mirror of
https://github.com/suitenumerique/docs.git
synced 2026-09-17 15:17:59 +02:00
Deleting a user is not possible when it has created docs because the on_delete on the Document class id RESTRICT and we don't want to change it. We decided to have a specific workflow for correctly delete a user. The document where the user is the sole owner must be deleted, the other only the owner access must be deleted. For the remaining Documents where the user is the creator, we set it to `null`, then the user can be delete, remaining relations are deleted in cascade.