summaryrefslogtreecommitdiffstats
path: root/client/components
diff options
context:
space:
mode:
authorAndrés Manelli <andresmanelli@gmail.com>2018-01-31 15:46:59 -0300
committerAndrés Manelli <andresmanelli@gmail.com>2018-01-31 15:46:59 -0300
commitff9ca755f338e3c45a1bd726dfbce1c607f2ff4c (patch)
tree7100c84a6fe294eb98921f9e70c793c5e658af91 /client/components
parentd3c110cd8f3ad16a4ced5520c27ab542cc79b548 (diff)
downloadwekan-ff9ca755f338e3c45a1bd726dfbce1c607f2ff4c.tar.gz
wekan-ff9ca755f338e3c45a1bd726dfbce1c607f2ff4c.tar.bz2
wekan-ff9ca755f338e3c45a1bd726dfbce1c607f2ff4c.zip
Fix details view in lists only mode
Diffstat (limited to 'client/components')
-rw-r--r--client/components/lists/listsGroup.js13
-rw-r--r--client/components/swimlanes/swimlanes.jade2
-rw-r--r--client/components/swimlanes/swimlanes.js9
3 files changed, 22 insertions, 2 deletions
diff --git a/client/components/lists/listsGroup.js b/client/components/lists/listsGroup.js
new file mode 100644
index 00000000..f94f681f
--- /dev/null
+++ b/client/components/lists/listsGroup.js
@@ -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');
diff --git a/client/components/swimlanes/swimlanes.jade b/client/components/swimlanes/swimlanes.jade
index e6a0cd34..765f6d49 100644
--- a/client/components/swimlanes/swimlanes.jade
+++ b/client/components/swimlanes/swimlanes.jade
@@ -33,7 +33,7 @@ template(name="listsGroup")
else
each currentBoard.lists
+list(this)
- if currentCardIsInThisList
+ if currentCardIsInThisList _id null
+cardDetails(currentCard)
if currentUser.isBoardMember
+addListForm
diff --git a/client/components/swimlanes/swimlanes.js b/client/components/swimlanes/swimlanes.js
index 68039b17..211f84f2 100644
--- a/client/components/swimlanes/swimlanes.js
+++ b/client/components/swimlanes/swimlanes.js
@@ -30,7 +30,14 @@ BlazeComponent.extendComponent({
currentCardIsInThisList(listId, swimlaneId) {
const currentCard = Cards.findOne(Session.get('currentCard'));
- return currentCard && currentCard.listId === listId && currentCard.swimlaneId === swimlaneId;
+ 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;
},
events() {