Created
March 25, 2021 22:10
-
-
Save iaindooley/daf15db182dfbe8e9a5bc22decf0a5e5 to your computer and use it in GitHub Desktop.
createAndArchiveSubtaskCards
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
var added = new Notification(notification).addedLabel(/Subtask.*/i); | |
if(parts = /Subtask(.*)/i.exec(added.name())) | |
{ | |
if(!(listname = parts[1].trim())) | |
listname = "Checklist"; | |
added.card().checklist(listname).items().each(function(item) | |
{ | |
item.setName( | |
Card | |
.create( | |
added.card().currentList(),item.name() | |
) | |
.archive() | |
.link() | |
); | |
}); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment