<% content_for :page_specific_css do %> <%= stylesheet_link_tag "lib/main-forms" %> <%= stylesheet_link_tag "lib/main-list" %> <%= stylesheet_link_tag "lib/dropzone" %> <%= stylesheet_link_tag "//maxcdn.bootstrapcdn.com/font-awesome/4.4.0/css/font-awesome.min.css" %> <%= stylesheet_link_tag "//cdnjs.cloudflare.com/ajax/libs/animate.css/3.2.6/animate.min.css" %> <%= stylesheet_link_tag "space-admin" %> <% end %> <% content_for :page_specific_javascript do %> <%= javascript_include_tag "lib/dropzone" %> <%= javascript_include_tag "validator" %> <%= javascript_include_tag "space/space" %> <% end %>
Uploading...
<% @site_in_use_locales.each do |locale| %> <%= f.fields_for :title_translations do |f| %>
<%= f.label t(:title) + " (" + t(locale) + ")", :class => "control-label muted" %>
<%= f.text_field locale, placeholder: t("space.sub_unit_name"), data: {"fv-validation" => "required;", "fv-messages" => "Cannot be empty;"}, :value => @sub_unit.title_translations[locale.to_s] %>
<% end %> <% end %>
<% if params[:action] == "edit_sub_unit" %>
<% @sub_unit.floor_sub_unit_images.each do |image| %>
<% end %>
<% end %>
<% @site_in_use_locales.each do |locale| %> <%= f.fields_for :content_translations do |f| %>
<%= f.label t(:content) + " (" + t(locale) + ")", :class => "control-label muted" %>
<%= f.text_area locale, placeholder: t(:content), :value => @sub_unit.content_translations[locale.to_s], :class=> 'ckeditor' %>
<% end %> <% end %>
<% if params[:action] == "add_sub_unit" %> <%= f.hidden_field :floor_unit, :value => @floor_unit.id %> <% elsif params[:action] == "edit_sub_unit" %> <%= hidden_field_tag :floor_sub_unit_id, @sub_unit.id.to_s %> <% end %> <%= f.submit t('submit'), class: 'btn btn-primary', :id => "floor-sub-unit-form-btn" %>