<% content_for :page_specific_css do %> <%= stylesheet_link_tag "lib/main-forms" %> <%= stylesheet_link_tag "lib/fileupload" %> <%= stylesheet_link_tag "lib/main-list" %> <% end %> <% content_for :page_specific_javascript do %> <%= javascript_include_tag "lib/bootstrap-fileupload" %> <%= javascript_include_tag "lib/bootstrap-datetimepicker" %> <%= javascript_include_tag "lib/datetimepicker/datetimepicker.js" %> <%= javascript_include_tag "lib/file-type" %> <%= javascript_include_tag "lib/module-area" %> <% end %>
<%= f.datetime_picker :start_date, :no_label => true, :new_record => @paper_criteria.new_record?, :data=>{"picker-type" => "range", "range" => "start"} %>
<%= f.datetime_picker :end_date, :no_label => true, :new_record => @paper_criteria.new_record?, :data=>{"picker-type" => "range", "range" => "end"} %>
<% @site_in_use_locales.each_with_index do |locale, i| %>
<%= f.fields_for :sending_title_translations do |f| %> <%= f.text_field locale, value: (@paper_criteria.sending_title_translations[locale] rescue nil) %> <% end %>
<% end %>
<%= f.text_area :sending_notes %>
<% @site_in_use_locales.each_with_index do |locale, i| %>
<% end %>
<%= f.text_area :other_emails %>
Separated by , (comma)
<% if @paper_criteria.image.file %> <%= image_tag @paper_criteria.image %> <% else %> <% end %>
<%= t(:select_image) %> <%= t(:change) %> <%= f.file_field :image %> <%= t(:cancel) %>
<% @site_in_use_locales.each_with_index do |locale, i| %>
">
<%= f.fields_for :title_translations do |f| %> <%= f.text_field locale, class: "input-block-level", placeholder: t(:title), value: (@paper_criteria.title_translations[locale] rescue nil) %> <% end %>
<%= f.fields_for :description_translations do |f| %> <%= f.text_area locale, rows: 2, class: "input-block-level", value: (@paper_criteria.description_translations[locale] rescue nil) %> <% end %>
<%= f.fields_for :content_translations do |f| %> <%= f.cktext_area locale, rows: 5, class: "input-block-level", :value => @paper_criteria.content_translations[locale] %> <% end %>
<% end %>
<%= f.submit t('submit'), class: 'btn btn-primary' %>