Created
February 10, 2021 00:48
-
-
Save iaindooley/bcbd3707aa233eb68d1c966ceec0b142 to your computer and use it in GitHub Desktop.
2 items completed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function twoItemsCompleted(notification) | |
{ | |
var comp = new Notification(notification).completedChecklistItem(/(First Item|Second Item)/i); | |
var compcount = 0; | |
comp.checklist().card().checklists().each(function(cl) | |
{ | |
cl.items().each(function(item) | |
{ | |
if(/First Item/i.test(item.name()) && item.isComplete()) | |
{ | |
compcount++; | |
} | |
else if(/Second Item/i.test(item.name()) && item.isComplete()) | |
{ | |
compcount++; | |
} | |
}); | |
}); | |
if(compcount == 2) | |
{ | |
comp.checklist().card().postComment("MAKE YOUR TIME. ALL YOUR BASE ARE BELONG TO US."); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment