Attention: Confluence is not suitable for the storage of highly confidential data. Please ensure that any data classified as Highly Protected is stored using a more secure platform.
If you have any questions, please refer to the University's data classification guide or contact ict.askcyber@sydney.edu.au

Skip to end of banner
Go to start of banner

TAP-1304: MS - Add validation rule

Skip to end of metadata
Go to start of metadata

You are viewing an old version of this content. View the current version.

Compare with Current View Version History

« Previous Version 4 Next »

Persona + Need + Purpose

As a GA user

I want to ensure that all stages of the flow are done in order

So that business process is followed.

GA-Entry, GA-Approval, GI-Kickoff -

Acceptance Criteria

  • GI Kick off stage → If gift/pledge doesn’t exist at GIN level and stage updated to GI-Kickoff throw an error

    • Error message : “Please check that the gift pledge exists and credited opportunity updated at Gift level”

  • GA entry and GA approval cannot be updated manually but should be updated by flow

    • Error message: “This stage is updated automatically and cannot be set manually. Please contact Gift Administration for more information”

Implementation

Create 2 new Validation Rules on Gift Implementation Object:

Validation Rule Name

Logic

Condition Formula

Error Message

Usyd_Require_GiftPledge_Kick_Off_Stage

Check if the Stage is Updated to “5. GI - Kick Off” and if the Gift/Pledge field is empty and throw the error message below:

ISCHANGED(AQC_Stage__c) && ISPICKVAL(AQC_Stage__c, '5. GI - Kick Off') && ISBLANK(AQC_GiftPledge__c)

“Please check that the gift pledge exists and credited opportunity updated at Gift level”

Usyd_Disable_Users_To_Update_Gift_Stage

Fire only the error message below once the User is manually updating the Stage to “3. GA-Entry” or “4. GA-Approval”

  • Create a new field (Usyd_VR_Bypass_Toggle__c) as a flag to only allow updating the Stage field via Flow.

  • Update the existing logic of the flow to use the toggle field

NOT(ISCHANGED(Usyd_VR_Bypass_Toggle__c)) && (ISCHANGED(AQC_Stage__c ) && (ISPICKVAL( AQC_Stage__c , '3. GA-Entry') || ISPICKVAL( AQC_Stage__c , '4. GA-Approval')))

“This stage is updated automatically and cannot be set manually. Please contact Gift Administration for more information”

Unit Testing

#1 Update Gift Implementation Stage to GA - Kick Off when Gift/Pledge is blank

Steps:

  1. Log in as a GA user

  2. Go to an opportunity with a Gift Implementation record

  3. Open the Gift Implementation record

  4. Update manually the Stage to “GA - Kick Off“ without a Gift/Pledge linked to it.

Expected Result: Validation Rule should fire with error message “Please check that the gift pledge exists and credited opportunity updated at Gift level

Actual Result: Error message thrown “Please check that the gift pledge exists and credited opportunity updated at Gift level

#2 Update Gift Implementation Stage manually to GA - Entry or GA - Approval

Steps:

  1. Log in as a GA user

  2. Go to an opportunity with a Gift Implementation record

  3. Open the Gift Implementation record

  4. Update manually the Stage to “GA - Entry“ or “GA - Approval“.

Note: These stages can only be updated thru Flow from (Batch Item flow trigger)

Expected Result: Validation Rule should fire with error message “This stage is updated automatically and cannot be set manually. Please contact Gift Administration for more information

Actual Result: Error message thrown “This stage is updated automatically and cannot be set manually. Please contact Gift Administration for more information

Components

Component Name

API Name

Type

Parent Object

Operation (New/Update)

Usyd_Require_GiftPledge_Kick_Off_Stage

Usyd_Require_GiftPledge_Kick_Off_Stage

Validation Rule

AQC_GiftImplementation__c

New

Usyd_Disable_Users_To_Update_Gift_Stage

Usyd_Disable_Users_To_Update_Gift_Stage

Validation Rule

AQC_GiftImplementation__c

New

Usyd VR Bypass Toggle

Usyd_VR_Bypass_Toggle__c

Custom Field

AQC_GiftImplementation__c

New

Gift Implementation Layout

Gift_Implementation_Layout

Page Layout

AQC_GiftImplementation__c

Update

System Administrator

Profile

N/A

Update

Read Only

Profile

N/A

Update

AQC Opportunity to Gift

AQC_Opportunity_to_Gift

Permission Set

N/A

Update

  • No labels