Last active
March 25, 2020 11:58
-
-
Save iaindooley/0e810a4625865d9f13b86878a8641b42 to your computer and use it in GitHub Desktop.
Attach product to supplier
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 attachProductToSupplier(notification) | |
{ | |
var added = new Notification(notification).addedChecklistItem(); | |
if(added.checklist().name() == "Suppliers") | |
{ | |
var supplier_card = new Trellinator() | |
.board("Suppliers") | |
.card(new RegExp(".*"+added.name()+".*","i")); | |
added.setName(supplier_card.link()); | |
supplier_card.addChecklist("Products",function(cl) | |
{ | |
cl.addUniqueItem(added.checklist().card().link()); | |
}); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment