Skip to main content
function createMaxHoursDayRule(config): CompilationRule;
Limits how many hours a person can work in a single day. Supports entity scoping (people, roles, skills) and time scoping (date ranges, specific dates, days of week, recurring periods).

Parameters

config
MaxHoursDayConfig
required

Returns

CompilationRule

Examples

createMaxHoursDayRule({
  hours: 8,
  priority: "MANDATORY",
});
createMaxHoursDayRule({
  roleIds: ["student"],
  hours: 4,
  dayOfWeek: ["monday", "tuesday", "wednesday", "thursday", "friday"],
  priority: "MANDATORY",
});