Skip to content

Instantly share code, notes, and snippets.

@iaindooley
Created March 30, 2020 02:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save iaindooley/b64807638bcd8ad07a10de865323735a to your computer and use it in GitHub Desktop.
Save iaindooley/b64807638bcd8ad07a10de865323735a to your computer and use it in GitHub Desktop.
Email overdue cards periodically
function emailOverdueCardsPeriodically(params,signature,original_time)
{
new Board(params).cards().each(function(card)
{
if(new Date(card.due()) < Trellinator.now())
{
MailApp.send(card.customFieldValue("Email"),"Hi there!","Here is a message");
}
});
ExecutionQueue.push("emailOverdueCardsPeriodically",params,signature,original_time.addHours(1));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment