Loading

Edit Block Displays Empty Block Despite Passing Null Value

Publiseringsdato: Jan 1, 2025
Beskrivelse

When using an edit block in Omniscript to set its value to null based on specific conditions, the customer encountered an issue where the edit block displayed an empty row. They are attempting this by utilizing the set value condition: IF(%FieldName%, %BlockName%, NULL). However, this approach did not yield the desired result, as it resulted in an empty row instead of no block at all.


The observed behavior may occur because the value being passed to the edit block is "null" (as a string) instead of null. The customer's organization has access to environment variables such as $Vlocity.NULL, which correctly passes a null value rather than the string "null". These variables are specifically available in Integration Procedures and Data Mappers. In such cases, it is recommended to use $Vlocity.NULL instead of NULL.

Screenshot 2024-12-31 at 1.12.30 AM.png  

Løsning

To address the issue, remove the set value logic from the Omniscript and implement a new Integration Procedure to handle these set values effectively. This involves modifying the condition from IF(%FieldName%, %BlockName%, NULL) to IF(%FieldName%, %BlockName%, $Vlocity.NULL), ensuring the correct null value is passed instead of the string "null".

 

The set value logic is moved to the Integration Procedure as these environmnetal variables are specifically available in Integration Procedures and Data Mappers and not in Oniscripts. Once implemented, call the Integration Procedure action in the Omniscript, placing it after the relevant step to ensure seamless execution and accurate value handling.

For detailed guidance on using environment variables, please refer to the Salesforce documentation on environment variables in DataRaptors and Integration Procedures.

Knowledge-artikkelnummer

003962511

 
Laster
Salesforce Help | Article