mirror of
https://codeberg.org/Mo8it/AdvLabDB.git
synced 2024-11-08 21:21:06 +00:00
Improved repr for ExperimentMark
This commit is contained in:
parent
3b7c186baf
commit
96a32a3c3a
1 changed files with 4 additions and 2 deletions
|
@ -124,7 +124,7 @@ class PartStudent(db.Model):
|
||||||
category,
|
category,
|
||||||
)
|
)
|
||||||
else:
|
else:
|
||||||
flash(f"Final part mark did not change for {self} from {oldFinalPartMark}.")
|
flash(f"Final part mark did not change for {self} from {oldFinalPartMark}.", "warning")
|
||||||
|
|
||||||
def repr(self):
|
def repr(self):
|
||||||
return f"{self.student.repr()} {self.part.repr()}"
|
return f"{self.student.repr()} {self.part.repr()}"
|
||||||
|
@ -481,7 +481,9 @@ class ExperimentMark(db.Model):
|
||||||
return ExperimentMark(part_student=part_student, group_experiment=group_experiment)
|
return ExperimentMark(part_student=part_student, group_experiment=group_experiment)
|
||||||
|
|
||||||
def repr(self):
|
def repr(self):
|
||||||
return f"Oral {self.oral_mark}; Prot {self.protocol_mark}"
|
return (
|
||||||
|
f"Oral {self.oral_mark}; Prot {self.protocol_mark}; Exp {self.group_experiment.semester_experiment.repr()}"
|
||||||
|
)
|
||||||
|
|
||||||
def __repr__(self):
|
def __repr__(self):
|
||||||
return f"<EXPMARK {self.repr()}>"
|
return f"<EXPMARK {self.repr()}>"
|
||||||
|
|
Loading…
Reference in a new issue