[MRM-1809] Users - Manage section sort by name doesn't work as expected

This commit is contained in:
Olivier Lamy 2014-05-06 16:12:14 +10:00
parent d533b85919
commit 8e8148886b
2 changed files with 5 additions and 5 deletions

View File

@ -240,7 +240,7 @@ menu.users-runtime-configuration=Users Runtime Configuration
user.change.password.required=Change password required user.change.password.required=Change password required
users.grid.tab.title=Users users.grid.tab.title=Users
users.list=Users List users.list=Users List
users.sort.byname=Sort by Name users.sort.byname=Sort by User Name
effective.roles.edit=Edit Roles effective.roles.edit=Edit Roles
locked=Locked locked=Locked
validated=Validated validated=Validated

View File

@ -131,21 +131,21 @@ function(jquery,utils,i18n,jqueryValidate,ko,koSimpleGrid,typeahead) {
lock = function(user){ lock = function(user){
clearUserMessages(); clearUserMessages();
user.lock(); user.lock();
} };
unlock = function(user){ unlock = function(user){
clearUserMessages(); clearUserMessages();
user.unlock(); user.unlock();
} };
passwordChangeRequire = function(user,forceChangedPassword){ passwordChangeRequire = function(user,forceChangedPassword){
clearUserMessages(); clearUserMessages();
user.changePasswordChangeRequired(forceChangedPassword); user.changePasswordChangeRequired(forceChangedPassword);
} };
this.sortByName = function() { this.sortByName = function() {
this.users.sort(function(a, b) { this.users.sort(function(a, b) {
return a.username < b.username ? -1 : 1; return a.username().localeCompare(b.username());
}); });
}; };