Hi everybody, I am using Django for the first time and I have a few problems.
My model is (simplified): ------- class Company(models.Model): name = models.CharField(u'company name', max_length=255) address = models.CharField(u'address', max_length=255) etc. ------- class Person(models.Model): persons_company = models.ForeignKey(Company, related_name=u'employees') first_name = models.CharField(u'first name', max_length=30) last_name = models.CharField(u'last_name', max_length=255) etc. ------- class Reclamation(models.Model): description= models.TextField(u'reclamation description') reclamation_claimant = models.ForeignKey(Person, related_name=u'reclamations', verbose_name=u'claimant') etc. Now I can add Reclamations using Admin interface. But I would like to have interface which is aware of Company. Eg. I would like page admin/ myapp/reclamation/ to show links like this: admin/myapp/company/1/ reclamation/. Cliciking on that link will show reclamations only from Company with id=1. And filter by claimant box will be populated only claimants from that Company. Also when I add reclamation with url admin/myapp/company/1/reclamation/add to have combo box 'claimant' filled only with persons belonging to Company with id=1. I know how to change template on url admin/myapp/reclamation/, but for the rest of problem I do not have solution. Thanks, Zlatan --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Django users" group. To post to this group, send email to django-users@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---