Merge pull request #9758 from demarches-simplifiees/purge_supprimer_dol
Tech: quand un dossier est définitivement supprimé, on ne garde que le log (DOL) concernant sa suppression
This commit is contained in:
commit
befe74b801
3 changed files with 123 additions and 1 deletions
|
@ -41,7 +41,9 @@ class DossierOperationLog < ApplicationRecord
|
|||
|
||||
def self.purge_discarded
|
||||
not_deletion.destroy_all
|
||||
with_data.each(&:move_to_cold_storage!)
|
||||
|
||||
supprimer.map { _1.serialized.purge_later }
|
||||
supprimer.update_all(data: nil)
|
||||
end
|
||||
|
||||
def self.create_and_serialize(params)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue