On Mon, Jul 03, 2006 at 07:09:35AM -0500, James Bennett wrote:
> You can also differentiate between the initial save and later updates
> by checking -- before calling the parent class' 'save' method --
> whether the object has an ID; if it doesn't, then the object is being
> created for the first time, and if it does then it's an update to an
> existing object.

Perhaps instead of relying on the behavor of the object's ID not
existing until it's been created, that should become a method.
something like Model.created() returning true/flase or Model.is_created
or... something...???

-- 
Glenn

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to