[Django] Automatically Update Field when a Different Field is Changed
- by Gordon
I have a model with a bunch of different fields like first_name, last_name, etc. I also have fields first_name_ud, last_name_ud, etc. that correspond to the last updated date for the related fields (i.e. when first_name is modified, then first_name_ud is set to the current date).
Is there a way to make this happen automatically or do I need to check what fields have changed each time I save an object and then update the related "_ud" fields.
Thanks a lot!