Commit 049e880c authored by David Mudrak's avatar David Mudrak
Browse files

AJAX enrolment uses proper {$a} placeholder

We now have M.util.get_string() that should be used instead of custom
replacement. Otherwise the placeholder is not detected in AMOS
web translator.
parent 2246f9f6
......@@ -334,7 +334,7 @@ YUI.add('moodle-enrol-enrolmentmanager', function(Y) {
}
this.set(UEP.USERCOUNT, count);
if (!args.append) {
var usersstr = (result.response.totalusers == '1')?M.str.enrol.ajaxoneuserfound:M.str.enrol.ajaxxusersfound.replace(/\[users\]/, result.response.totalusers);
var usersstr = (result.response.totalusers == '1')?M.str.enrol.ajaxoneuserfound:M.util.get_string('ajaxxusersfound','enrol', result.response.totalusers);
var content = Y.Node.create('<div class="'+CSS.SEARCHRESULTS+'"></div>')
.append(Y.Node.create('<div class="'+CSS.TOTALUSERS+'">'+usersstr+'</div>'))
.append(users);
......
......@@ -186,7 +186,7 @@ YUI.add('moodle-enrol-otherusersmanager', function(Y) {
}
this.set(USERCOUNT, count);
if (!args.append) {
var usersstr = (result.response.totalusers == '1')?M.str.enrol.ajaxoneuserfound:M.str.enrol.ajaxxusersfound.replace(/\[users\]/, result.response.totalusers);
var usersstr = (result.response.totalusers == '1')?M.str.enrol.ajaxoneuserfound:M.util.get_string('ajaxxusersfound','enrol', result.response.totalusers);
var content = Y.Node.create('<div class="'+CSS.SEARCHRESULTS+'"></div>')
.append(Y.Node.create('<div class="'+CSS.TOTALUSERS+'">'+usersstr+'</div>'))
.append(usersnode);
......
......@@ -27,7 +27,7 @@
$string['actenrolshhdr'] = 'Available course enrolment plugins';
$string['addinstance'] = 'Add method';
$string['ajaxoneuserfound'] = '1 user found';
$string['ajaxxusersfound'] = '[users] users found';
$string['ajaxxusersfound'] = '{$a} users found';
$string['ajaxnext25'] = 'Next 25...';
$string['assignnotpermitted'] = 'You do not have permission or can not assign roles in this course.';
$string['configenrolplugins'] = 'Please select all required plugins and arrange then in appropriate order.';
......
......@@ -29,7 +29,7 @@
defined('MOODLE_INTERNAL') || die();
$version = 2010111300; // YYYYMMDD = date of the last version bump
$version = 2010111600; // YYYYMMDD = date of the last version bump
// XX = daily increments
$release = '2.0 RC2 (Build: 20101116)'; // Human-friendly version name
......
Supports Markdown
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