mirror of
https://github.com/plankanban/planka.git
synced 2025-07-19 13:19:44 +02:00
feat: add page to view all cards assigned to current user #264
This commit is contained in:
parent
e6ab4e2370
commit
8c2de439d4
15 changed files with 329 additions and 3 deletions
|
@ -296,6 +296,10 @@ export default class extends BaseModel {
|
|||
return this.activities.orderBy(['id.length', 'id'], ['desc', 'desc']);
|
||||
}
|
||||
|
||||
getOrderedCardsQuerySet() {
|
||||
return this.cards.orderBy(['position', 'id.length', 'id']);
|
||||
}
|
||||
|
||||
getUnreadNotificationsQuerySet() {
|
||||
return this.notifications.filter({
|
||||
isRead: false,
|
||||
|
@ -313,6 +317,11 @@ export default class extends BaseModel {
|
|||
})
|
||||
.first();
|
||||
}
|
||||
getOrderedCardsModelArrayForUser(userId) {
|
||||
return this.getOrderedCardsQuerySet()
|
||||
.toModelArray()
|
||||
.filter((cardModel) => cardModel.hasMembershipForUser(userId));
|
||||
}
|
||||
|
||||
getCardsModelArray() {
|
||||
return this.getFiniteListsQuerySet()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue