-
Notifications
You must be signed in to change notification settings - Fork 51
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sort campCollaboration- & MaterialList-List #5535
Conversation
ff170f8
to
840f05c
Compare
⛔ Feature branch deployment currently inactive.If the PR is still open, you can add the |
...keyBy(this.camp.campCollaborations().items, '_meta.self'), | ||
...keyBy( | ||
sortBy(this.camp.campCollaborations().items, (u) => | ||
campCollaborationDisplayName(u, this.$tc.bind(this)).toLowerCase() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why the toLowerCase?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So that sorting is alphabetical regardless of capitalization.
return sortBy( | ||
this.campCollaborations.items | ||
.filter((cc) => { | ||
return ( | ||
cc.status !== 'inactive' || | ||
this.currentCampCollaborationIRIs.includes(cc._meta.self) | ||
) | ||
}) | ||
.map((value) => { | ||
// following structure is defined by vuetify v-select items property | ||
return { | ||
value: value._meta.self, | ||
campCollaboration: value, | ||
text: campCollaborationDisplayName(value, this.$tc.bind(this)), | ||
} | ||
}), | ||
(value) => value.text.toLowerCase() | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Move to own computed
close #5484
In ScheduleEntry-View, ResponsibleUser List is sorted alphabetically.
In Material-View, MaterialList is sorted
Non-User before User-Lists
then alphabetically