1
0
Fork 0
This repository has been archived on 2023-03-27. You can view files and clone it, but cannot push or open issues or pull requests.
lpr-partynest/app/views/staffs/relation_statuses/_table.html.erb

38 lines
1.1 KiB
Text

<table class="table">
<thead>
<tr>
<th scope="col">
<%= RelationStatus.human_attribute_name :org_unit_kind %>
</th>
<th scope="col">
<%= RelationStatus.human_attribute_name :codename %>
</th>
<th scope="col">
<%= RelationStatus.human_attribute_name :name %>
</th>
<th scope="col"></th>
</tr>
</thead>
<tbody>
<% relation_statuses.each do |relation_status| %>
<tr>
<td scope="row">
<% if policy([:staff, relation_status.org_unit_kind]).show? %>
<%= link_to relation_status.org_unit_kind.short_name,
[:staff, relation_status.org_unit_kind] %>
<% else %>
<%= relation_status.org_unit_kind.short_name %>
<% end %>
</td>
<td><%= relation_status.codename %></td>
<td><%= relation_status.name %></td>
<td>
<% if policy([:staff, relation_status]).show? %>
<%= open_action [:staff, relation_status] %>
<% end %>
</td>
</tr>
<% end %>
</tbody>
</table>