diff --git a/seminar/models.py b/seminar/models.py index 57d4304a..43d6e59d 100644 --- a/seminar/models.py +++ b/seminar/models.py @@ -1246,7 +1246,7 @@ class TreeNode(PolymorphicModel): blank = False, on_delete = models.SET_NULL, # Vrcholy s null kořenem jsou sirotci bez ročníku verbose_name="kořen stromu") - first_child = models.ForeignKey('TreeNode', + first_child = models.OneToOneField('TreeNode', related_name='father_of_first', null = True, blank = True,