Table of Contents |
---|
...
Property | Type | Description |
---|---|---|
id | uuid | Automatically generated |
name | string | Description of the sanction rule |
positions | enum[] | Optional - Applicable to players or coaches |
Penalty matching | ||
matchers[] | object[] | Types of penalties |
name | string | Name of the penalty to match |
code | string | Optional - code of the penalty to match |
injury | boolean | Optional - accounts for if there’s a linked incident report with an injury or not |
Accumulation | ||
order | number | Accumulation precedence order |
resetAccumulation | number | Optional - number of infractions to reset the count after |
accumulations[] | object[] | Total number of infractions required to be accumulated |
total | number | Optional? - Total number of infractions |
sanctionId | uuid | Resulting sanctionThis could potentially be multiple..? 🚩 |
Breaks
Required to define breaks when calculating the suspension expiry date for the season
...
When the game is completed (or certified, depending on settings), get all parent rulebooks of the schedule office
Cancel out sanctions in parent rulebooks that have a matching sanction in a child rulebook by matchers
Determine matching sanction rule for each player
Each penalty typically only results in one suspension per game
Hockey has some exceptions with accumulations and fighting
Determine sanction rules by matching the strictest penalty name/code match and order
TODO: indirect red will affect yellow here somehow 🚩
Get all past penalties and suspensions of all suspend-able players in the same season
In soccer, limit both to same office
Determine the sanction(s) based on the accumulation rules
accumulations[] is ordered, find the matching total based on the number of penalties incurred in past games and current. Account for reset count.
If there are accumulated suspensions, they will be pending until the prior suspension has completed
7.2(c) results in 3 games, then later 7.8(c) will result in 3 games (15 days) immediately then AS107 5 games (25 days) following its completion
If there is an expiry ratio defined, calculate the expiry based on the number of days
If the expiry falls within a break, extend it by the number of days within that break
When creating the suspension, send a notification to the player, team and officesofficials and office admins (except player, will be based on notification setting)
Supplemental
Status | |
---|---|
|
...
|
...
|
League administrators may edit the suspension add additional suspensions to increase the required number of games and expiry date. This does not affect the automatic game suspension.
If a suspension has the Appealed status, it is not effective. The suspension must be validated to meet the minimum games of the sanction and automatic game suspension is not affected.
The suspension should follow the expiry ratio logic and breaks defined in the rulebook
If a suspension has the Appealed status, it is still Active at it’s minimum number of games of the sanction as those are not appealable
Status colour Blue title TODO
Lineup Status
Status | ||||
---|---|---|---|---|
|
...
If the suspension type is Indefinite, the suspension can never automatically be completed
Status colour Blue title TODO Jira Legacy server System JIRA serverId 03e16d48-9e59-3010-89f5-a1a3500d66b7 key SPR-646
If there is an expiry date, the suspension is considered Expired once that date passes if it is not yet completed based on the required games
Status colour Blue title TODO This will require a task to run at midnight daily (based on the timezone of the office)
Jira Legacy server System JIRA serverId 03e16d48-9e59-3010-89f5-a1a3500d66b7 key SPR-646
A suspension completes once the suspension has the required amount of purges that are completed games
Status colour Green title COMPLETE If there is a pending suspension dependent on a completed suspension, start the dependent suspension
Syncing
Status | ||||
---|---|---|---|---|
|
...