index.html.slim 854 Bytes
Newer Older
Chrysanthi Lagodimou's avatar
Chrysanthi Lagodimou committed
1
h1= t('.group_offer_categories')
Markus Koller's avatar
Markus Koller committed
2 3

ul.list-inline
4
  li= button_link icon_span(:back), group_offers_path
5 6
  - if policy(GroupOfferCategory).new?
    li= form_navigation_btn :new, with_row: false
Tugce Nur Tas's avatar
Tugce Nur Tas committed
7

8 9 10 11
.table-responsive
  table.table.table-striped
    thead
      tr
12 13 14
        th= sort_link @q, :category_name, t_attr(:category_name)
        th= sort_link @q, :description, 'Beschreibung'
        th= sort_link @q, :category_state, t_attr(:category_state)
15 16
        - if policy(GroupOfferCategory).edit?
          th
Tugce Nur Tas's avatar
Tugce Nur Tas committed
17

18 19
    tbody
      - @group_offer_categories.each do |category|
Tugce Nur Tas's avatar
Tugce Nur Tas committed
20 21
          tr
            td= category.category_name
22
            td= category.description
Chrysanthi Lagodimou's avatar
Chrysanthi Lagodimou committed
23
            td= t(".category_states.#{category.category_state}")
24 25
            - if policy(GroupOfferCategory).edit?
              td= link_to t_action(:edit), edit_group_offer_category_path(category)