I have a model Goal which has two M2M fields and is referred to by another model Event. Now, the requirement is such that Goal is editable which means I can add/delete from M2M fields and add/delete events. But editing goes through moderation and only after approval the changes are to be reflected or in case of rejection changes must be reverted.
I have gone through deepcopy but it doesn't serve my purpose because lets say if I do x=deepcopy(goal object)
I get copy of goal object but I am unsure what I can do with it.
Then I came to know about model_to_dict from django.forms module it serializes the whole object which is handy. I was thinking may be I could use this dictionary to create a model RevisedGoal with original goal as foreign key. Is it a feasible solution? Are there any othe ways of achieving this?