Use revision instead of groupe instructeur as dossier procedure link

This commit is contained in:
Paul Chavard 2021-03-09 11:21:25 +01:00
parent 1e10298859
commit 9c3e72c84a
6 changed files with 11 additions and 14 deletions

View file

@ -22,6 +22,7 @@ class Avis < ApplicationRecord
belongs_to :instructeur, optional: true
belongs_to :experts_procedure, optional: true
belongs_to :claimant, class_name: 'Instructeur', optional: false
has_one :procedure, through: :dossier
has_one_attached :piece_justificative_file
has_one_attached :introduction_file
@ -79,10 +80,6 @@ class Avis < ApplicationRecord
]
end
def procedure
dossier.procedure
end
def revoked?
revoked_at.present?
end