Sha256: 0c5862ae6d6e5a636188e71ca58612057880bc848c30914f776e405ef82b3063
Contents?: true
Size: 1.77 KB
Versions: 13
Compression:
Stored size: 1.77 KB
Contents
- @window_title = "Library" - @page_title = "#{link_to "Asset Library", admin_asset_category_path(:category => 'all' , :page => 1 )} > Collections" .row-fluid = render :partial => "/gluttonberg/admin/asset_library/shared/sidebar" .span9 .row-fluid .page-header %h1 = @page_title.html_safe .subnav = sub_nav do = nav_link("New Collection", new_admin_collection_url ) - if @collections.empty? %p.empty No collections available - else - unless @collections.empty? .accordion#accordion_for_collections - for collection in @collections - unless @category.blank? || @category.asset_type_ids.blank? - assets = collection.assets.where({:asset_type_id => @category.asset_type_ids }) - else - assets = collection.assets - if assets.length > 0 .accordion-group .accordion-heading %a{ :class=>"accordion-toggle no-ajax" , "data-toggle" => "collapse" , "data-parent" => "#accordion_for_collections" , "data-target" => "#collection-#{collection.id}", "href" => "#collection-#{collection.id}"} = "#{collection.name} ( #{pluralize(assets.length,'asset')} )" .accordion-body{:id => "collection-#{collection.id}" , :class => "collapse in"} .accordion-inner = render :partial => "gluttonberg/admin/shared/asset_panel.html" , :locals => {:assets => assets} /%li= link_to("Edit", edit_admin_collection_url(collection) ) /%li= link_to("Delete", delete_admin_collection_url(collection) ) :javascript $(".collapse").collapse({parent: "#accordion_for_collections"})
Version data entries
13 entries across 13 versions & 1 rubygems