Created
May 4, 2019 20:45
-
-
Save iaindooley/1102d83ab01c9a8c333066f04ae8a635 to your computer and use it in GitHub Desktop.
Mark parent card complete when child cards under given list
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 markParentCardCompleteWhenChildCardsUnderGivenList(notification) | |
{ | |
var complete = true; | |
var parent = new Notification(notification) | |
.movedCard("Completed List") | |
.cardsLinkedInAttachments() | |
.first(); | |
parent.cardsLinkedInAttachments().each(function(card) | |
{ | |
if(card.currentList().name() != "Completed List") | |
complete = false; | |
}); | |
if(complete) | |
parent.markDueDateComplete(); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment