All rules are in the formatWHEN <conditions>THEN <actions>
All rules are executed sequentially, from top to bottom
As the rules are executed, the shift will be broken up into segments that match particular rules. The general process is that pay categories will be assigned to these shift segments.
Allowances may be added to a shift.
NOTE: Any rules that check for a pay category should be moved to late in the rule set to allow earlier rules to actually assign a pay category.
If the shift spans midnight (eg: 9pm - 4am), this condition will match the part of the shift after midnight (eg: in this case, midnight - 4am)
Apply pay category
- work from 9am – 2pm
- a break of 30 minutes from 2pm – 2:30pm
- work from 2:30pm – 5pm
- For the first 2 hours, apply pay category "time and a half"
- For the remaining time, apply pay category "double time"
- WHEN: Time Worked in a shift WHERE Work Type is Ordinary Hours is less than than 8h
- THEN: Add remaining time
- WHEN: Time Worked in a shift period WHERE Work Type is Ordinary Hours is greater than than 152h
- THEN: Conditional:
- If the day is Monday-Saturday, apply M-S Overtime
- If the day is Sunday, apply Sunday Overtime
For this action to work correctly, rules in the rule set that assign pay categories (e.g.: time of day, day of week) should also consider this work type.
Once all of the rules have been applied, the interpreter will determine which is higher - the value of the shift as it stands with the rules applied or the amount the employee would have been paid with ordinary hours.