delete a user
This commit is contained in:
parent
58ef36ff57
commit
9a62d3fe0c
6 changed files with 73 additions and 6 deletions
|
@ -100,6 +100,15 @@ class User < ApplicationRecord
|
|||
dossiers.state_instruction_commencee.empty?
|
||||
end
|
||||
|
||||
def delete_and_keep_track_dossiers(administration)
|
||||
if can_be_deleted?
|
||||
dossiers.each do |dossier|
|
||||
dossier.delete_and_keep_track(administration)
|
||||
end
|
||||
destroy
|
||||
end
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def link_invites!
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue