Back

OBRASTAFF

Laravel 12Livewire 3PostgreSQLSanctum API
TECHNICAL SUMMARY

A web system that controls personnel, enabling documentation and project assignments for heavy industry. Its core is a single centralized eligibility Action, CheckEmployeeEligibilityForProject, that evaluates a project's active requirements against an employee's documents and returns a typed result — blocking reasons, warnings and what's satisfied. A document's 'effective' status (approved but past its date = doesn't clear) is resolved by one DocumentStatusService, so a date is never compared by hand in two places. The Livewire web UI, the v1 Sanctum API, the dashboard and the PDF/Excel reports all consume the same rule; no screen reimplements it. Seven roles with ~22 granular permissions (spatie/laravel-permission), personnel documents stored on a private disk and served only through Policies, deployed on Railway (FrankenPHP + managed PostgreSQL + persistent volume).

KEY CAPABILITIES
Centralized Eligibility Rule (single Action)
Traffic-light Gate Board for site entry
Effective Document Status (approved + expired = expired)
7 Roles / ~22 Granular Permissions (RBAC)
v1 REST API with Sanctum + rate limiting
PDF & Excel Compliance Reports
ENGINE_SPECIFICATIONS
ACTIVE

Laravel 12

ENGINE SPEC

Tech Stack

ACTIVE

Livewire 3

ENGINE SPEC

Tech Stack

ACTIVE

PostgreSQL

ENGINE SPEC

Relational DB

ACTIVE

Sanctum API

ENGINE SPEC

Tech Stack

ENGINEERING_DECISIONS
PROBLEMThe clearance rule is safety-critical — if each screen recomputes it, they drift and someone enters with an expired certificate.
DECISIONA single Action, CheckEmployeeEligibilityForProject, owns the rule and returns a typed DTO; web, API, dashboard and reports all consume it.
PROBLEM'Approved' documents expire silently — a valid-looking certificate can be past its date.
DECISIONOne DocumentStatusService derives the effective status (approved + past date = expired), so a date is never compared by hand in two places.
PROBLEMPersonnel documents are sensitive and roles range from HR to external auditors.
DECISIONFiles live on a private disk served only through Policies; authorization asks for one of ~22 granular permissions, never a hardcoded role.
CHALLENGE
Encoding safety-critical compliance as one rule reused by web, API, dashboard and reports.
IMPACT
The clearance decision is written once and surfaced right at the site gate — no screen recomputes it.
Visit Live Site →