added SLot.rooms property

This commit is contained in:
Brian Rosner 2012-09-19 20:16:07 -06:00
parent 17869c7c7c
commit f30dce6a61

View file

@ -74,6 +74,10 @@ class Slot(models.Model):
except ObjectDoesNotExist:
return None
@property
def rooms(self):
return Room.objects.filter(pk__in=self.slotroom_set.values("room"))
class SlotRoom(models.Model):
"""