mirror of
https://github.com/wekan/wekan.git
synced 2025-04-23 21:47:10 -04:00
Admin Panel - sort Organizations and Teams by Display Name, sort People by username
This commit is contained in:
parent
9b22e6da7a
commit
3a83d48bef
3 changed files with 5 additions and 2 deletions
|
@ -144,6 +144,7 @@ BlazeComponent.extendComponent({
|
|||
},
|
||||
orgList() {
|
||||
const orgs = Org.find(this.findOrgsOptions.get(), {
|
||||
sort: { orgDisplayName: 1 },
|
||||
fields: { _id: true },
|
||||
});
|
||||
this.numberOrgs.set(orgs.count(false));
|
||||
|
@ -151,6 +152,7 @@ BlazeComponent.extendComponent({
|
|||
},
|
||||
teamList() {
|
||||
const teams = Team.find(this.findTeamsOptions.get(), {
|
||||
sort: { teamDisplayName: 1 },
|
||||
fields: { _id: true },
|
||||
});
|
||||
this.numberTeams.set(teams.count(false));
|
||||
|
@ -158,6 +160,7 @@ BlazeComponent.extendComponent({
|
|||
},
|
||||
peopleList() {
|
||||
const users = Users.find(this.findUsersOptions.get(), {
|
||||
sort: { username: 1 },
|
||||
fields: { _id: true },
|
||||
});
|
||||
this.numberPeople.set(users.count(false));
|
||||
|
|
|
@ -217,7 +217,7 @@ if (Meteor.isServer) {
|
|||
// Index for Organization name.
|
||||
Meteor.startup(() => {
|
||||
// Org._collection._ensureIndex({ name: -1 });
|
||||
Org._collection._ensureIndex({ orgDisplayName: -1 });
|
||||
Org._collection._ensureIndex({ orgDisplayName: 1 });
|
||||
});
|
||||
}
|
||||
|
||||
|
|
|
@ -214,7 +214,7 @@ if (Meteor.isServer) {
|
|||
if (Meteor.isServer) {
|
||||
// Index for Team name.
|
||||
Meteor.startup(() => {
|
||||
Team._collection._ensureIndex({ teamDisplayName: -1 });
|
||||
Team._collection._ensureIndex({ teamDisplayName: 1 });
|
||||
});
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue