提交成绩后,列表成绩没刷新修改;分组作业列表宽度调整

This commit is contained in:
Tim 2016-05-20 20:05:39 +08:00
parent 1c7efa247e
commit 5f4a9304fe
5 changed files with 9 additions and 6 deletions

View File

@ -17,7 +17,7 @@
<% end%>
</th>
<% elsif @homework.homework_type == 3 && @homework.homework_detail_group.base_on_project == 1 %>
<th class="hworkList160">
<th class="<%=@homework.anonymous_comment == 1 ? 'hworkList220' : 'hworkList160'%>">
<span class="c_dark f14 fb">关联项目</span>
</th>
<% end %>

View File

@ -1,6 +1,6 @@
<!-- 匿评作品列表,显示某一个作品的信息 -->
<a name="<%= student_work.id%>"></a>
<tr class="hworkListRow" id="student_work_<%= student_work.id%>">
<td class="none"><a name="<%= student_work.id%>"></a></td>
<td class="hworkList30 pl5 pr5" id="work_num_<%=student_work.id %>"><%=index + 1 %></td>
<td class="hworkPortrait pr10 float-none">
<%= link_to(image_tag(url_to_avatar(student_work.user),:width =>"40",:height => "40",:style => "display:block;"),user_activities_path(student_work.user)) %>
@ -20,7 +20,7 @@
</td>
<% elsif @homework.homework_type == 3 && @homework.homework_detail_group.base_on_project == 1 %>
<% if student_work.project.is_public || User.current.member_of?(student_work.project) || User.current.admin? %>
<td class="hworkPrName student_work_<%= student_work.id%>" title="项目名称">
<td class="<%=@homework.anonymous_comment == 1 ? 'hworkPrName2' : 'hworkPrName'%> student_work_<%= student_work.id%>" title="项目名称">
<%= link_to( student_work.project.name, project_path(student_work.project.id))%>
</td>
<% else %>

View File

@ -1,5 +1,6 @@
<!-- 匿评作品列表,显示某一个作品的信息 -->
<tr class="hworkListRow" id="student_work_<%= student_work.id%>">
<td class="none"><a name="<%= student_work.id%>"></a></td>
<% if @homework.homework_type != 3 %>
<% is_my_work = student_work.user == User.current%>
<% else %>

View File

@ -11,9 +11,9 @@ var num = $("#work_num_<%= @work.id%>").html();
$("#score_list_<%= @work.id%>").removeAttr("style");
<% if @is_teacher %>
$("tr[id='"+student_work_<%= @work.id%>+"']").replaceWith("<%= escape_javascript(render :partial => 'evaluation_un_work',:locals => {:student_work => @work, :index => 1}) %>");
$("tr[id='student_work_<%= @work.id%>']").replaceWith("<%= escape_javascript(render :partial => 'evaluation_un_work',:locals => {:student_work => @work, :index => 1}) %>");
$("#work_num_<%= @work.id%>").html(num);
<% else %>
$("tr[id='"+student_work_<%= @work.id%>+"']").replaceWith("<%= escape_javascript(render :partial => 'evaluation_work',:locals => {:student_work => @work, :index => 1}) %>");
$("tr[id='student_work_<%= @work.id%>']").replaceWith("<%= escape_javascript(render :partial => 'evaluation_work',:locals => {:student_work => @work, :index => 1}) %>");
$("#work_num_<%= @work.id%>").html(num);
<% end%>

View File

@ -59,6 +59,7 @@ a:hover.news_foot{ color:#787b7e; border:1px solid #d4d4d4;}
.hworkList100 {width:100px; text-align:center;}
.hworkList130 {width:130px; text-align:center;}
.hworkList160 {width:160px; text-align:center;}
.hworkList220 {width:220px; text-align:center;}
.hworkList260 {width:260px; text-align:left;}
.codeList{ float:right; font-size:12px; color:#484848; padding:0px 3px; width:714px; margin-bottom:10px; }
.hworkName {width:80px; float:left; line-height:18px;}
@ -1250,7 +1251,8 @@ a:hover.blueCir{ background:#3598db; color:#fff;}
.ml7 {margin-left:7px;}
.tac {text-align:center;}
.proHelp {background:url(/images/course/hwork_icon.png) -5px -124px no-repeat; display:inline-block; width:15px; height:15px; display:inline-block;}
.hworkPrName {width:160px; max-width:160px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis; float:left; height:65px; line-height:65px; vertical-align:middle; font-size:12px; color:#888888; text-align:center;}
.hworkPrName {width:160px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis; float:left; height:65px; line-height:65px; vertical-align:middle; font-size:12px; color:#888888; text-align:center;}
.hworkPrName2 {width:220px; overflow:hidden; white-space: nowrap; text-overflow:ellipsis; float:left; height:65px; line-height:65px; vertical-align:middle; font-size:12px; color:#888888; text-align:center;}
.mr150 {margin-right:150px;}
.relatePInfo {text-align: left; position:absolute; background-color:#ffffff; padding:3px 8px; white-space:nowrap; box-shadow:0px 2px 8px rgba(146, 153, 169, 0.5); z-index:999; color:#585858; cursor:pointer; display:none;}
.captainName {max-width:75px; white-space: nowrap; text-overflow: ellipsis; overflow: hidden; display: inline-block;}