Status: Architecture extracted from the archived system docs, controller inventory and three RFDs. July 2026 observations are evidence of that snapshot, not a fresh implementation/security review.
Disciplinary composes existing systems rather than building a second approval engine or payroll calculator. TenantDb records are CompanyId-scoped. The defining sequence is policy → incident → proposed trigger → human decision → downstream action; not every incident automatically becomes a penalty.
| Component | Responsibility / source starting point |
|---|---|
| Core disciplinary domain | DisciplinaryService.cs; policies, threshold-trigger logic and suspension handling. |
| Admin operations | AdminDisciplinaryService.cs and Admin Disciplinary controller. |
| Employee operations | Employee/DisciplinaryService.cs; employee-visible incidents and comments. Interaction was not live-driven. |
| Preferences | Employee/MileStoneEmailExemptionsService.cs; milestone-email opt-out, not disciplinary consequences. |
| Frontend | Admin source under pages/dashboard/tasks/disciplinary/; approval under pages/approval/{violations,suspensions}; employee under employee-dashboard/disciplinary/, including ChatComponent. |
| Domain definitions | DisciplinaryModel.cs, policy/violation/trigger/suspension and exemption entities. See ‣. |
Source file sizes are snapshot details, not current code metrics. Source paths do not determine browser routes.
Threshold proposals — UF3
HasThreshold and ViolationCount configure escalation for a violation type. Qualifying accumulation raises an EmployeeViolationTrigger with proposed action, amount where relevant and New status. Employee versus System origin must remain explicit. Approval authorises execution; New is a normal review queue state. Eligible counted statuses, time window, reset, concurrency and repeat-trigger prevention are not specified by the archive.
Suspension composition — UF4/UF5
EmployeeRequestId links the suspension to Requests’ role-chain approval. Employment flags/dates remain on the suspension. HasBeenRecovered and RecoveredInPayrollId identify unpaid recovery in Payroll. Paid/unpaid setup, approval, effective employment state and financial result must not be collapsed into one status. A pending chain, missing recovery and reinstatement are different investigations.
The source associates Deduction with Payroll, Demotion/Redeployment with grade/role changes, and Termination with exit. This is an ownership map, not proof of every receiving service’s execution contract. There is no complete transactional/outbox, callback, scheduler, reversal or idempotency specification here.
The archived capture observed middleware-dev.paidhr.com/admin/disciplinary/*, including select/view operations. Core also exposes Admin/Disciplinary/*. The screen-to-host/operation split is incomplete; do not substitute a core endpoint or invent REST paths from UI routes. Trace the actual client request and handler before changes.
The controller inventory has class-level [Authorize], bearer authentication and tenant identity from claims. can_view_disciplinary_details and applicable approval permissions gate access; the source does not establish every operation-level check. Verify tenant plus permitted employee/record scope server-side, including offender and optional target, evidence downloads, comments and approval actions. These are review obligations, not a claim that all checks were tested.
Retain author/source distinction and linked incident, review and pay evidence. Handle attachments and victim information as sensitive; do not expose broad case details merely because a user can view an employee profile. Keep tokens and private evidence out of diagnostic notes.