Hi team,
1) Anyone help me What is the use of Advanced JS activity in Adobe Campaign Classic?
2) What is the use of First call and next calls?
3) what is task.setCompleted();
4) what is return 0 in both calls?
please any one help me any share use case for clarify this question?
Solved! Go to Solution.
Views
Replies
Total Likes
Hi @Kumar_27,
The First Call is the code base which will be executed at each start of the workflow.
The next call is the code which will run post the first call. If you are using the scheduler functionality in the Advanced Javascript, then first run of the Advanced JS will trigger the First Call code block and then Next call.
Subsequent runs triggered by scheduler within Advanced JS will trigger only the next call and not the first call.
Transitions similar to split help to change the flow of data based on some inputs which can be configured programmatically. For transitions consider the following example:
var input = 1;
if(input == 1)
{
task.postEvent(task.transitionByName('ok'));
}
else
{
task.postEvent(task.transitionByName('notOk'));
}
As we see in the above example, the code will evaluate to give output to the 'Ok' transition and hence the workflow will move towards 'Ok' transition.
If the value of input was any numeric value other than 1, then the workflow will move to notOk transition.
Refer to following link for more info:
Hi @Kumar_27,
The First Call is the code base which will be executed at each start of the workflow.
The next call is the code which will run post the first call. If you are using the scheduler functionality in the Advanced Javascript, then first run of the Advanced JS will trigger the First Call code block and then Next call.
Subsequent runs triggered by scheduler within Advanced JS will trigger only the next call and not the first call.
Transitions similar to split help to change the flow of data based on some inputs which can be configured programmatically. For transitions consider the following example:
var input = 1;
if(input == 1)
{
task.postEvent(task.transitionByName('ok'));
}
else
{
task.postEvent(task.transitionByName('notOk'));
}
As we see in the above example, the code will evaluate to give output to the 'Ok' transition and hence the workflow will move towards 'Ok' transition.
If the value of input was any numeric value other than 1, then the workflow will move to notOk transition.
Refer to following link for more info:
Views
Likes
Replies