Commit e2aea75f by Felix Sun

Fixed a bug in recording hints shown.

Removed the answer display next to voting.  (This was deemed distracting.)
parent d9517ea1
...@@ -227,7 +227,7 @@ class CrowdsourceHinterModule(CrowdsourceHinterFields, XModule): ...@@ -227,7 +227,7 @@ class CrowdsourceHinterModule(CrowdsourceHinterFields, XModule):
if not rand_hint in hints: if not rand_hint in hints:
go_on = True go_on = True
hints.append(rand_hint) hints.append(rand_hint)
self.previous_answers += [[hint_index, [hint_answer]]] self.previous_answers += [[hint_answer, [hint_index]]]
return {'hints': hints, return {'hints': hints,
'answer': answer} 'answer': answer}
...@@ -281,7 +281,6 @@ class CrowdsourceHinterModule(CrowdsourceHinterFields, XModule): ...@@ -281,7 +281,6 @@ class CrowdsourceHinterModule(CrowdsourceHinterFields, XModule):
except KeyError: except KeyError:
# Sometimes, the hint that a user saw will have been deleted by the instructor. # Sometimes, the hint that a user saw will have been deleted by the instructor.
continue continue
return {'answer_to_hints': answer_to_hints, return {'answer_to_hints': answer_to_hints,
'user_submissions': self.user_submissions} 'user_submissions': self.user_submissions}
......
...@@ -46,7 +46,7 @@ ...@@ -46,7 +46,7 @@
% for hint_pk, hint_text in pk_dict.items(): % for hint_pk, hint_text in pk_dict.items():
<p> <p>
<input class="vote" data-answer="${answer}" data-hintno="${hint_pk}" type="button" value="Vote"> <input class="vote" data-answer="${answer}" data-hintno="${hint_pk}" type="button" value="Vote">
${answer}: ${hint_text} ${hint_text}
</p> </p>
% endfor % endfor
% endfor % endfor
...@@ -71,7 +71,7 @@ ...@@ -71,7 +71,7 @@
<div class = "previous-answer" id="previous-answer-${unspace(answer)}" data-answer="${answer}"> <div class = "previous-answer" id="previous-answer-${unspace(answer)}" data-answer="${answer}">
<div class = "hint-inner-container"> <div class = "hint-inner-container">
<p> <p>
What hint would you give a student who made the same mistake you did? Please don't give away the answer. What hint would you give a student who also arrived at an answer of ${answer}? Please don't give away the correct answer.
</p> </p>
<textarea cols="50" class="custom-hint" data-answer="${answer}"> <textarea cols="50" class="custom-hint" data-answer="${answer}">
What would you say to help someone who got this wrong answer? What would you say to help someone who got this wrong answer?
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment