#35 Sanity command

* refactors "toggling" of recorded/checked state
* introduces mark_as_edited() for RecordableObjectMixin
This commit is contained in:
2021-11-17 12:09:49 +01:00
parent 80e72c2146
commit bd36ab5b6f
11 changed files with 80 additions and 59 deletions

View File

@@ -348,10 +348,7 @@ class EditInterventionForm(NewInterventionForm):
self.instance.save()
# Uncheck and unrecord intervention due to changed data
if self.instance.checked:
self.instance.set_unchecked()
if self.instance.recorded:
self.instance.set_unrecorded(user)
self.instance.mark_as_edited(user)
return self.instance