Accessing updated M2M fields in overriden save() in django's admin

Posted by Jonathan on Stack Overflow See other posts from Stack Overflow or by Jonathan
Published on 2010-06-18T15:19:27Z Indexed on 2010/06/18 15:23 UTC
Read the original article Hit count: 409

I'd like to use the user updated values of a ManyToManyField in a model's overriden save() method when I save an instance in admin.

It turns out that by design, django does not update the M2M field before calling save(), but only after the save() is complete as part of the form save...

How can I access the new values of this field in the override save() ?

© Stack Overflow or respective owner

Related posts about django-models

Related posts about django-admin