Skip to content

Commit

Permalink
Closes #690
Browse files Browse the repository at this point in the history
  • Loading branch information
Egor Philippov committed Mar 1, 2012
1 parent 7348abf commit 69d54ef
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 18 deletions.
3 changes: 2 additions & 1 deletion app/views/results/common/_file_selector.html.erb
@@ -1,7 +1,7 @@
<% # Make sure to include the public/javascripts/Grader/file_selector.js
# file when using this partial
%>
<%= form_tag({:action => "download"}, {:id => "grader_view_file_selector_form"}) if can_download %>
<%= form_tag({:action => "download"}, {:id => "grader_view_file_selector_form"}) do %>
<%= label_tag "select_file_id", I18n.t("common.submission_file"), :class => "inline_label" %>
<input type="button" onclick="bump_select($('select_file_id'), -1); return false;" value="<-" />
<select id="select_file_id" name="select_file_id" onchange="if ($(this).getValue() != '') { load_submitted_file($(this).getValue()); }">
Expand All @@ -22,3 +22,4 @@
<%= label_tag("include_annotations", I18n.t("marker.include_annotations"), :class => "inline_label") if can_download && !files.empty? %>
<%= check_box_tag("include_annotations", true, false, :id => "include_annotations", :class => "inline_checkbox") if can_download && !files.empty? %>
<% end %>
2 changes: 1 addition & 1 deletion app/views/results/common/_rubric_criterion.html.erb
Expand Up @@ -7,7 +7,7 @@ class="mark_criterion_title_div_level" class="float_left">
<% if old_mark and !old_mark.mark.nil? %>
<div id="<%="mark_criterion_title_#{mark.id}_oldmark"%>" class="padding_left_old">
<strong>
<%= I18n.t("marker.marks.old") %>
<%= I18n.t("marker.marks.old").html_safe %>
<%= h(old_mark.mark) %>: <%= h(mark_criterion["level_" + old_mark.mark.to_i.to_s + "_name"]) %>&nbsp;
</strong>
<%= h(mark_criterion["level_" + old_mark.mark.to_i.to_s + "_description"]) %>
Expand Down
4 changes: 3 additions & 1 deletion app/views/results/edit.html.erb
Expand Up @@ -7,7 +7,9 @@
<% # UI LIBRARIES %>
<%= javascript_include_tag "livepipe/livepipe.js",
"livepipe/window.js",
"livepipe/tabs.js" %>
"livepipe/tabs.js",
"effects.js",
"dragdrop.js" %>
<%= javascript_include_tag "effects.js" %>
<%= javascript_include_tag "controls.js" %>
Expand Down
8 changes: 4 additions & 4 deletions app/views/results/marker/_marker_summary.html.erb
Expand Up @@ -38,7 +38,7 @@
</div>
<div class="clear"></div>
<div class="summary_block">
<b class="total_extra_points_label"><%= I18n.t("marker.marks.total_extra_marks") %></strong>
<b class="total_extra_points_label"><%= I18n.t("marker.marks.total_extra_marks").html_safe %></strong>
<span id="total_extra_points"><%= h(result.get_total_extra_points) %></span><br/>
</div>
<div class="clear"></div>
Expand All @@ -50,7 +50,7 @@
</div>
<div class="clear"></div>
<div class="summary_block">
<strong><%= I18n.t("marker.marks.total_extra_percentages") %></strong>
<strong><%= I18n.t("marker.marks.total_extra_percentages").html_safe %></strong>
<span id="total_extra_percentage"><%= h(result.get_total_extra_percentage) %></span><br />
<strong><%= I18n.t("marker.marks.translated_to_points") %></strong>
<span id="total_extra_percentage_as_points"><%= h(result.get_total_extra_percentage_as_points)%></span> <br />
Expand All @@ -65,7 +65,7 @@
<span> / <%= h(assignment.total_mark) %> </span>
</span>

<span><%= I18n.t("marker.marks.previous_mark") %></span>
<span><%= I18n.t("marker.marks.previous_mark").html_safe %></span>
</div>
<% end %>

Expand All @@ -75,5 +75,5 @@
<span> / <%= h(assignment.total_mark) %> </span>
</span>

<span><%= I18n.t("marker.marks.final_mark") %></span>
<span><%= I18n.t("marker.marks.final_mark").html_safe %></span>
</div>
2 changes: 1 addition & 1 deletion app/views/results/marker/_overall_comment.html.erb
Expand Up @@ -5,6 +5,6 @@
<div>
<%= f.submit t(:save_changes), :disabled => true, :id => "overall_comment_submit" %>
</div>
<% end -%>
<% end %>
</div>
</div>
2 changes: 1 addition & 1 deletion app/views/results/student/_student_summary.html.erb
Expand Up @@ -37,7 +37,7 @@
:locals => {:extra_marks_points => extra_marks_points, :result_id => result.id} %>

<div>
<div class="float_left"><strong><%= I18n.t("marker.marks.bonus_marks") %></strong></div>
<div class="float_left"><strong><%= I18n.t("marker.marks.bonus_marks").html_safe %></strong></div>
<div class="float_left" id="extra_marks_bonus"><%= h(result.get_positive_extra_points) %></div>
</div>
<div class="clear"></div>
Expand Down
19 changes: 10 additions & 9 deletions config/routes.rb
Expand Up @@ -128,26 +128,27 @@

resources :results do
collection do
get 'update_mark'
get 'expand_criteria'
post 'update_mark'
post 'expand_criteria'
end

member do
get 'add_extra_marks'
get 'add_extra_mark'
get 'download'
post 'download'
get 'cancel_remark_request'
get 'codeviewer'
post 'codeviewer'
get 'collapse_criteria'
get 'add_extra_mark'
post 'collapse_criteria'
post 'add_extra_mark'
get 'next_grouping'
get 'remove_extra_mark'
get 'expand_unmarked_criteria'
post 'remove_extra_mark'
post 'expand_unmarked_criteria'
get 'set_released_to_students'
get 'update_overall_comment'
get 'update_overall_remark_comment'
get 'update_marking_state'
post 'update_overall_comment'
post 'update_overall_remark_comment'
post 'update_marking_state'
get 'update_remark_request'
get 'render_test_result'
get 'update_positions'
Expand Down

0 comments on commit 69d54ef

Please sign in to comment.