2012-05-16 22:28:29 +00:00
|
|
|
<%= javascript_include_tag "new_admin" %>
|
|
|
|
<%= stylesheet_link_tag "new_admin" %>
|
2012-08-07 09:32:15 +00:00
|
|
|
<%= javascript_include_tag "tinymce/tiny_mce_popup" %>
|
2012-05-16 22:28:29 +00:00
|
|
|
|
|
|
|
|
2012-08-07 09:32:15 +00:00
|
|
|
<%= flash_messages %>
|
|
|
|
<body onload="tinyMCEPopup.executeOnLoad('init();')">
|
2012-05-16 22:28:29 +00:00
|
|
|
<%= form_for :asset, :url => admin_assets_path(:uploader => true), :html => {:id => 'ajaxForm', :multipart => true } do |f| %>
|
|
|
|
<div class="modal-header">
|
|
|
|
<h3><%= t 'admin.file_upload' %></h3>
|
|
|
|
</div>
|
|
|
|
<div class="modal-body form-horizontal">
|
|
|
|
<div class="control-group">
|
2012-05-17 08:40:09 +00:00
|
|
|
<label for="title" class="control-label error"><%= t 'admin.title' %></label>
|
2012-05-16 22:28:29 +00:00
|
|
|
<div class="controls">
|
2012-07-25 21:58:09 +00:00
|
|
|
<%= f.fields_for :title_translations do |f| %>
|
2012-05-17 11:09:52 +00:00
|
|
|
<div>
|
2012-05-17 11:40:30 +00:00
|
|
|
<% @site_valid_locales.each do |locale| %>
|
|
|
|
<%= content_tag :label do -%>
|
|
|
|
<div>
|
|
|
|
<%= I18nVariable.from_locale(locale) %>
|
2012-07-25 21:58:09 +00:00
|
|
|
<%= f.text_field locale, :class => "input-large", :value => (@asset.title_translations[locale] rescue nil) %>
|
2012-05-17 11:40:30 +00:00
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
<% end %>
|
2012-05-17 11:09:52 +00:00
|
|
|
</div>
|
2012-05-16 22:28:29 +00:00
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
2012-05-17 10:31:40 +00:00
|
|
|
<label for="description" class="control-label error"><%= t 'admin.description' %></label>
|
2012-05-16 22:28:29 +00:00
|
|
|
<div class="controls">
|
2012-07-25 21:58:09 +00:00
|
|
|
<%= f.fields_for :description_translations do |f| %>
|
2012-05-17 11:09:52 +00:00
|
|
|
<div>
|
2012-05-17 11:40:30 +00:00
|
|
|
<% @site_valid_locales.each do |locale| %>
|
|
|
|
<%= content_tag :label do -%>
|
|
|
|
<div>
|
|
|
|
<%= I18nVariable.from_locale(locale) %>
|
2012-07-25 21:58:09 +00:00
|
|
|
<%= f.text_field locale, :class => "input-large", :value => (@asset.title_translations[locale] rescue nil) %>
|
2012-05-17 11:40:30 +00:00
|
|
|
</div>
|
|
|
|
<% end %>
|
|
|
|
<% end %>
|
2012-05-17 11:09:52 +00:00
|
|
|
</div>
|
2012-05-16 22:28:29 +00:00
|
|
|
<% end %>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div class="control-group">
|
2012-05-17 08:40:09 +00:00
|
|
|
<%= f.label :data, t('admin.data'), :class => "control-label" %>
|
2012-05-16 22:28:29 +00:00
|
|
|
<div class="controls">
|
|
|
|
<%= f.file_field :data, :class => 'upload' %>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<div style="position: absolute; width: 100%; bottom: 0;">
|
|
|
|
<div class="modal-footer">
|
2012-08-06 07:13:21 +00:00
|
|
|
<%= f.submit t(:create), :class => "btn btn-primary" %>
|
2012-05-16 22:28:29 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
2012-08-07 09:32:15 +00:00
|
|
|
<% end %>
|
2012-08-06 07:13:21 +00:00
|
|
|
</body>
|