Skip to main content

KI-93

Key/SummaryKI-93: Fulfillment: Expire Anonymous flow cannot edit closed Fulfillment recordsStatusDone
Created1/20/2023Updated05/22/2023
DescriptionThe Fulfillment: Expire Anonymous (MED_Fulfillment_Expire_Anonymous) flow throws a "FIELD_CUSTOM_VALIDATION_EXCEPTION" error when it tries to edit a closed Fulfillment (MED_Fulfillment__c) record. This is because the flow runs as the user who closed the fulfillment and the MED_Cannot_Edit_When_Closed validation rule on the Fulfillment object prevents the same user from editing the closed record.
Impacted CapabilitiesInquiry Management Content ManagementAffected AppsMedical Information Cloud - Classic Medical Information Cloud - Lightning
Affects VersionsMIC V12Fix VersionV13
Steps to Reproduce1. Create a new Fulfillment record. 2. Close the Fulfillment record. The Fulfillment: Expire Anonymous flow will run automatically after 30 days. 3. Notice the "FIELD_CUSTOM_VALIDATION_EXCEPTION" error that is thrown. The Anonymous Key (MED_Anonymous_Key__c` field on the Fulfillment record does not get updated.
Workaround1. Create a new checkbox field on the Fulfillment object called "Override Lock" (MED_Override_Lock__c). 1. Set the default value to false. 2. Update the MED_Cannot_Edit_When_Closed validation rule on the Fulfillment object. 1. At the beginning of the Error Condition Formula, add "!ISCHANGED(MED_Override_Lock__c) &&". This prevents the validation rule from firing when the Override Lock field is changed. 3. Update the Fulfillment: Expire Anonymous flow to change the Override Lock value from false to true. 4. Create a new flow called "Fulfillment: Reset Override Lock". This flow should reset the Override Lock field to its default value (false).
Resolution Notes- Upgrade to MIC V13 - Requires manual config change. Perform step 2 shown above (steps 1, 3, and 4 are already completed as part of V13 update).