mirror of
https://gitlink.org.cn/Gitlink/forgeplus.git
synced 2026-05-03 20:00:49 +08:00
init project
This commit is contained in:
40
app/views/admins/user_statistics/shared/_list.html.erb
Normal file
40
app/views/admins/user_statistics/shared/_list.html.erb
Normal file
@@ -0,0 +1,40 @@
|
||||
<table class="table table-hover text-center user-statistic-list-table">
|
||||
<thead class="thead-light">
|
||||
<tr>
|
||||
<th width="4%">序号</th>
|
||||
<th width="14%" class="text-left">姓名</th>
|
||||
<th width="22%" class="text-left">单位部门</th>
|
||||
<th width="10%">学习关卡数<%#= sort_tag('学习关卡数', name: 'study_challenge_count', path: admins_user_statistics_path) %></th>
|
||||
<th width="9%">完成关卡数<%#= sort_tag('完成关卡数', name: 'finish_challenge_count', path: admins_user_statistics_path) %></th>
|
||||
<th width="9%"><%= sort_tag('学习实训数', name: 'study_shixun_count', path: admins_user_statistics_path) %></th>
|
||||
<th width="9%"><%= sort_tag('完成实训数', name: 'finish_shixun_count', path: admins_user_statistics_path) %></th>
|
||||
<th width="9%">评测次数</th>
|
||||
<th width="14%">实战时间</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<% if users.present? %>
|
||||
<% users.each_with_index do |user, index| %>
|
||||
<tr class="user-statistic-item-<%= user.id %>">
|
||||
<td><%= list_index_no((params[:page] || 1).to_i, index) %></td>
|
||||
<td class="text-left">
|
||||
<%= link_to "/users/#{user.login}", target: '_blank' do %>
|
||||
<%= overflow_hidden_span user.real_name, width: 100 %>
|
||||
<% end %>
|
||||
</td>
|
||||
<td class="text-left"><%= display_text [user.school_name.presence, user.department_name.presence].compact.join(' - ') %></td>
|
||||
<td><%= user.display_extra_data(:study_challenge_count) %></td>
|
||||
<td><%= user.display_extra_data(:finish_challenge_count) %></td>
|
||||
<td><%= user.display_extra_data(:study_shixun_count) %></td>
|
||||
<td><%= user.display_extra_data(:finish_shixun_count) %></td>
|
||||
<td><%= user.display_extra_data(:evaluate_count) %></td>
|
||||
<td><%= Util.display_cost_time(user.display_extra_data(:cost_time)) || '--' %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
<% else %>
|
||||
<%= render 'admins/shared/no_data_for_table' %>
|
||||
<% end %>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<%= render partial: 'admins/shared/paginate', locals: { objects: users } %>
|
||||
Reference in New Issue
Block a user