|
|
|
@ -8,7 +8,6 @@
|
|
|
|
|
</style>
|
|
|
|
|
<% is_student = is_cur_course_student? @homework.bid.courses.first %>
|
|
|
|
|
<% is_teacher = is_course_teacher User.current,@homework.bid.courses.first %>
|
|
|
|
|
|
|
|
|
|
<p id="notice"><%= notice %></p>
|
|
|
|
|
<!-- <%= image_tag(url_to_avatar(@user), :class => "avatar2") %> -->
|
|
|
|
|
<div style="height: auto; padding-bottom: 10px">
|
|
|
|
@ -29,8 +28,12 @@
|
|
|
|
|
<tr>
|
|
|
|
|
<td style="padding-left: 40px">
|
|
|
|
|
<span>作业下载:</span>
|
|
|
|
|
<% options = {:author => true } %>
|
|
|
|
|
<%= render :partial => 'app_link', :locals => {:attachments => @homework.attachments, :options => options} %>
|
|
|
|
|
<% if @is_evaluation || is_teacher%>
|
|
|
|
|
<% options = {:author => true } %>
|
|
|
|
|
<%= render :partial => 'app_link', :locals => {:attachments => @homework.attachments, :options => options} %>
|
|
|
|
|
<% else %>
|
|
|
|
|
<%= l(:label_cant_download) %>
|
|
|
|
|
<% end %>
|
|
|
|
|
</td>
|
|
|
|
|
<td style="width: 240px; word-wrap: break-word; word-break: break-all">
|
|
|
|
|
所属任务:<%= link_to(@homework.bid.name, project_for_bid_path(@homework.bid))%>
|
|
|
|
@ -133,10 +136,19 @@
|
|
|
|
|
<div style="height: 50px">
|
|
|
|
|
<div style="font-size: 15px"><strong>作业评论:</strong></div>
|
|
|
|
|
<% if is_student %>
|
|
|
|
|
<div style="text-align: center;">评分:
|
|
|
|
|
<%= rating_for @homework, dimension: :quality, class: 'rateable div_inline' %>
|
|
|
|
|
<span style="font-size: 11px">(您可以重新打分,打分结果以最后一次打分为主!)</span>
|
|
|
|
|
</div>
|
|
|
|
|
<% if @is_evaluation %>
|
|
|
|
|
<% if @has_evaluation %>
|
|
|
|
|
<div style="text-align: center;">
|
|
|
|
|
<%= l(:lable_has_evaluation)%>
|
|
|
|
|
</div>
|
|
|
|
|
<% else %>
|
|
|
|
|
<%= render :partial => 'evaluation', :locals => {:homework => @homework} %>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% else %>
|
|
|
|
|
<div style="text-align: center;">
|
|
|
|
|
<%= l(:lable_close_evaluation)%>
|
|
|
|
|
</div>
|
|
|
|
|
<% end %>
|
|
|
|
|
<% end %>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|