I’m trying below transforms with given conditions… but somehow missing something… Can someone please help me with it to correct this transform
- when the authoritative source status field is disabled set the LCS is disabled.
- When the authoritative source status field is suspended set the LCS is suspended.
- when the term date is set to today’s plus one padding and set LCS termination.
- when the worker type is contractor status is inactive, set the LCS is active.
The transform that I build is
{
"attributes": {
"EMPL_STATUS": {
"attributes": {
"attributeName": "STATUS",
"sourceName": "Oracle ERP"
},
"type": "accountAttribute"
},
"WORKER_TYPE": {
"attributes": {
"attributeName": "WORKER_TYPE",
"sourceName": "Oracle ERP"
},
"type": "accountAttribute"
},
"DATE": {
"attributes": {
"firstDate": {
"attributes": {
"sourceName": "Oracle ERP",
"attributeName": "TERMDT"
},
"inputFormat": "ddMMyyyy",
"outputFormat": "ISO8601",
"type": "accountAttribute"
},
"secondDate": "now",
"expression": "+1d",
"roundUp": true,
"operator": "gt",
"positiveCondition": "active",
"negativeCondition": "terminated"
},
"type": "dateCompare"
},
"value": "#if($EMPL_STATUS == 'ACTIVE')active#elseif($EMPL_STATUS == 'SUSPENDED')suspended#elseif($EMPL_STATUS == 'INACTIVE' || $WORKER_TYPE =='Pending Worker')active#end"
},
"type": "static",
"Name": "Test Calculate EmployeeLifeCycleState"
}