老师用户可以对作业进行多次评价,最终评价以最后一次评价为最终结果
This commit is contained in:
parent
090ef98ec6
commit
b2f7e4d234
|
@ -1,31 +1,55 @@
|
||||||
<% is_teacher = is_course_teacher User.current,homework.bid.courses.first %>
|
<% is_teacher = is_course_teacher User.current,homework.bid.courses.first %>
|
||||||
<% if comprehensive_evaluation != nil && comprehensive_evaluation.count > 0 %>
|
<% if comprehensive_evaluation != nil && comprehensive_evaluation.count > 0 %>
|
||||||
<div style="height: 100px; padding-bottom: 10px">
|
<div style="height: <%= is_teacher ? 250 : 100%>px; padding-bottom: 10px">
|
||||||
<div style="font-size: 15px">
|
<div style="font-size: 15px">
|
||||||
<strong>作业综评:</strong>
|
<strong>作业综评:</strong>
|
||||||
<%= render :partial => 'show_score', locals: {:stars => teaher_score} %>
|
<% if teaher_score != "0.00" %>
|
||||||
|
<%= render :partial => 'show_score', locals: {:stars => teaher_score} %>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<div style="font-size: 14px;">
|
<div style="font-size: 14px;">
|
||||||
<div style="margin-left: 20px;margin-bottom: 10px;margin-top: 10px;"> <%= comprehensive_evaluation.first.notes%> </div>
|
<div style="margin-left: 20px;margin-bottom: 10px;margin-top: 10px;"> <%= comprehensive_evaluation.first.notes%> </div>
|
||||||
</div>
|
</div>
|
||||||
|
<% if is_teacher %>
|
||||||
|
<%= render :partial => 'evaluation', :locals => {:homework => homework} %>
|
||||||
|
<div>
|
||||||
|
<%= render :partial => 'evaluation_add_jour',
|
||||||
|
:locals => {:homework_attach => homework,
|
||||||
|
:sta => 0,
|
||||||
|
:is_comprehensive_evaluation => 1,
|
||||||
|
:comprehensive_evaluation => comprehensive_evaluation.first.notes} %>
|
||||||
|
</div>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<% else %>
|
<% else %>
|
||||||
<% if is_teacher %>
|
<% if is_teacher %>
|
||||||
<div style="height: 200px; padding-bottom: 10px">
|
<div style="height: 200px; padding-bottom: 10px">
|
||||||
<div style="font-size: 15px">
|
<div style="font-size: 15px">
|
||||||
<strong>作业综评:</strong>
|
<strong>作业综评:</strong>
|
||||||
|
<% if teaher_score != "0.00" %>
|
||||||
|
<%= render :partial => 'show_score', locals: {:stars => teaher_score} %>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<%= render :partial => 'evaluation', :locals => {:homework => homework} %>
|
<%= render :partial => 'evaluation', :locals => {:homework => homework} %>
|
||||||
<div>
|
<div>
|
||||||
<%= render :partial => 'evaluation_add_jour', :locals => {:homework_attach => homework, :sta => 0,:is_comprehensive_evaluation => 1} %>
|
<%= render :partial => 'evaluation_add_jour',
|
||||||
|
:locals => {:homework_attach => homework,
|
||||||
|
:sta => 0,
|
||||||
|
:is_comprehensive_evaluation => 1,
|
||||||
|
:comprehensive_evaluation => nil} %>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<% else %>
|
<% else %>
|
||||||
<div style="height: 80px; padding-bottom: 10px">
|
<div style="height: 80px; padding-bottom: 10px">
|
||||||
<div style="font-size: 15px">
|
<div style="font-size: 15px">
|
||||||
<strong>作业综评:</strong>
|
<strong>作业综评:</strong>
|
||||||
|
<% if teaher_score != "0.00" %>
|
||||||
|
<%= render :partial => 'show_score', locals: {:stars => teaher_score} %>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<div style="text-align: center;font-size: 15px;color: #15BCCC;vertical-align:middle;padding-top: 15px; "><strong>老师还未进行评价!</strong></div>
|
<% if teaher_score == "0.00" %>
|
||||||
|
<div style="text-align: center;font-size: 15px;color: #15BCCC;vertical-align:middle;padding-top: 15px; "><strong>老师还未进行评价!</strong></div>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
|
@ -1,4 +1,4 @@
|
||||||
<div style="text-align: center;">评分:
|
<div style="text-align: center;">评分:
|
||||||
<%= rating_for homework, dimension: :quality, class: 'rateable div_inline' %>
|
<%= rating_for homework, dimension: :quality, class: 'rateable div_inline' %>
|
||||||
<span style="font-size: 11px">(每个用户对每份作业只能进行一次评价!)</span>
|
<span style="font-size: 11px">(您可以对作业进行多次评价,以最后一次评价为最终结果)</span>
|
||||||
</div>
|
</div>
|
|
@ -65,10 +65,13 @@
|
||||||
<% if User.current.logged? %>
|
<% if User.current.logged? %>
|
||||||
<table border="0" width="525px" align="center" >
|
<table border="0" width="525px" align="center" >
|
||||||
<tr>
|
<tr>
|
||||||
<td><%= f.text_area 'user_message', :rows => 3, :cols => 65, :value => "#{l(:label_leave_a_message)}",
|
<td>
|
||||||
|
<%= f.text_area 'user_message', :rows => 3, :cols => 65,
|
||||||
|
:value => "#{comprehensive_evaluation.nil? ? l(:label_leave_a_message) : comprehensive_evaluation}",
|
||||||
:onfocus => "clearInfo('new_form_user_message','#{l(:label_leave_a_message)}')",
|
:onfocus => "clearInfo('new_form_user_message','#{l(:label_leave_a_message)}')",
|
||||||
:onblur => "showInfo('new_form_user_message','#{l(:label_leave_a_message)}')",
|
:onblur => "showInfo('new_form_user_message','#{l(:label_leave_a_message)}')",
|
||||||
:style => "resize: none;", :class => 'noline'%></td>
|
:style => "resize: none;", :class => 'noline'%>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<%= f.text_field :reference_user_id, :style=>"display:none"%>
|
<%= f.text_field :reference_user_id, :style=>"display:none"%>
|
||||||
|
@ -81,7 +84,8 @@
|
||||||
<%= submit_tag l(:button_clear_meassge), :name => nil, :class => "enterprise",
|
<%= submit_tag l(:button_clear_meassge), :name => nil, :class => "enterprise",
|
||||||
:onclick => "clearMessage('new_form_user_message');",
|
:onclick => "clearMessage('new_form_user_message');",
|
||||||
:onmouseout => "this.style.backgroundPosition = 'left top'",
|
:onmouseout => "this.style.backgroundPosition = 'left top'",
|
||||||
:onmouseover => "this.style.backgroundPosition = 'left -31px'" %> </td>
|
:onmouseover => "this.style.backgroundPosition = 'left -31px'" %>
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
</table>
|
</table>
|
||||||
<% else %>
|
<% else %>
|
||||||
|
|
|
@ -9,7 +9,6 @@
|
||||||
<% is_student = is_cur_course_student @homework.bid.courses.first %>
|
<% is_student = is_cur_course_student @homework.bid.courses.first %>
|
||||||
<% is_teacher = is_course_teacher User.current,@homework.bid.courses.first %>
|
<% is_teacher = is_course_teacher User.current,@homework.bid.courses.first %>
|
||||||
<p id="notice"><%= notice %></p>
|
<p id="notice"><%= notice %></p>
|
||||||
<!-- <%= image_tag(url_to_avatar(@user), :class => "avatar2") %> -->
|
|
||||||
<div style="height: auto; padding-bottom: 10px">
|
<div style="height: auto; padding-bottom: 10px">
|
||||||
<tr>
|
<tr>
|
||||||
<td colspan="2" valign="top" width="320" >
|
<td colspan="2" valign="top" width="320" >
|
||||||
|
|
Loading…
Reference in New Issue