2014-02-18 09:28:04 +01:00
|
|
|
= form_for [:moderation, @note] do |f|
|
|
|
|
- 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
|
2014-06-30 00:52:45 +02:00
|
|
|
|
|
|
|
- if params[:envoiParMail]
|
|
|
|
= hidden_field_tag :envoiParMail, params[:envoiParMail]
|
|
|
|
|
|
|
|
%p=t 'title', scope: [:note_mailer, :create]
|
|
|
|
%p=t 'body', scope: [:note_mailer, :create], subject: @note.event.title, contents: @note.contents
|
|
|
|
|
2014-02-18 09:28:04 +01:00
|
|
|
.field
|
|
|
|
%p.label= f.label Note.human_attribute_name :contents
|
|
|
|
= f.text_area :contents, cols: 70, rows: 10
|
|
|
|
|
2014-06-30 00:52:45 +02:00
|
|
|
- if params[:envoiParMail]
|
|
|
|
:markdown
|
2014-08-09 18:59:11 +02:00
|
|
|
#{t 'edit_link', scope: [:note_mailer, :notify]}
|
2014-06-30 00:52:45 +02:00
|
|
|
|
2014-10-31 14:33:39 +01:00
|
|
|
#{edit_moderation_path @note.event}
|
2014-06-30 00:52:45 +02:00
|
|
|
|
2014-08-09 18:59:11 +02:00
|
|
|
#{t 'signature', scope: [:note_mailer, :notify]}
|
2014-06-30 00:52:45 +02:00
|
|
|
|
|
|
|
.actions
|
2014-10-31 14:33:39 +01:00
|
|
|
= link_to moderations_path do
|
2014-09-20 17:47:46 +02:00
|
|
|
%em.fa.fa-arrow-left
|
|
|
|
=t '.ko'
|
|
|
|
= f.button do
|
|
|
|
%em.fa.fa-bullhorn
|
|
|
|
=t '.save'
|
2014-06-30 00:52:45 +02:00
|
|
|
|
|
|
|
- else
|
|
|
|
.actions
|
2014-10-31 14:33:39 +01:00
|
|
|
= link_to moderations_path do
|
2014-09-20 17:47:46 +02:00
|
|
|
%em.fa.fa-arrow-left
|
|
|
|
=t '.ko'
|
|
|
|
= f.button do
|
|
|
|
%em.fa.fa-bullhorn
|
|
|
|
=t '.ok'
|