2018-05-30 11:36:48 +02:00
|
|
|
class DeletedDossier < ApplicationRecord
|
|
|
|
belongs_to :procedure
|
2019-02-13 16:13:37 +01:00
|
|
|
|
|
|
|
def self.create_from_dossier(dossier)
|
2019-02-18 11:56:09 +01:00
|
|
|
DeletedDossier.create!(dossier_id: dossier.id, procedure: dossier.procedure, state: dossier.state, deleted_at: Time.zone.now)
|
2019-02-13 16:13:37 +01:00
|
|
|
end
|
2018-05-30 11:36:48 +02:00
|
|
|
end
|