Created
March 3, 2021 04:46
-
-
Save iaindooley/94db1528594700f189160d77799ad662 to your computer and use it in GitHub Desktop.
Set elements from template
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 setElementsFromTemplate(notification) | |
{ | |
var created = new Notification(notification).createdCard(); | |
var template = created.board().card("Template"); | |
template.checklists().each(function(cl) | |
{ | |
template.copyUniqueChecklist(cl.name(),created); | |
}); | |
template.labels().each(function(label) | |
{ | |
created.addLabel(label.name()); | |
}); | |
template.members().each(function(member) | |
{ | |
created.addMember(member); | |
}); | |
created.setDescription(created.description()+"\n\n"+template.description()); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment