From 6aa0e50193eba80b9e542b93295e9b0026e91e65 Mon Sep 17 00:00:00 2001 From: Gergely Polonkai Date: Mon, 19 Oct 2015 17:03:17 +0200 Subject: [PATCH] Add related names to DuckCompetence fields --- booking/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/booking/models.py b/booking/models.py index 2d14373..9d9d296 100644 --- a/booking/models.py +++ b/booking/models.py @@ -121,8 +121,8 @@ class DuckNameVote(models.Model): class DuckCompetence(models.Model): """Duck competence governor table""" - duck = models.ForeignKey(Duck) - comp = models.ForeignKey(Competence) + duck = models.ForeignKey(Duck, related_name='competences') + comp = models.ForeignKey(Competence, related_name='ducks') up_minutes = models.IntegerField(default=0) down_minutes = models.IntegerField(default=0)