0
Fork 0
mirror of https://github.com/TryGhost/Ghost.git synced 2025-01-13 22:41:32 -05:00

Roles drop down sorted by ID

closes #3391
- Changed sort order to ID instead of name
This commit is contained in:
joeldrapper 2014-07-24 19:28:30 +01:00
parent 719d90da46
commit 25b20bb2fe

View file

@ -14,7 +14,7 @@ var InviteNewUserController = Ember.Controller.extend({
self = this; self = this;
roles.promise = this.store.find('role', { permissions: 'assign' }).then(function (roles) { roles.promise = this.store.find('role', { permissions: 'assign' }).then(function (roles) {
return roles.rejectBy('name', 'Owner').sortBy('name'); return roles.rejectBy('name', 'Owner').sortBy('id');
}).then(function (roles) { }).then(function (roles) {
// After the promise containing the roles has been resolved and the array // After the promise containing the roles has been resolved and the array
// has been sorted, explicitly set the selectedRole for the Ember.Select. // has been sorted, explicitly set the selectedRole for the Ember.Select.