Sha256: d697c6e3b4dc055bec00c0bf7f43ce778fe8e95f3054894eea298f62690cbfe9

Contents?: true

Size: 649 Bytes

Versions: 10

Compression:

Stored size: 649 Bytes

Contents

- object = form.object
- if (categories = @site.categories.of_type(object.class.to_s)).present?
  = form.form_group label: {text: t('.label')}, class: "categories" do
    - categories.each do |category|
      - name = "#{object.class.to_s.demodulize.underscore.downcase}[category_ids][#{category.id}]"
      = hidden_field_tag name, 0, id: nil
      .form-check.form-check-inline
        %label.form-check-label
          - name = "#{object.class.to_s.demodulize.underscore.downcase}[category_ids][#{category.id}]"
          = check_box_tag name, 1, object.categories.member?(category), id: nil, class: 'form-check-input'
          = category.label

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
comfortable_mexican_sofa-2.0.9 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.8 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.7 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.6 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.5 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.4 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.3 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.2 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.1 app/views/comfy/admin/cms/categories/_form.html.haml
comfortable_mexican_sofa-2.0.0 app/views/comfy/admin/cms/categories/_form.html.haml