作业积分的弹出框增加序号、导出的学生列表中去掉未发布的作业、弹框高度控制
This commit is contained in:
parent
8f9ead0a12
commit
6479ace5e1
|
@ -341,7 +341,7 @@ class CoursesController < ApplicationController
|
|||
|
||||
def export_course_member_excel
|
||||
@all_members = student_homework_score(0,0,0,"desc")
|
||||
@homeworks = @course.homework_commons.order("created_at asc")
|
||||
@homeworks = @course.homework_commons.where("publish_time <= '#{Date.today}'").order("created_at asc")
|
||||
filename="#{@course.teacher.lastname.to_s + @course.teacher.firstname.to_s }_#{@course.name}_#{@course.time.to_s + @course.term}#{l(:excel_member_list)}";
|
||||
|
||||
respond_to do |format|
|
||||
|
|
|
@ -8,19 +8,19 @@
|
|||
|
||||
|
||||
.tscore_con h2{ display:block; background:#eaeaea; font-size:14px; color:#343333; height:31px; width: auto; text-align: center; padding-top:5px;}
|
||||
.tscore_box{ width:350px; margin:15px auto;}
|
||||
.tscore_box{ width:370px; margin:15px auto;}
|
||||
.tscore_box li{ height:25px;}
|
||||
</style>
|
||||
|
||||
|
||||
<div class="tscore_con" id="user_score">
|
||||
<h2><%= @member_score.user.name %> 历次作业积分</h2>
|
||||
<ul class="tscore_box">
|
||||
<ul class="tscore_box" style="max-height: 400px; overflow: auto;">
|
||||
<li ><span class="c_blue02 w280">作业名称</span><span class="c_blue02 w70">得分</span></li>
|
||||
<% @member_score.homework_common_list.each do |homework_common| %>
|
||||
<% @member_score.homework_common_list.each_with_index do |homework_common, index| %>
|
||||
<li>
|
||||
<span class="c_grey02 w280 hiddent">
|
||||
<%= homework_common.name %>
|
||||
作业<%=index + 1 %>:<%= homework_common.name %>
|
||||
</span>
|
||||
<span class="c_red w70">
|
||||
<% final_score = @member_score.homework_common_score(homework_common).first%>
|
||||
|
|
Loading…
Reference in New Issue