|
3 | 3 | <% end %> |
4 | 4 |
|
5 | 5 | <% if @borrow_policies.any? %> |
6 | | - <div class="responsive-table eight-columns"> |
7 | | - <%= tag.div "Name", class: "responsive-table-header" %> |
8 | | - <%= tag.div "Duration", class: "responsive-table-header" %> |
9 | | - <%= tag.div "Fine", class: "responsive-table-header" %> |
10 | | - <%= tag.div "Fine Period", class: "responsive-table-header" %> |
11 | | - <%= tag.div "Uniquely Numbered", class: "responsive-table-header" %> |
12 | | - <%= tag.div "Consumable", class: "responsive-table-header" %> |
13 | | - <%= tag.div "Default", class: "responsive-table-header" %> |
14 | | - <%= tag.div "Requires Approval", class: "responsive-table-header" %> |
| 6 | + <table class="table"> |
| 7 | + <thead> |
| 8 | + <th>Name</th> |
| 9 | + <th>Duration</th> |
| 10 | + <th>Fine</th> |
| 11 | + <th>Fine Period</th> |
| 12 | + <th>Uniquely Numbered</th> |
| 13 | + <th>Consumable</th> |
| 14 | + <th>Default</th> |
| 15 | + <th>Requires Approval</th> |
| 16 | + <th>Requested Approvals</th> |
| 17 | + </thead> |
| 18 | + <tbody> |
| 19 | + <% @borrow_policies.each do |borrow_policy| %> |
| 20 | + <tr> |
| 21 | + <td> |
| 22 | + <%= link_to "#{borrow_policy.code} #{borrow_policy.name}", admin_borrow_policy_path(borrow_policy) %> |
| 23 | + </td> |
15 | 24 |
|
16 | | - <% @borrow_policies.each do |borrow_policy| %> |
17 | | - <%= tag.div class: "responsive-table-cell" do %> |
18 | | - <%= link_to "#{borrow_policy.code} #{borrow_policy.name}", admin_borrow_policy_path(borrow_policy) %> |
| 25 | + <td><%= borrow_policy.duration %></td> |
| 26 | + <td><%= borrow_policy.fine %></td> |
| 27 | + <td><%= borrow_policy.fine_period %></td> |
| 28 | + <td><%= borrow_policy.uniquely_numbered %></td> |
| 29 | + <td><%= borrow_policy.consumable %></td> |
| 30 | + <td><%= borrow_policy.default %></td> |
| 31 | + <td><%= borrow_policy.requires_approval %></td> |
| 32 | + <td><%= link_to borrow_policy.borrow_policy_approvals.requested.count, admin_borrow_policy_borrow_policy_approvals_path(borrow_policy) %></td> |
| 33 | + </tr> |
19 | 34 | <% end %> |
20 | | - <%= tag.div borrow_policy.duration, class: "responsive-table-cell" %> |
21 | | - <%= tag.div borrow_policy.fine, class: "responsive-table-cell" %> |
22 | | - <%= tag.div borrow_policy.fine_period, class: "responsive-table-cell" %> |
23 | | - <%= tag.div borrow_policy.uniquely_numbered, class: "responsive-table-cell" %> |
24 | | - <%= tag.div borrow_policy.consumable, class: "responsive-table-cell" %> |
25 | | - <%= tag.div borrow_policy.default, class: "responsive-table-cell" %> |
26 | | - <%= tag.div borrow_policy.requires_approval, class: "responsive-table-cell" %> |
27 | | - <% end %> |
28 | | - </div> |
29 | | - |
| 35 | + </tbody> |
| 36 | + </table> |
30 | 37 | <% else %> |
31 | 38 | <%= empty_state "There are no borrow policies." %> |
32 | 39 | <% end %> |
0 commit comments