diff options
-rw-r--r-- | client/components/rules/triggers/checklistTriggers.js | 4 | ||||
-rw-r--r-- | models/checklistItems.js | 4 | ||||
-rw-r--r-- | server/rulesHelper.js | 8 |
3 files changed, 8 insertions, 8 deletions
diff --git a/client/components/rules/triggers/checklistTriggers.js b/client/components/rules/triggers/checklistTriggers.js index 01f3effe..2272be29 100644 --- a/client/components/rules/triggers/checklistTriggers.js +++ b/client/components/rules/triggers/checklistTriggers.js @@ -78,7 +78,7 @@ BlazeComponent.extendComponent({ const actionSelected = this.find('#spec-comp-check-action').value; const checklistId = this.find('#spec-comp-check-name').value; const boardId = Session.get('currentBoard'); - if (actionSelected === 'added') { + if (actionSelected === 'completed') { datas.triggerVar.set({ activityType: 'completeChecklist', boardId, @@ -86,7 +86,7 @@ BlazeComponent.extendComponent({ desc, }); } - if (actionSelected === 'removed') { + if (actionSelected === 'uncompleted') { datas.triggerVar.set({ activityType: 'uncompleteChecklist', boardId, diff --git a/models/checklistItems.js b/models/checklistItems.js index 8380bda7..7132bc7c 100644 --- a/models/checklistItems.js +++ b/models/checklistItems.js @@ -130,7 +130,7 @@ function publishChekListCompleted(userId, doc, fieldNames, modifier){ cardId: doc.cardId, boardId, checklistId: doc.checklistId, - checklistName:doc.title, + checklistName:checkList.title, }; Activities.insert(act); } @@ -148,7 +148,7 @@ function publishChekListUncompleted(userId, doc, fieldNames, modifier){ cardId: doc.cardId, boardId, checklistId: doc.checklistId, - checklistName:doc.title, + checklistName:checkList.title, }; Activities.insert(act); } diff --git a/server/rulesHelper.js b/server/rulesHelper.js index e7e19b96..175af953 100644 --- a/server/rulesHelper.js +++ b/server/rulesHelper.js @@ -36,8 +36,8 @@ RulesHelper = { if(action.actionType === 'moveCardToTop'){ let listId; let list; - if(activity.listTitle === '*'){ - listId = card.swimlaneId; + if(action.listTitle === '*'){ + listId = card.listId; list = card.list(); }else{ list = Lists.findOne({title: action.listTitle, boardId }); @@ -49,8 +49,8 @@ RulesHelper = { if(action.actionType === 'moveCardToBottom'){ let listId; let list; - if(activity.listTitle === '*'){ - listId = card.swimlaneId; + if(action.listTitle === '*'){ + listId = card.listId; list = card.list(); }else{ list = Lists.findOne({title: action.listTitle, boardId}); |