change foregin key to one to one field and add MUOR app to settings.
This commit is contained in:
parent
4072c90e68
commit
f87290b6b5
@ -9,7 +9,8 @@ class Profile(AbstractUser):
|
|||||||
|
|
||||||
|
|
||||||
class Session(models.Model):
|
class Session(models.Model):
|
||||||
user = models.ForeignKey(Profile, primary_key=True, on_delete=models.CASCADE)
|
user = models.OneToOneField(Profile, primary_key=True,
|
||||||
|
on_delete=models.CASCADE)
|
||||||
port = models.PositiveIntegerField(null=False, unique=True)
|
port = models.PositiveIntegerField(null=False, unique=True)
|
||||||
sessionid = models.CharField(max_length=32)
|
sessionid = models.CharField(max_length=32)
|
||||||
container_id = models.CharField(max_length=64, null=True, blank=True)
|
container_id = models.CharField(max_length=64, null=True, blank=True)
|
||||||
|
@ -36,7 +36,8 @@ INSTALLED_APPS = [
|
|||||||
'django.contrib.sessions',
|
'django.contrib.sessions',
|
||||||
'django.contrib.messages',
|
'django.contrib.messages',
|
||||||
'django.contrib.staticfiles',
|
'django.contrib.staticfiles',
|
||||||
'crispy_forms'
|
'crispy_forms',
|
||||||
|
'MUOR'
|
||||||
]
|
]
|
||||||
|
|
||||||
MIDDLEWARE = [
|
MIDDLEWARE = [
|
||||||
|
Loading…
Reference in New Issue
Block a user