/
Setting up Required By Dates - v4.4

Required By dates were added in v4.2 and allows registrations to have a date indication of when the student must take the course. They were updated with a Rules Engine in v4.4. A full description of how the system works can be found here. https://rippleops.atlassian.net/wiki/spaces/CMD/pages/5432392748

The use case and business explanation is at the bottom of the page which provides some context. To set up the feature for a customer follow the below instructions:

TLDR

  1. Add System.Customer.DueSoonDurationDefault page attribute to the Org page.

  2. Create course offering (NOTE - doing this after step 1 ensures the new Course Offering gets the Certificate and DueSoonDuration for the MCW label.

  3. PauseAutomaticRequiredByRuleProcessing

  4. AddRequiredByRule [coursePath] [filterExpression] [baseDateFunction] [durationFunction] e.g. AddRequiredByRule /Root/Fug/StrongPasswords/ HasActiveRegistration() RegistrationDate() DurationFromOffering()

  5. ReEvaluateRequiredByRulesByCoursePathMatch (-logOnly, -debug) (-overrideRequiredByDateSetManually) [string: startPath] [string: terminalElement] [batchSize: optional, default Core.OfferingRuleEvaluatorBatchSize] e.g ReEvaluateRequiredByRulesByCoursePathMatch /Root/Fug/StrongPasswords ""

  6. ContinueAutomaticRequiredByRuleProcessing

Due Soon Intervals

Firstly you need to make sure the the default duration intervals for due soon email notifications and labels in the My Courses Widget is applied. Add System.Customer.DueSoonDurationDefault page attribute to the Org page.

This optional org page attribute is a comma separated list of numbers. It defines the default set of intervals at which a registration will have “due soon” email notifications (if they have been enabled) created and also the largest number will be the threshold for which the MCW marks registrations as Due Soon and adds the below labels.

Not all customers may want email notifications but it is likely all will want the Due Soon label in the MCW to be enabled. 7 days seems like a typical duration for this system setting.


For new offerings

Go to the Manage Registrations and create the offering. Add the Expected Duration in number of days. Creating the offering will also create the Due Soon intervals.

For existing offerings

Go to the offering and add the Expected Duration.

You will also need to run SetDueSoonIntervalsForOffering to create the Due Soon intervals for your existing offering. NOTE - this command only sets the intervals for the due soon labels and notification. It does not set any Required By dates on registrations.

You can use the command SetExpectedDurationForOffering [coursePath] [offeringShortId] [expectedDuration] to update the expected during of an existing offering.

e.g. SetDueSoonIntervalsForOffering /Root/Carnival/CCL/Compliance/HandleComplaints/ HandleComplaints 7

Add Required By Rule

Required By Rules work in a similar way to offering rules in that they have a background thread that is constantly re-evaluating them. This means you will need to PauseAutomaticRequiredByRuleProcessing before you can add any rules. See https://rippleops.atlassian.net/wiki/spaces/CMD/pages/5432392748 for full details of rules

Rules are constructed as

  • filterExpression that users predicates to determine which users will be given the RequiredBy Date

  • Base Date function - this determines which is base date to determine the RequiredBy Date. It could be a constant date, or something from a user org profile field, or certificate.

  • Duration function - this determines how many days after the base date the RequiredBy Date will be set. It can be a constant or come from the course offering. I would generally recommend doing the latter as it means the customer can change the duration themselves if necessary

AddRequiredByRule [coursePath] [filterExpression] [baseDateFunction] [durationFunction]

e.g. AddRequiredByRule /Root/Fug/StrongPasswords/ HasActiveRegistration() RegistrationDate() DurationFromOffering()

Like offering rules you will also need to ReEvaluate your new rule after it has been added

ReEvaluateRequiredByRulesByCoursePathMatch (-logOnly, -debug) (-overrideRequiredByDateSetManually) [string: startPath] [string: terminalElement] [batchSize: optional, default Core.OfferingRuleEvaluatorBatchSize]

e.g ReEvaluateRequiredByRulesByCoursePathMatch /Root/Fug/StrongPasswords ""

Finally you will need to ContinueAutomaticRequiredByRuleProcessing

Business Use Case

It is common that important training needs to be completed within a certain time period of the trainee being registered. Crew may need to complete familiarization training within 7 days of joining a vessel, or maybe new-hires need to complete their orientation within their first month are just some examples.  

This feature allows a course offering to be given a “Required By” duration.  This means the trainee must complete the course within a certain number of days after the base date defined in the rule e.g “Course Offering End date, Embarkation Date, Hire Date”. You can even set multiple rules and have offerings with different durations so you can provide precise deadlines to different groups of students.

Trainees are made aware of the “Required By” duration by seeing a new column under the My Courses tab or Gradebook.

A new set of labels will also appear next to any courses that are getting close to the deadline or are already overdue.

To help ensure courses are completed on time the system can also send email reminders and overdue notices to the trainee or to managers, admins or instructors who may need to chase up and ensure compliance and timely completion.

Required By date also appear in our new reporting system.

If you have some courses in mind that this feature would suit, let your Customer Success Manager or our Support team know you are interested and we can discuss your implementation requirements in further detail.


Relevant Tasks

https://rippleops.atlassian.net/browse/COREDEV-4511

https://rippleops.atlassian.net/browse/COREDEV-5005