From d03de8d6f904c6b42d87ef0d307089b54ac6ba79 Mon Sep 17 00:00:00 2001 From: Johnson Chetty Date: Fri, 27 Jul 2012 15:53:01 +0200 Subject: [PATCH] related names added to itfprofiles.models.theatregroup --- itf/itfprofiles/models.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/itf/itfprofiles/models.py b/itf/itfprofiles/models.py index 10ac2c0..c13f0e2 100644 --- a/itf/itfprofiles/models.py +++ b/itf/itfprofiles/models.py @@ -248,7 +248,7 @@ class TheatreGroup(ItfModel): added_by = models.ForeignKey(User) name = models.CharField(max_length=255, db_index=True) # name + location is unique email = models.EmailField(blank=True, null=True) - location = models.ForeignKey(Location, blank=True, null=True) + location = models.ForeignKey(Location, blank=True, null=True, related_name="theatregroup_location") tel = models.IntegerField(blank=True, null=True) nature_of_work = models.ManyToManyField("GroupOccupation", blank=True, null=True, through="GroupGroupOccupation") languages = models.ManyToManyField("Language", blank=True, null=True) @@ -257,7 +257,7 @@ class TheatreGroup(ItfModel): awards = models.ManyToManyField("Award", blank=True, null=True) website = models.URLField(blank=True, verify_exists=False) # resources = models.ManyToManyField("Resource", blank=True, null=True) - locations = models.ManyToManyField("Location", blank=True, null=True) + locations = models.ManyToManyField("Location", blank=True, null=True, related_name="theatregroup_locations") about = models.TextField(blank=True, null=True) nature_of_work = models.CharField(max_length=255)