Created
August 28, 2019 19:17
-
-
Save iaindooley/6a82562d486e447307df4911b7bcf76a to your computer and use it in GitHub Desktop.
Move cards with label
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 moveCardsWithLabel() | |
{ | |
var b = new Trellinator().board("My Board"); | |
var l1 = b.list("Target 1"); | |
var l2 = b.list("Target 2"); | |
b.list("My List").cards().each(function(card) | |
{ | |
try | |
{ | |
card.label("Label 1"); | |
card.moveTo(l1); | |
} | |
catch(e) | |
{ | |
card.moveTo(l2); | |
} | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment