We keep on running into issues every now and then about a user complaining that they deleted a file or course module and wants the data recovered.
The process often involves us taking a recent snapshot of the database, load it up another another server. If files are involved we rsync the file system to another server and "hope" that the deleted files aren't yet purged from the file cleanup cron.
Then we do a backup/restore of the single course module. This process is not always smooth and is such a hassle that involves hours of manual intervention.
What if we had a "deleted" flag in the course module data that acts like a super "visible" flag. So that the content doesn't show up for any user. Or we can overload the "visible" flag for a third state of "deleted"?
Then we have a weekly or so cron that will clean up course modules that are flagged as deleted if the flag was set at a certain time interval? Seems like a possible simple concept that would save people from shooting themselves in the foot.
We would have a report that can allow users to "undelete" deleted course modules.
This is a past discussion: Undelete or recycler for all deleted items?
It was also mentioned in the Perth Hackfest years ago, but nothing seemed to come out of it.
I hope to drum up interest and I wonder if my proposed approach is along the right way or not.
I created a tracker issue for this: https://tracker.moodle.org/browse/MDL-48012