mirror of
https://github.com/wekan/wekan.git
synced 2026-02-12 11:14:21 +01:00
Add popup menu and archive action
This commit is contained in:
parent
3414cb84ad
commit
5953fb8a44
7 changed files with 57 additions and 2 deletions
|
|
@ -25,3 +25,14 @@ template(name="archivesSidebar")
|
|||
= title
|
||||
else
|
||||
li.no-items-message {{_ 'no-archived-lists'}}
|
||||
|
||||
+tabContent(slug="swimlanes")
|
||||
ul.archived-lists
|
||||
each archivedSwimlanes
|
||||
li.archived-lists-item
|
||||
if currentUser.isBoardMember
|
||||
button.js-restore-swimlane
|
||||
i.fa.fa-undo
|
||||
= title
|
||||
else
|
||||
li.no-items-message {{_ 'no-archived-swimlanes'}}
|
||||
|
|
|
|||
|
|
@ -3,6 +3,7 @@ BlazeComponent.extendComponent({
|
|||
return [
|
||||
{ name: TAPi18n.__('cards'), slug: 'cards' },
|
||||
{ name: TAPi18n.__('lists'), slug: 'lists' },
|
||||
{ name: TAPi18n.__('swimlanes'), slug: 'swimlanes' },
|
||||
];
|
||||
},
|
||||
|
||||
|
|
@ -20,6 +21,13 @@ BlazeComponent.extendComponent({
|
|||
});
|
||||
},
|
||||
|
||||
archivedSwimlanes() {
|
||||
return Swimlanes.find({
|
||||
archived: true,
|
||||
boardId: Session.get('currentBoard'),
|
||||
});
|
||||
},
|
||||
|
||||
cardIsInArchivedList() {
|
||||
return this.currentData().list().archived;
|
||||
},
|
||||
|
|
@ -45,6 +53,10 @@ BlazeComponent.extendComponent({
|
|||
const list = this.currentData();
|
||||
list.restore();
|
||||
},
|
||||
'click .js-restore-swimlane'() {
|
||||
const swimlane = this.currentData();
|
||||
swimlane.restore();
|
||||
},
|
||||
}];
|
||||
},
|
||||
}).register('archivesSidebar');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue