Posts

Showing posts from July, 2022

Vlocity Facts #14 | Integration Procedure Properties

Integration Procedure runs in synchronous or asynchronous mode ? By Default it will run in Synchronous mode. To make Integration Procedure run in Asynchronous mode, call Integration Procedures using these settings from omniscript: Use Future — Use when the calling OmniScript or Integration Procedure doesn't need a response and completion time is not critical. [Specifies that the Integration Procedure runs asynchronously, as a Salesforce future method, which can return no data to the calling OmniScript.] Invoke Mode: Non-Blocking : The Action runs asynchronously, and the response applies to the UI. Pre and Post DataRaptor transform and large attachments are not supported. Invoke Mode: Fire and Forget : The Action runs asynchronously with no callback to the UI. Pre and Post DataRaptor transforms, and large attachments are not supported. A response still appears in the debug console but does not apply to the Data JSON. ===========================================================...

Vlocity Facts #13 | Angular OmniScript Debugging

Image
When creating any interface or code, debugging and testing are crucial components. We can test from Vlocity's Omniscript Designer Preview mode to analyze the execution results.  But in some cases we need  OmniScript must occasionally be tested under same circumstances and using the same Users and Profiles as the intended users. Angular OmniScript Debugging A few methods for debugging Integration Procedures and Omniscripts for Angular while they are running and how to obtain the data that is kept in OmniScript JSON storage and the data that is exchanged with Salesforce. Before starting we need to know what is scope, bpTree, response and baseCrtl. " baseCtrl " - The "baseCrtl" angular controller defines its methods and variables. Scope -- definition of all available methods Path: baseCtrl.prototype.$scope bpTree --  the OmniScript structure definition and variables Path: baseCtrl.prototype.$scope.bpTree response -> the OmniScript JSON Data Path: baseCtrl.protot...

Vlocity Facts #12 | CSS changes to an OmniScript elements

Image
For example: If their is a requirement where you need to change the color of the button or you need to add some custom styling of the elements. instead of creating templates you can follow this approach.  For applying CSS changes to the elements all over the OmniScript. 1. Inspect the element  by right-clicking on the element and selecting Inspect. 2. Locate the Styles tab next to the Elements tab and copy the class for the element's div to your clipboard. 3. Navigate to Script Configuration > HTML Custom Templates and add opening and closing style tags <style> </style> and write CSS for the desired changes using the class that was copied as your CSS Selector. 4. Navigate back to Preview to see the changes in effect for each step. This is other example for text element, here you can see the difference between the 2 text elements font-size. This is for single element on each step. Use this code  # Text1 ~ label {       font-wei...

Vlocity Facts #11 | Best Practices of OmniScripts, Integration Procedure, Data Raptor

 Best Practices of OmniScripts: Provide the proper Name for elements without space. Need to Add Internal  Notes to the OmniSscript Elements. Avoid assigning or using  a ContextId Within Omniscript. When process are repeatable across multiple omniscripts, create a reusable OS and add it in parent OmniScript. Reduce Conditional Views, Merge Fields, Formulas where possible in OmniScript to avoid loading. Reduce the number of elements in the script. A single OmniScript should not exceed 200 elements. Remove the inactive elements. Pass the required Input JSON to Integration Procedure instead of Passing full JSON. Instead of using multiple actions on OmniScript use Integration procedure. Best Practices of   Data Raptor: Try to keep the number of SObjects to three or fewer. Use relationship notation (queries) whenever possible to pull data from other SObjects. Ensure that all filtering and sorting (ORDER BY) operations are on indexed fields. Use caching to store freque...