Restyle creates a combined results view
This commit is contained in:
@@ -591,15 +591,22 @@ class CombinedOpenEndedV1Module():
|
||||
for ri in all_responses:
|
||||
for i in xrange(0,len(ri['rubric_scores'])):
|
||||
feedback = ri['feedback_dicts'][i].get('feedback','')
|
||||
rubric_data = self.rubric_renderer.render_rubric(stringify_children(self.static_data['rubric']), ri['rubric_scores'][i])
|
||||
if rubric_data['success']:
|
||||
rubric_html = rubric_data['html']
|
||||
else:
|
||||
rubric_html = ''
|
||||
context = {
|
||||
'rubric_html': self.rubric_renderer.render_rubric(stringify_children(self.static_data['rubric']), ri['rubric_scores'][i]),
|
||||
'rubric_html': rubric_html,
|
||||
'grader_type': ri['grader_type'],
|
||||
'grader_type_image_dict' : GRADER_TYPE_IMAGE_DICT,
|
||||
'human_grader_types' : HUMAN_GRADER_TYPE,
|
||||
'feedback' : feedback,
|
||||
}
|
||||
context_list.append(context)
|
||||
feedback_table = self.system.render_template('open_ended_result_table.html', {'context_list' : context_list})
|
||||
feedback_table = self.system.render_template('open_ended_result_table.html', {
|
||||
'context_list' : context_list,
|
||||
'grader_type_image_dict' : GRADER_TYPE_IMAGE_DICT,
|
||||
'human_grader_types' : HUMAN_GRADER_TYPE,
|
||||
})
|
||||
context = {
|
||||
'results': feedback_table,
|
||||
'task_name' : "Combined Results",
|
||||
|
||||
@@ -119,6 +119,7 @@ div.combined-rubric-container {
|
||||
}
|
||||
}
|
||||
}
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
div.result-container {
|
||||
@@ -252,6 +253,11 @@ div.result-container {
|
||||
}
|
||||
}
|
||||
}
|
||||
.rubric-result {
|
||||
font-size: .9em;
|
||||
padding: 2px;
|
||||
display: inline-table;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -1,14 +1,21 @@
|
||||
% for context in context_list:
|
||||
% if context['grader_type'] in grader_type_image_dict:
|
||||
% for co in context_list:
|
||||
% if co['grader_type'] in grader_type_image_dict:
|
||||
<%grader_type=co['grader_type']%>
|
||||
<% grader_image = grader_type_image_dict[grader_type] %>
|
||||
% if grader_type in human_grader_types:
|
||||
<% human_title = human_grader_types[grader_type] %>
|
||||
% else:
|
||||
<% human_title = grader_type %>
|
||||
% endif
|
||||
<img src="${grader_image}" title="${human_title}"/>
|
||||
% endif
|
||||
${rubric_html}
|
||||
${feedback}
|
||||
<div class="rubric-result">
|
||||
<img src="${grader_image}" title="${human_title}"/>
|
||||
</div>
|
||||
<div class="rubric-result">
|
||||
${co['rubric_html']}
|
||||
</div>
|
||||
<div class="rubric-result">
|
||||
${co['feedback']}
|
||||
</div>
|
||||
<br/>
|
||||
%endif
|
||||
%endfor
|
||||
@@ -5,7 +5,7 @@
|
||||
% for j in range(len(category['options'])):
|
||||
<% option = category['options'][j] %>
|
||||
% if option['selected']:
|
||||
${category['description']} : ${option['points']} points ,
|
||||
${category['description']} : ${option['points']} points |
|
||||
% endif
|
||||
% endfor
|
||||
% endfor
|
||||
|
||||
Reference in New Issue
Block a user