CSEN_RemoveFeeLines_TDTM
Course Connection trigger handler/TDTM to remove/delete fee line
Table of Contents
Custom Permission | REDU - Student, REDU - Admin |
Event | AfterUpdate |
Object | Course Connection |
Related RIO Education Settings | None |
Description
If a student withdraws from a Course before census date, meaning:
- the Enrollment Status field on a Course Connection is set to "Withdrawn" or "Withdrawn With Penalty", and,
- the Course Connection's "Census Date" field (see notes below) is greater than the current date,
then, this class will delete any related Fee Lines, provided that:
- the Student Fee's "Locked" field is not checked, and,
- the Student Fee's "Paid Amount" field is 0.
- From v3.14.2 onwards, this class will also check the type of Payment records generated.
If there are disbursements, refunds, and voided payments, then, the related Fee Lines will be deleted as well, even if the Paid Amount field is not 0.
This is to allow students to withdraw from Courses before the Census Date, if no "real" payments were made.
- From v3.14.2 onwards, this class will also check the type of Payment records generated.
If this deletion causes any Student Fee records have no related Fee Lines, then those Student Fees are also deleted.
Notes on census date:
The trigger handler looks at the Course Connection's "Census Date" field when deciding whether to delete the Fee Lines.
It can be manually defined, but by default, it will inherit from the Term.
Census Date | |||
Scenario A: Inherit from Term | Scenario B: Manually define at Course Offering | Scenario C: Manually define at Course Connection | |
Term | 18-04-2025 | 18-04-2025 | 18-04-2025 |
Course Offering | 18-04-2025 | 20-04-2025 (manually specified) | 20-04-2025 |
Course Connection |
18-04-2025 |
20-04-2025 | 22-04-2025 (manually specified) |
Use case
This is to automatically delete Fee Lines for a Course, since the student does not need to pay for it because he/she withdrew from the Course before census date.
If there are already payments made, then, the Fee Lines will not be deleted automatically, since the finance team will need to handle the reconciliation / refunds.