demarches-normaliennes/app/components/editable_champ/dossier_link_component.rb

10 lines
259 B
Ruby
Raw Normal View History

class EditableChamp::DossierLinkComponent < EditableChamp::EditableChampBaseComponent
def dsfr_input_classname
'fr-input'
end
def dossier
@dossier ||= @champ.blank? ? nil : Dossier.visible_by_administration.find_by(id: @champ.to_s)
end
2022-08-12 10:45:04 +02:00
end