2010-07-13 00:46:17 +00:00
|
|
|
- title link_to(@asset_collection.name.blank? ? @asset_collection.name_was : @asset_collection.name, '#', :rel => 'asset_collection_name', :title => t('.ask_for_name'), :class => 'editable')
|
2010-05-12 00:16:39 +00:00
|
|
|
|
|
|
|
- content_for :head do
|
2010-12-14 17:00:12 +00:00
|
|
|
= include_javascripts :asset_collections
|
|
|
|
= include_stylesheets :fancybox
|
2010-05-12 00:16:39 +00:00
|
|
|
|
|
|
|
- content_for :submenu do
|
|
|
|
= render 'admin/shared/menu/assets'
|
|
|
|
|
2010-07-21 23:56:42 +00:00
|
|
|
%p!= t('.help')
|
2010-05-12 00:16:39 +00:00
|
|
|
|
|
|
|
- content_for :buttons do
|
2010-07-13 20:01:40 +00:00
|
|
|
= admin_button_tag :add_asset, new_admin_asset_url(@asset_collection), :class => 'new'
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2010-07-13 00:46:17 +00:00
|
|
|
%p.no-items{ :style => "#{'display: none' unless @asset_collection.assets.empty? }" }
|
2010-07-21 23:56:42 +00:00
|
|
|
!= t('.no_items', :url => new_admin_asset_url(@asset_collection))
|
|
|
|
|
2010-05-12 00:16:39 +00:00
|
|
|
%ul#assets.assets.sortable
|
2010-07-13 00:46:17 +00:00
|
|
|
= render :partial => 'asset', :collection => @asset_collection.ordered_assets
|
2010-05-12 00:16:39 +00:00
|
|
|
%li.clear
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2010-07-13 00:46:17 +00:00
|
|
|
= semantic_form_for @asset_collection, :url => admin_asset_collection_url(@asset_collection), :html => { :multipart => true } do |f|
|
2010-05-12 00:16:39 +00:00
|
|
|
= f.hidden_field :assets_order
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2010-05-12 00:16:39 +00:00
|
|
|
= f.foldable_inputs :name => :options do
|
|
|
|
= f.input :name
|
|
|
|
= f.input :slug, :required => false
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2010-06-22 13:04:40 +00:00
|
|
|
= render 'admin/custom_fields/index', :form => f, :collection_name => 'assets'
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2010-07-13 20:01:40 +00:00
|
|
|
= render 'admin/shared/form_actions', :delete_button => link_to(content_tag(:em, escape_once(' ')) + t('.destroy'), admin_asset_collection_url(@asset_collection), :confirm => t('admin.messages.confirm'), :method => :delete, :class => 'button small remove'), :button_label => :update
|
2010-07-21 23:56:42 +00:00
|
|
|
|
2011-03-04 23:29:40 +00:00
|
|
|
= render 'admin/custom_fields/edit_field'
|