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
kg
http://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
-~----------~----~----~----~------~----~------~--~---

Reply via email to