demarches-normaliennes/app/models/deleted_dossier.rb
2019-02-14 18:09:08 +01:00

7 lines
245 B
Ruby

class DeletedDossier < ApplicationRecord
belongs_to :procedure
def self.create_from_dossier(dossier)
DeletedDossier.create!(dossier_id: dossier.id, procedure: dossier.procedure, state: dossier.state, deleted_at: Time.now.utc)
end
end