On 18/12/14 17:19, Carsten Fuchs wrote:
> I would like to find out if anything has changed in the parent
> model or the related (inline) models, and depending on the result,
> update one of the parent model's fields before it is saved.
> 
> Can you please tell me how can this be achieved?


Take a look at the Django signal dispatcher:
https://docs.djangoproject.com/en/dev/topics/signals/

Specifically, the 'update_fields' argument passed to the 'pre_save'
signal should provide what you need:

https://docs.djangoproject.com/en/dev/ref/signals/#django.db.models.signals.pre_save

Regards,

Alex.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/5495EE89.6040504%40mykolab.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to