Sha256: 1d539b3c54a74f793de823b6adf14160d80daa3c50826dada482dfc51d1b0462

Contents?: true

Size: 705 Bytes

Versions: 7

Compression:

Stored size: 705 Bytes

Contents

- category ||= show
- read ||= false
- categories = [params[:category]].flatten.compact
- active = categories.flatten.member?(category.label)

.category{:class => (read && active ? 'active' : nil), :id => dom_id(category)}
  - if read
    - categories = active ? categories.reject{|c| c == category.label} : categories << category.label
    = link_to category.label, "?#{{:category => categories}.to_param}"
  - else
    = link_to category.label, edit_admin_cms_site_category_path(@site, category), :remote => true
    = link_to admin_cms_site_category_path(@site, category), :method => :delete, :remote => true, :data => {:confirm => t('.are_you_sure')}, :class => 'delete' do
      %i.icon-remove-circle

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
comfortable_mexican_sofa-1.11.2 app/views/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.11.1 app/views/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.11.0 app/views/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.10.3 app/views/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.10.2 app/views/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.10.1 app/views/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.10.0 app/views/admin/cms/categories/_show.html.haml