djangocms-history
djangocms-history copied to clipboard
cannot delete user
django cms users cannot be deleted if there are related PlaceholderOperation
objects:
- there is a restriction that prevents this at admin-site level (
djangocms_history/admin.py
) - there is a direct foreign key relation (see
djangocms_history/models.py
,PlaceholderOperation.user
) todjango.contrib.auth.User
which causes the deletion to fail with "there is no permission to delete theplaceholder operation
"
In my opinion this should be resolved (as there should generally be no showstoppers to delete stale accounts) by either
- deleting related placeholder operations when deleting a user
- or resolving the relation to
django.contrib.auth.User
differently, e.g. similarly as django-cms does in the page model where thecreated_by
field is just the username and no direct foreign key