If you're creating your objects through forms, the clean() method on your form may even be a better place for that:
http://docs.djangoproject.com/en/dev/ref/forms/validation/#cleaning-and-validating-fields-that-depend-on-each-other Rodrigue On Jul 1, 10:58 am, Kenneth Gonsalves <law...@thenilgiris.com> wrote: > On Wednesday 01 July 2009 14:58:00 Shuge Lee wrote: > > > # cat models.py > > > class Seed(models.Model): > > name = models.CharField(max_length=128, unique=True) > > category = models.ForeignKey(Category) > > source = models.CharField(max_length=256) > > > now, I want > > source = category + '/' + name > > if user doesn't fill source field in admin view > > > How to do that ? > > overide save() > -- > regards > kghttp://lawgon.livejournal.com --~--~---------~--~----~------------~-------~--~----~ 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 django-users+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/django-users?hl=en -~----------~----~----~----~------~----~------~--~---