Fix details view in lists only mode

This commit is contained in:
Andrés Manelli 2018-01-31 15:46:59 -03:00
parent d3c110cd8f
commit ff9ca755f3
3 changed files with 22 additions and 2 deletions

View file

@ -0,0 +1,13 @@
BlazeComponent.extendComponent({
currentCardIsInThisList(listId, swimlaneId) {
const currentCard = Cards.findOne(Session.get('currentCard'));
const currentBoardId = Session.get('currentBoard');
const board = Boards.findOne(currentBoardId);
if (board.view === 'board-view-lists')
return currentCard && currentCard.listId === listId;
else if (board.view === 'board-view-swimlanes')
return currentCard && currentCard.listId === listId && currentCard.swimlaneId === swimlaneId;
else
return false;
},
}).register('listsGroup');