admin global nav
This commit is contained in:
@ -11,7 +11,7 @@
|
||||
<td><%= link_to user.name, admin_user_path(user.to_i) %></td>
|
||||
<td><%= mail_to(user.email) %></td>
|
||||
<td><%= user.role %></td>
|
||||
<td><%= link_to 'edit', admin_edit_user_path(user.to_i), { class: 'btn tertiary-btn' } %></td>
|
||||
<td><%= link_to 'edit', admin_edit_user_path(user.to_i), { class: 'btn tertiary-btn' } if policy(user).edit? %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</table>
|
||||
|
@ -4,4 +4,4 @@
|
||||
|
||||
<h1>Users</h1>
|
||||
<%= render partial: 'admin/user/table_list', locals: { users: @users } %>
|
||||
<%= link_to('New User', admin_new_user_path, { class: 'btn' }) %>
|
||||
<%= link_to('New User', admin_new_user_path, { class: 'btn' }) if policy(User).create? %>
|
||||
|
Reference in New Issue
Block a user