parent
87fa8365eb
commit
c30a74af25
@ -1,14 +1,33 @@
|
||||
= form_for [:moderation, @note] do |f|
|
||||
= hidden_field_tag :envoiParMail, params[:envoiParMail]
|
||||
- if @note.errors.any?
|
||||
#error_explanation
|
||||
%h2= "#{pluralize(@note.errors.count, "error")} prohibited this note from being saved:"
|
||||
%ul
|
||||
- @note.errors.full_messages.each do |msg|
|
||||
%li= msg
|
||||
|
||||
- if params[:envoiParMail]
|
||||
= hidden_field_tag :envoiParMail, params[:envoiParMail]
|
||||
|
||||
%h2=t '.title'
|
||||
%p=t 'title', scope: [:note_mailer, :create]
|
||||
%p=t 'body', scope: [:note_mailer, :create], subject: @note.event.title, contents: @note.contents
|
||||
|
||||
.field
|
||||
%p.label= f.label Note.human_attribute_name :contents
|
||||
= f.text_area :contents, cols: 70, rows: 10
|
||||
|
||||
.actions
|
||||
= f.submit t('save')
|
||||
- if params[:envoiParMail]
|
||||
:markdown
|
||||
#{t 'edit_link', scope: [:note_mailer, :create]}
|
||||
|
||||
#{ edit_moderation_url @note.event}
|
||||
|
||||
#{t 'signature', scope: [:note_mailer, :create]}
|
||||
|
||||
.actions
|
||||
= f.submit t('.save')
|
||||
|
||||
- else
|
||||
.actions
|
||||
= f.submit t('save')
|
||||
|
Loading…
Reference in new issue