aboutsummaryrefslogtreecommitdiffstats
path: root/client/models.py
diff options
context:
space:
mode:
authorAndrea Lepori <alepori@student.ethz.ch>2020-06-20 15:55:28 +0200
committerAndrea Lepori <alepori@student.ethz.ch>2020-06-20 15:55:28 +0200
commitccc5d1f1b2cb4b5e2a95b97bbd1a5760ce585f08 (patch)
tree6912e8d96bce8bdf7782c7877a7a0928560c7a1a /client/models.py
parentDocument support (diff)
downloadscout-subs-ccc5d1f1b2cb4b5e2a95b97bbd1a5760ce585f08.tar.gz
scout-subs-ccc5d1f1b2cb4b5e2a95b97bbd1a5760ce585f08.zip
Document custom field
Diffstat (limited to 'client/models.py')
-rw-r--r--client/models.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/client/models.py b/client/models.py
index 01d5f4c..e7142ac 100644
--- a/client/models.py
+++ b/client/models.py
@@ -12,6 +12,8 @@ class DocumentType(models.Model):
personal_data = models.BooleanField(default=False)
medical_data = models.BooleanField(default=False)
custom_data = models.BooleanField(default=False)
+ custom_message = models.BooleanField(default=False)
+ custom_message_text = models.CharField(default="", max_length=250)
name = models.CharField(default="", max_length=250)
@@ -36,7 +38,7 @@ class Document(models.Model):
DocumentType, default=None, on_delete=models.PROTECT)
personal_data = models.ForeignKey(
- PersonalData, default=None, on_delete=models.PROTECT)
+ PersonalData, default=None, on_delete=models.PROTECT, null=True)
class Meta:
permissions = [