Hi,
In my django app i have the admin site and I am trying to customise it so that i can keep adding people to the event attendance. My models look like this:
class Talk(models.Model):
title = models.CharField(max_length=200, primary_key=True)
speaker = models.CharField(max_length=200)
date_of_talk = models.DateField('date_of_talk')
def __unicode__(self):
return self.title
class Member(models.Model):
name = models.CharField(max_length=200)
telephone_number = models.CharField(max_length=200)
email_address = models.CharField(max_length=200)
membership_type = models.CharField(max_length=1, choices=MEMBERSHIP_TYPES)
membership_number = models.CharField(max_length=200, primary_key=True)
def __unicode__(self):
return self.name
class Event_Attendance(models.Model):
talk = models.ForeignKey('Talk')
membersAttended = models.ForeignKey('Member')
I want to be able to configure the admin site so that i can keep adding members to the talk in the event_attendance object. I have one talk with many members. How would i do this? I also want the maximum number of membersAttended in the event_attendance object to be equal to the number of members.
Thanks in Advance,
Dean