<% revise_attachment = work.attachments.where("attachtype = 7").first %> <% if @homework.end_time < Date.today %> <% if revise_attachment && work.user != User.current %>
作业修订附件
追加附件: <%= render :partial => 'work_attachments_status', :locals => {:attachments => work.attachments.where("attachtype = 7"), :status => 2} %> <% unless revise_attachment.description == "" %> 追加理由:

<%=revise_attachment.description %>

<% end %>
注意:此处的附件是在作业截止日期过后提交的
<% end %> <% if work.user == User.current && !User.current.allowed_to?(:as_teacher, @homework.course) %>
作业修订附件
<% if revise_attachment %>
追加附件: <%= render :partial => 'work_attachments_status', :locals => {:attachments => work.attachments.where("attachtype = 7"), :status => 1} %> <% unless revise_attachment.description == "" %> 追加理由:

<%=revise_attachment.description %>

<% end %>
注意:此处的附件是在作业截止日期过后提交的
<% end %>
上传附件
<% end %> <% end %>