Commit 15ed645e authored by Saskia Schreiber's avatar Saskia Schreiber

[FEATURE] Add successfulAnswer and score to answer model, give first visual feedback

parent 74e54ab3
...@@ -161,9 +161,13 @@ Ext.define('ARSnova.view.FreetextAnswerPanel', { ...@@ -161,9 +161,13 @@ Ext.define('ARSnova.view.FreetextAnswerPanel', {
'<span style="color:gray">{formattedTime}</span>', '<span style="color:gray">{formattedTime}</span>',
'<tpl if="read === true || this.isStudent()">', '<tpl if="read === true || this.isStudent()">',
'<span style="padding-left:30px">{answerSubject:htmlEncode}</span>', '<span style="padding-left:30px">{answerSubject:htmlEncode}</span>',
'<tpl if="successfulFreeTextAnswer === true"><span class="correct">Correct</span></tpl>',
'<tpl if="successfulFreeTextAnswer === false"><span class="incorrect">Wrong</span></tpl>',
'</tpl>', '</tpl>',
'<tpl if="read === false && !this.isStudent()">', '<tpl if="read === false && !this.isStudent()">',
'<span class="thm-red" style="padding-left:30px">{answerSubject:htmlEncode}</span>', '<span class="thm-red" style="padding-left:30px">{answerSubject:htmlEncode}</span>',
'<tpl if="successfulFreeTextAnswer === true"><span class="correct">Correct</span></tpl>',
'<tpl if="successfulFreeTextAnswer === false"><span class="incorrect">Wrong</span></tpl>',
'</tpl>', '</tpl>',
'</div>', '</div>',
{ {
......
...@@ -48,7 +48,9 @@ Ext.define('FreetextAnswer', { ...@@ -48,7 +48,9 @@ Ext.define('FreetextAnswer', {
'type', 'type',
'_rev', '_rev',
'answerThumbnailImage', 'answerThumbnailImage',
'read' 'read',
'successfulFreeTextAnswer',
'freetextScore'
] ]
} }
}); });
......
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