PECS_UnenrolmentProcess_TDTM
Course Connection trigger handler/TDTM for withdrawal/unenrollment
Custom Permission | REDU - Student, REDU - Admin |
Event | AfterUpdate |
Object | Course Connection |
Related RIO Education Settings | Auto Clone CC For Withdrawn |
Description
Whenever a student unenrolls from a Course by setting the Enrollment Status field on a Course Connection record to either Withdrawn, Withdrawn With Penalty or Dropped, then this class will handle any of the related Session Connections for that Course Connection.
If a related Session Connection has at least one related Attendance, then its Enrollment Status is set to either 'Dropped' if the Course Connection Enrollment Status is 'Dropped', or 'Withdrawn' otherwise. If the Session Connection has no related Attendances, then it is deleted.
This class will also clone any withdrawn Course Connections for future enrollment.
Use case
If a student has an attendance record and then withdraws from a Course, this trigger will unenroll the related Session Connections as well. It will not delete the Session Connection, but keep it for record purposes.
On the other hand, if a student has no attendance record, there is no need to keep the Session Connection record. This trigger will automatically delete it.
However, if you wish to keep the Session Connection, you can disable this trigger by unchecking the 'Active' checkbox.