Sha256: 95e9a7bbefd2b10ab5ddda8f77370ce7ff74a5ab9f12b00f221cac3aff2a5a07

Contents?: true

Size: 732 Bytes

Versions: 12

Compression:

Stored size: 732 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_comfy_admin_cms_site_category_path(@site, category), :remote => true
    = link_to comfy_admin_cms_site_category_path(@site, category), :method => :delete, :remote => true, :data => {:confirm => t('.are_you_sure')}, :class => 'delete' do
      %i.glyphicon.glyphicon-remove-circle

Version data entries

12 entries across 12 versions & 1 rubygems

Version Path
comfortable_mexican_sofa-1.12.11 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.10 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.9 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.8 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.7 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.6 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.5 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.4 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.3 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.2 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.1 app/views/comfy/admin/cms/categories/_show.html.haml
comfortable_mexican_sofa-1.12.0 app/views/comfy/admin/cms/categories/_show.html.haml