From 85606123a5ddea7cf97921d4584a87c97f92a1d1 Mon Sep 17 00:00:00 2001 From: Mo8it Date: Fri, 30 Jul 2021 23:37:38 +0200 Subject: [PATCH] Added customUpdateDate and customUpdateSpecial for Appointment --- advlabdb/models.py | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/advlabdb/models.py b/advlabdb/models.py index 32533ec..e6f5cac 100644 --- a/advlabdb/models.py +++ b/advlabdb/models.py @@ -313,6 +313,12 @@ class Appointment(db.Model): self.assistant = assistant self.group_experiment = group_experiment + def customUpdateDate(self, date): + self.date = date + + def customUpdateSpecial(self, special): + self.special = special + def repr(self): return f"{self.date} {self.group_experiment.repr()}" @@ -407,7 +413,7 @@ class ExperimentMark(db.Model): return f"Oral {self.oral_mark}; Prot {self.protocol_mark}" def __repr__(self): - return f"" + return f"" class User(db.Model, FsUserMixin):