split form and avis answers in 2 views for instructeurs

This commit is contained in:
Lisa Durand 2023-03-10 18:39:26 +01:00
parent dcf1bcc16c
commit 603d66e020
5 changed files with 27 additions and 2 deletions

View file

@ -76,6 +76,14 @@ module Instructeurs
end
end
def avis_new
@avis_seen_at = current_instructeur.follows.find_by(dossier: dossier)&.avis_seen_at
@avis = Avis.new
if @dossier.procedure.experts_require_administrateur_invitation?
@experts_emails = dossier.procedure.experts_procedures.where(revoked_at: nil).map(&:expert).map(&:email).sort
end
end
def personnes_impliquees
@following_instructeurs_emails = dossier.followers_instructeurs.map(&:email)
previous_followers = dossier.previous_followers_instructeurs - dossier.followers_instructeurs