Added billard app
This commit is contained in:
parent
c297407135
commit
a51c2cf733
0
billard/__init__.py
Normal file
0
billard/__init__.py
Normal file
3
billard/admin.py
Normal file
3
billard/admin.py
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
from django.contrib import admin
|
||||||
|
|
||||||
|
# Register your models here.
|
5
billard/apps.py
Normal file
5
billard/apps.py
Normal file
@ -0,0 +1,5 @@
|
|||||||
|
from django.apps import AppConfig
|
||||||
|
|
||||||
|
|
||||||
|
class BillardConfig(AppConfig):
|
||||||
|
name = 'billard'
|
0
billard/migrations/__init__.py
Normal file
0
billard/migrations/__init__.py
Normal file
16
billard/models.py
Normal file
16
billard/models.py
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
from django.db import models
|
||||||
|
|
||||||
|
# Create your models here.
|
||||||
|
|
||||||
|
|
||||||
|
class Location(models.Model):
|
||||||
|
name = models.CharField(max_length=30, unique=True)
|
||||||
|
|
||||||
|
class Client(models.Model):
|
||||||
|
id = models.UUIDField(primary_key=True, editable=False)
|
||||||
|
location = models.ForeignKey(Location)
|
||||||
|
|
||||||
|
class Table(models.Model):
|
||||||
|
client = models.ForeignKey(Client)
|
||||||
|
number = models.IntegerField()
|
||||||
|
name = models.CharField(max_length=30)
|
3
billard/tests.py
Normal file
3
billard/tests.py
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
from django.test import TestCase
|
||||||
|
|
||||||
|
# Create your tests here.
|
3
billard/views.py
Normal file
3
billard/views.py
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
from django.shortcuts import render
|
||||||
|
|
||||||
|
# Create your views here.
|
Loading…
Reference in New Issue
Block a user