parent
34b254b9c8
commit
72da250706
@ -0,0 +1,52 @@
|
||||
|
||||
<p class="pt20 pb20 font-16"><span class="modalTitle">翻转课堂</span></p>
|
||||
<table width="100%" class="tBodyScroll edu-txt-center" cellpadding="0" cellspacing="0">
|
||||
<thead class="lastPart">
|
||||
<tr>
|
||||
<th width="10%">创建者</th>
|
||||
<th width="40%" class="edu-txt-left">名称</th>
|
||||
<th width="10%">学生数量</th>
|
||||
<th width="15%">发布的实训作业数量</th>
|
||||
<th width="10%" data-tip-down="至少完成了1个关卡">有效作品数</th>
|
||||
<th width="15%">经验值</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<%
|
||||
total_members_count = 0
|
||||
total_shixun_homework_count = 0
|
||||
total_course_score = 0
|
||||
%>
|
||||
<% @courses.each do |course| %>
|
||||
<%
|
||||
total_members_count += course.members_count.to_i
|
||||
total_shixun_homework_count += course['shixun_homework_count'].to_i
|
||||
|
||||
score = 500 + 5 * @course_shixun_count_map.fetch(course.id, 0) * @course_myshixun_map.fetch(course.id, 0)
|
||||
total_course_score += score
|
||||
%>
|
||||
<tr>
|
||||
<td width="10%"><%= course.teachers.where(user_id: @team_user_ids).first.user.show_real_name %></td>
|
||||
<td width="40%" class="edu-txt-left">
|
||||
<%= link_to course_path(course), target: '_blank' do %>
|
||||
<span class="task-hide fl" style="max-width: 480px;"><%= course.name %></span>
|
||||
<% end %>
|
||||
</td>
|
||||
<td width="10%"><%= course.members_count %></td>
|
||||
<td width="15%"><%= course['shixun_homework_count'].presence || '--' %></td>
|
||||
<td width="10%"><%= @course_myshixun_map.fetch(course.id, '--') %></td>
|
||||
<td width="15%"><%= score.zero? ? '--' : score %></td>
|
||||
</tr>
|
||||
<% end %>
|
||||
</tbody>
|
||||
<tfoot class="tfootLastPart">
|
||||
<tr class="color-orange font-16">
|
||||
<th width="10%" class="color-grey-6">合计</th>
|
||||
<th width="40%" class="edu-txt-left"><%= @courses.size %></th>
|
||||
<th width="10%"><%= total_members_count %></th>
|
||||
<th width="15%"><%= total_shixun_homework_count %></th>
|
||||
<th width="10%"><%= @course_myshixun_map.values.reduce(:+) || 0 %></th>
|
||||
<th width="15%"><%= total_course_score %></th>
|
||||
</tr>
|
||||
</tfoot>
|
||||
</table>
|
@ -0,0 +1 @@
|
||||
$('.competition-detail-course').html("<%= j(render :partial => 'competition_team_detail_course') %>");
|
@ -0,0 +1 @@
|
||||
$('.competition-detail-shixun').html("<%= j(render :partial => 'competition_team_detail_shixun') %>");
|
Loading…
Reference in new issue