ORD_UpdateChildStatuses_TDTM
Order trigger handler/TDTM to update the status of child Study Credit and Study Registration records
Table of Contents
Custom Permission | None |
Event | AfterUpdate |
Object | Order |
Related RIO Education Settings | None |
Description
Introduced in v3.14, this class is used alongside the Order Status Custom Metadata Type, to handle the mapping of Study Credit and Study Registration status fields.
When the status of an Order is updated, this class will automatically update the status fields of the Order's child records:
- Study Credit's “Activation Status”
- Study Registration's “Status”
using the respective values defined in the Order Status Custom Metadata Type.
Use case
For example, a student registers (places an order) for a Study Offering, and creates an Order with the Status = Draft.
There are child Study Credits and Study Registration records, which are in Draft status as well.
The student then completes payment, and the Order will have Status = Paid.
The statuses of the child Study Credits and Study Registration records will be automatically updated by this class, based on the field mapping defined in the Order Status Custom Metadata Type.