Commit ac779afa authored by Saskia Schreiber's avatar Saskia Schreiber

[BUGFIX] Get sending values from textChecker back to work

parent c5d2ba72
......@@ -102,9 +102,7 @@ Ext.define('ARSnova.view.speaker.form.FreeTextQuestion', {
var result = {};
result.imageQuestion = this.imageQuestion;
result.textAnswerEnabled = this.textAnswerEnabled;
result.ignoreCaseSensitive = this.textChecker.textCheckerStricktOptionsFormPart.getIgnoreCaseSensitive();
result.ignoreWhitespaces = this.textChecker.textCheckerStricktOptionsFormPart.getIgnoreWhitespaces();
result.ignorePunctuation = this.textChecker.textCheckerStricktOptionsFormPart.getIgnorePunctuation();
Ext.apply(result, this.textChecker.getValues());
return result;
}
......
......@@ -27,9 +27,10 @@ Ext.define('ARSnova.view.speaker.form.TextChecker', {
},
constructor: function () {
var me = this;
this.callParent(arguments);
var textCheckerStricktOptionsFormPart = Ext.create('ARSnova.view.speaker.form.textCheckerStricktOptionsForm', {
this.textCheckerStricktOptionsFormPart = Ext.create('ARSnova.view.speaker.form.textCheckerStricktOptionsForm', {
id: 'textCheckerStricktOptionsFormPart'
});
......@@ -39,7 +40,7 @@ Ext.define('ARSnova.view.speaker.form.TextChecker', {
mainFormPanel.hide();
selectField.hide();
ratingField.hide();
textCheckerStricktOptionsFormPart.hide();
me.textCheckerStricktOptionsFormPart.hide();
},
pressed: this.getPressed() === 'free'
});
......@@ -70,7 +71,7 @@ Ext.define('ARSnova.view.speaker.form.TextChecker', {
var easyButton = Ext.create('Ext.Button', {
text: Messages.FREETEXT_BUTTON_EASY,
handler: function () {
textCheckerStricktOptionsFormPart.hide();
me.textCheckerStricktOptionsFormPart.hide();
},
pressed: true
});
......@@ -78,7 +79,7 @@ Ext.define('ARSnova.view.speaker.form.TextChecker', {
var strictButton = Ext.create('Ext.Button', {
text: Messages.FREETEXT_BUTTON_STRICT,
handler: function () {
textCheckerStricktOptionsFormPart.show();
me.textCheckerStricktOptionsFormPart.show();
},
pressed: this.getPressed() === 'strict'
});
......@@ -138,8 +139,17 @@ Ext.define('ARSnova.view.speaker.form.TextChecker', {
freefixField,
mainFormPanel,
selectField,
textCheckerStricktOptionsFormPart,
this.textCheckerStricktOptionsFormPart,
ratingField
]);
},
getValues: function() {
var result = {};
result.ignoreCaseSensitive = this.textCheckerStricktOptionsFormPart.getIgnoreCaseSensitive();
result.ignoreWhitespaces = this.textCheckerStricktOptionsFormPart.getIgnoreWhitespaces();
result.ignorePunctuation = this.textCheckerStricktOptionsFormPart.getIgnorePunctuation();
return result;
}
});
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