学生打开新建的作业列表报500

This commit is contained in:
cxt 2016-05-13 14:40:28 +08:00
parent 7759670fa1
commit 01287ff93c
1 changed files with 1 additions and 1 deletions

View File

@ -56,8 +56,8 @@
<% else %>
<% work= params[:show_work_id].nil? ? @homework.student_works.where("user_id = ?",User.current.id).first : StudentWork.find(params[:show_work_id]) %>
<% end %>
location.hash = "<%=work.id %>";
<% unless work.nil? %>
location.hash = "<%=work.id %>";
<% if @homework.homework_type == 2 %>
$("#about_hwork_<%= work.id%>").html("<%= escape_javascript(render :partial => 'programing_work_show',:locals => {:work =>work,:score =>student_work_score(work,User.current),:student_work_scores => work.student_works_scores.order("updated_at desc"),:is_focus => @is_focus}) %>");