更改:时间显示不正确

This commit is contained in:
yystopf 2026-07-30 08:38:58 +08:00
parent 88eab534cd
commit 1ad5b90dd5
3 changed files with 37 additions and 2 deletions

View File

@ -22,7 +22,7 @@
<td>
<%= raw action.action_info %>
</td>
<td><%= display_text(action.created_at&.utc.strftime('%Y-%m-%d %H:%M')) %></td>
<td><%= display_text(action.created_at&.strftime('%Y-%m-%d %H:%M')) %></td>
<td><%= action.memo %></td>
</tr>
<% end %>

View File

@ -0,0 +1,35 @@
<table class="table table-hover users-list-table">
<thead class="thead-light">
<tr>
<th width="5%" class="text-center">序号</th>
<th width="10%">操作类型</th>
<th width="10%" class="text-left">操作人账号</th>
<th width="25%" class="text-left">关联基本信息</th>
<th width="15%">操作时间</th>
<th width="35%">原因/备注</th>
</tr>
</thead>
<tbody>
<% if user_actions.present? %>
<% user_actions.each_with_index do |action, index| %>
<tr class="user-item-<%= action.user&.id %>">
<td class="text-center"><%= list_index_no((params[:page] || 1).to_i, index) %></td>
<td><%= action.action_name %></td>
<td>
<%= link_to "/#{action.user&.login}", target: '_blank' do %>
<%= overflow_hidden_span action.opt_user_name, width: 100 %>
<% end %></td>
<td>
<%= raw action.action_info %>
</td>
<td><%= display_text(action.created_at&.utc.strftime('%Y-%m-%d %H:%M')) %></td>
<td><%= action.memo %></td>
</tr>
<% end %>
<% else %>
<%= render 'admins/shared/no_data_for_table' %>
<% end %>
</tbody>
</table>
<%= render partial: 'admins/shared/paginate', locals: { objects: user_actions } %>

View File

@ -15,7 +15,7 @@
</div>
<div class="box admin-list-container users-list-container">
<%= render partial: 'admins/user_actions/user_action_list', locals: { user_actions: @user_actions } %>
<%= render partial: 'admins/user_actions/user_action_list_1', locals: { user_actions: @user_actions } %>
</div>
<script>