Write, Bureaucrats, Administrators
4,332
edits
mNo edit summary |
mNo edit summary |
||
Line 395: | Line 395: | ||
The user will enter the value in PriceUSD and the value in Euros will appear in PriceEUR according to the current exchange rate. | The user will enter the value in PriceUSD and the value in Euros will appear in PriceEUR according to the current exchange rate. | ||
:; Add new trigger: Set Event '''Create an entry to Add''' and Phase '''After saving the entry'''. It will run asynchronously. | |||
: | :'''Trigger script:''' | ||
<source lang="javascript"> | <source lang="javascript"> | ||
result = http().get("http://api.fixer.io/latest?base=USD"); // Use http://fixer.io/ for | result = http().get("http://api.fixer.io/latest?base=USD"); // Use http://fixer.io/ for | ||
Line 407: | Line 407: | ||
// for value for PriceEUR | // for value for PriceEUR | ||
</source> | </source> | ||
<br/> | |||
----- | ----- | ||
==== Creating a Task in the Todoist App ==== | ==== Creating a Task in the Todoist App ==== | ||
Line 413: | Line 413: | ||
In the following example of task creation, text will be taken from the Memento library entry. | In the following example of task creation, text will be taken from the Memento library entry. | ||
: | :; Add a new trigger: Set Event to '''Creating a new entry''' or perhaps '''Update an entry'''. Set Phase as appropriate. | ||
:'''Trigger script:''' | |||
<source lang="javascript"> | <source lang="javascript"> | ||
// Create a JSON command for Todoist task creation | // Create a JSON command for Todoist task creation |