<% 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/modal-preview" %> <%= javascript_include_tag "lib/file-type" %> <% end %> <%#= f.error_messages %>
<%= f.label :category ,t(:category), :class=>"control-label muted" %>
<%= select_category(f, @module_app) %>
<%= select_tag(f, @module_app) %>
<% @site_in_use_locales.each_with_index do |locale, i| %>
">
<%= f.label :title , t('faq.question'), :class=>"control-label muted" %>
<%= f.fields_for :title_translations do |f| %> <%= f.text_field locale, :class=>'post-title', :value => (@qa.title_translations[locale] rescue nil) %> <% end %>
<%= f.label :answer ,t('faq.answer'), :class => "control-label muted" %> <%= f.fields_for :answer_translations do |f| %>
<%= f.text_area locale, :style=>"width:100%", :class => 'ckeditor input-block-level', :value => (@qa.answer_translations[locale] rescue nil) %>
<% end %>
<% end %>
<% if @qa && !@qa.qa_links.blank? %>
<% @qa.qa_links.each_with_index do |qa_link, i| %> <%= f.fields_for :qa_links, qa_link do |f| %> <%= render :partial => 'form_qa_link', :object => qa_link, :locals => {:f => f, :i => i} %> <% end %> <% end %>
<% end %>

<%= hidden_field_tag 'qa_link_field_count', @qa.qa_links.count %> <%= t(:add) %>

<% if @qa && !@qa.qa_files.blank? %>
<% @qa.qa_files.each_with_index do |qa_file, i| %> <%= f.fields_for :qa_files, qa_file do |f| %> <%= render :partial => 'form_qa_file', :object => qa_file, :locals => {:f => f, :i => i} %> <% end %> <% end %>
<% end %>

<%= hidden_field_tag 'qa_file_field_count', @qa.qa_files.count %> <%= t(:add) %>

<%= f.submit t('submit'), class: 'btn btn-primary' %> <%#= button_tag t("preview"), id: "button_for_preview", name: "commit", class: 'btn post_preview', type: :button, url: preview_panel_announcement_back_end_bulletins_path %> <%#= link_to t('cancel'), get_go_back, :class=>"btn" %>
<% content_for :page_specific_javascript do %> <% end %>