Customer Journey Configuration: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 22: | Line 22: | ||
=== Customer Journey process id === | === Customer Journey process id === | ||
#REPLACE-STEP-PROCESS-Id# | #REPLACE-STEP-PROCESS-Id# | ||
== Javascript Examples == | |||
Below are some common used scripts that can be reused in your projects | |||
=== Check if moment already has a startdate, if not set it | |||
var currentvalue = '#MOMENT-dossier-klaar||date||#'; | |||
if (currentvalue) return currentvalue; | |||
if ('#VARIABLE-dossier-klaar||value||#' === 'yes') | |||
{ | |||
return CommonInterface.utcDateToString(new Date(), "yyyyMMddHHmmss"); | |||
} | |||
return ''; |
Revision as of 15:43, 21 December 2022
Below are some examples for referring to fields in the customer journey
Customer Journey References
These references are examples for retrieving data from the Customer Journey
Moments
Planned Start Date
#MOMENT-name-of-moment||date||#
Actions
Planned Start Date
#ACTION-name-of-action||date||#
Variables
#VARIABLE-name-of-variable||value||#
Common Process References
Customer Journey process start date
#REPLACE-STEP-PROCESS-DateStarted-yyyyMMdd#
Customer Journey process id
#REPLACE-STEP-PROCESS-Id#
Javascript Examples
Below are some common used scripts that can be reused in your projects === Check if moment already has a startdate, if not set it
var currentvalue = '#MOMENT-dossier-klaar||date||#'; if (currentvalue) return currentvalue; if ('#VARIABLE-dossier-klaar||value||#' === 'yes') { return CommonInterface.utcDateToString(new Date(), "yyyyMMddHHmmss"); } return ;