MDL-46525 enrol_cohort: fix JS error

This commit is contained in:
Marina Glancy 2014-07-25 14:29:55 +08:00
parent 40f0ad21a3
commit bd56200e09

View File

@ -292,7 +292,7 @@ YUI.add('moodle-enrol_cohort-quickenrolment', function(Y) {
} else {
if (result.response && result.response.message) {
var alertpanel = new M.core.alert(result.response);
Y.Node.one('#id_yuialertconfirm-' + alertpanel.COUNT).focus();
Y.Node.one('#id_yuialertconfirm-' + alertpanel.get('COUNT')).focus();
}
var enrolled = Y.Node.create('<div class="'+CSS.COHORTBUTTON+' alreadyenrolled">'+M.str.enrol.synced+'</div>');
node.one('.'+CSS.COHORT+' #cohortid_'+cohort.get(COHORTID)).replace(enrolled);