|
1 | 1 | <% set_page_title 'Users' %> |
2 | | - |
3 | 2 | <div class="container-fluid"> |
4 | 3 | <h1 class="text-center"><%= t('.page_title') %></h1> |
5 | | - |
6 | 4 | <hr> |
7 | | - |
8 | 5 | <div class="row"> |
9 | | - <div class="col-sm-9"><%= link_to t('.new_user'), lcms_engine.new_admin_user_path, class: 'btn btn-success' %></div> |
10 | | - <div class="col-sm-3"><%= render 'search_form' %></div> |
11 | | - |
| 6 | + <div class="col-12"><%= render 'search_form' %></div> |
| 7 | + <div class="col-12"><%= link_to t('.new_user'), lcms_engine.new_admin_user_path, class: 'btn btn-success' %></div> |
12 | 8 | </div> |
13 | | - |
14 | 9 | <hr> |
15 | | - |
16 | 10 | <div class="row"> |
17 | 11 | <table class="table"> |
18 | 12 | <tr> |
19 | | - <th><%= t('.id') %> |
20 | | - <th><%= t('.name') %> |
21 | | - <th><%= t('.email') %> |
22 | | - <th><%= t('.role') %> |
23 | | - <th><%= t('.access_code') %> |
24 | | - <th><%= t('.confirmed') %> |
25 | | - <th><%= t('.registration') %> |
26 | | - <th> |
27 | | - <th> |
| 13 | + <th><%= t('.id') %></th> |
| 14 | + <th><%= t('.name') %></th> |
| 15 | + <th><%= t('.email') %></th> |
| 16 | + <th><%= t('.role') %></th> |
| 17 | + <th><%= t('.access_code') %></th> |
| 18 | + <th><%= t('.confirmed') %></th> |
| 19 | + <th><%= t('.registration') %></th> |
| 20 | + <th></th> |
| 21 | + <th></th> |
28 | 22 | </tr> |
29 | | - |
30 | 23 | <% @users.each do |user| %> |
31 | 24 | <% cache user do %> |
32 | 25 | <tr id="user_<%= user.id %>"> |
33 | | - <td><%= link_to user.id, lcms_engine.edit_admin_user_path(user) %> |
34 | | - <td><%= link_to user.name, lcms_engine.edit_admin_user_path(user) %> |
35 | | - <td><%= user.email %> |
36 | | - <td><%= user.role %> |
37 | | - <td><%= user.access_code.presence || '-' %> |
38 | | - <td><%= user.confirmed? ? 'YES' : 'NO' %> |
39 | | - <td class="u-txt--small"><%= user.created_at.to_s %> |
40 | | - <td><%= button_to t('.reset_password_btn'), lcms_engine.reset_password_admin_user_path(user), class: 'btn btn-warning', data: { confirm: t('ui.are_you_sure') }, form_class: 'inline', method: :post %> |
41 | | - <td><%= button_to t('ui.delete'), lcms_engine.admin_user_path(user), class: 'btn btn-danger', data: { confirm: t('ui.are_you_sure'), 'turbo-method': :delete }, form_class: 'inline', method: :delete %></td> |
| 26 | + <td><%= link_to user.id, lcms_engine.edit_admin_user_path(user) %></td> |
| 27 | + <td><%= link_to user.name, lcms_engine.edit_admin_user_path(user) %></td> |
| 28 | + <td><%= user.email %></td> |
| 29 | + <td><%= user.role %></td> |
| 30 | + <td><%= user.access_code.presence || '-' %></td> |
| 31 | + <td><%= user.confirmed? ? 'YES' : 'NO' %></td> |
| 32 | + <td class="u-txt--small"><%= user.created_at.to_s %></td> |
| 33 | + <td><%= button_to t('.reset_password_btn'), lcms_engine.reset_password_admin_user_path(user), class: 'btn btn-warning btn-sm', data: { confirm: t('ui.are_you_sure') }, form_class: 'inline', method: :post %></td> |
| 34 | + <td><%= button_to t('ui.delete'), lcms_engine.admin_user_path(user), class: 'btn btn-danger btn-sm', data: { confirm: t('ui.are_you_sure'), 'turbo-method': :delete }, form_class: 'inline', method: :delete %></td> |
42 | 35 | </tr> |
43 | 36 | <% end %> |
44 | 37 | <% end %> |
45 | 38 | </table> |
46 | 39 | </div> |
47 | | - |
48 | 40 | <div class="row"> |
49 | 41 | <%= will_paginate @users, list_classes: %w(pagination d-flex justify-content-center) %> |
50 | 42 | </div> |
|
0 commit comments