demarches-normaliennes/app/views/administrateurs/procedures/_publication_form.html.haml
2022-11-08 10:20:35 +00:00

15 lines
956 B
Text

.card.mb-4
%h2.card-title Publiez votre démarche
= form_tag admin_procedure_publish_path(procedure_id: procedure.id), method: :put, class: 'form' do
= render Procedure::PublicationWarningComponent.new(procedure: procedure)
.mt-2
- if procedure.draft_changed?
%p.mb-2 Publiez une nouvelle version de votre démarche. Les modifications suivantes seront appliquées :
= render partial: 'revision_changes', locals: { changes: procedure.revision_changes }
- if procedure.close?
= render partial: 'publication_form_inputs', locals: { procedure: procedure, closed_procedures: @closed_procedures }
- else
= render partial: 'publication_form_inputs', locals: { procedure: procedure, closed_procedures: @closed_procedures }
.flex.justify-end
= submit_tag procedure_publish_label(procedure, :submit), { disabled: procedure.errors.present?, class: "fr-btn fr-btn--primary", id: 'publish' }