Remove GenericRelation to prevent cascade deletion of logs

This commit is contained in:
Raphael Michel
2017-02-23 17:52:48 +01:00
parent f722d4e83e
commit a2cb219d9b
2 changed files with 9 additions and 3 deletions

View File

@@ -130,3 +130,6 @@ class LogEntry(models.Model):
@cached_property
def parsed_data(self):
return json.loads(self.data)
def delete(self, using=None, keep_parents=False):
raise TypeError("Logs cannot be deleted.")