mirror of
https://github.com/moodle/moodle.git
synced 2025-04-21 16:32:18 +02:00
MDL-47959 mod_quiz: fixed 0 questions bug
This commit is contained in:
parent
323ed3bbf0
commit
1a14f8a6de
@ -124,10 +124,10 @@ Y.extend(TOOLBOX, Y.Base, {
|
||||
} catch (e) {}
|
||||
|
||||
// Run the callback if we have one.
|
||||
if (responsetext.newsummarks) {
|
||||
if (responsetext.hasOwnProperty('newsummarks')) {
|
||||
Y.one(SELECTOR.SUMMARKS).setHTML(responsetext.newsummarks);
|
||||
}
|
||||
if (responsetext.newnumquestions) {
|
||||
if (responsetext.hasOwnProperty('newnumquestions')) {
|
||||
Y.one(SELECTOR.NUMQUESTIONS).setHTML(M.util.get_string('numquestionsx', 'quiz', responsetext.newnumquestions));
|
||||
}
|
||||
if (success_callback) {
|
||||
|
File diff suppressed because one or more lines are too long
@ -124,10 +124,10 @@ Y.extend(TOOLBOX, Y.Base, {
|
||||
} catch (e) {}
|
||||
|
||||
// Run the callback if we have one.
|
||||
if (responsetext.newsummarks) {
|
||||
if (responsetext.hasOwnProperty('newsummarks')) {
|
||||
Y.one(SELECTOR.SUMMARKS).setHTML(responsetext.newsummarks);
|
||||
}
|
||||
if (responsetext.newnumquestions) {
|
||||
if (responsetext.hasOwnProperty('newnumquestions')) {
|
||||
Y.one(SELECTOR.NUMQUESTIONS).setHTML(M.util.get_string('numquestionsx', 'quiz', responsetext.newnumquestions));
|
||||
}
|
||||
if (success_callback) {
|
||||
|
4
mod/quiz/yui/src/toolboxes/js/toolbox.js
vendored
4
mod/quiz/yui/src/toolboxes/js/toolbox.js
vendored
@ -122,10 +122,10 @@ Y.extend(TOOLBOX, Y.Base, {
|
||||
} catch (e) {}
|
||||
|
||||
// Run the callback if we have one.
|
||||
if (responsetext.newsummarks) {
|
||||
if (responsetext.hasOwnProperty('newsummarks')) {
|
||||
Y.one(SELECTOR.SUMMARKS).setHTML(responsetext.newsummarks);
|
||||
}
|
||||
if (responsetext.newnumquestions) {
|
||||
if (responsetext.hasOwnProperty('newnumquestions')) {
|
||||
Y.one(SELECTOR.NUMQUESTIONS).setHTML(M.util.get_string('numquestionsx', 'quiz', responsetext.newnumquestions));
|
||||
}
|
||||
if (success_callback) {
|
||||
|
Loading…
x
Reference in New Issue
Block a user