Skip to content

About

mock contractor risk & compliance tracker

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Risk Compliance Portal

A mock contractor risk & compliance tracker, in the spirit of platforms like Highwire/Veriforce. Built as a personal portfolio project to practice a full Java/Angular stack: an Angular frontend backed by a real Spring Boot REST API with validation, error handling, and a database.

Screenshot 2026-07-12 062125 Screenshot 2026-07-12 062140 Screenshot 2026-07-12 062155 Screenshot 2026-07-12 062203

Stack

  • Frontend: Angular 22, TypeScript, RxJS
  • Backend: Java 17, Spring Boot 4 (Spring Web, Spring Data JPA, Bean Validation), H2 in-memory database
  • Tests: Vitest (frontend), JUnit + MockMvc (backend)
  • CI: GitHub Actions runs both test suites and the production build on every push

Features

  • Dashboard with live compliance stats (total contractors, action required, fully compliant) computed server-side from real data
  • Contractor registry with full create/read/update/delete, server-side validation (grade, TRIR/EMR ranges, insurance status), and inline error feedback
  • Analytics page with a breakdown of contractors by safety grade and insurance status
  • REST API with proper HTTP status codes (201/204/404/400), a global exception handler, and CORS restricted to the frontend's origin

Running it locally

Requires Java 17 and Node 20+. No database install needed, the backend uses an in-memory H2 database seeded with sample data on startup.

1. Start the backend (from backend/):

./mvnw spring-boot:run

This starts the API on http://localhost:8080. The Maven wrapper downloads Maven itself on first run, no local Maven install required.

2. Start the frontend (from the repo root):

npm install
npm start

Then open http://localhost:4200.

API overview

Method Endpoint Description
GET /api/contractors List all contractors (?summary=true for latest 5)
GET /api/contractors/stats Aggregate counts for the dashboard/analytics
GET /api/contractors/{id} Get one contractor
POST /api/contractors Create a contractor (validated)
PUT /api/contractors/{id} Update a contractor (validated)
DELETE /api/contractors/{id} Remove a contractor

Running the tests

# backend
cd backend && ./mvnw test

# frontend
npm test

A note on how this was built

I built this app structure myself. I used Claude for assistance in plugging data into the Spring Boot backend (entity/repository/service/controller layers, validation, CORS, tests), throwing the README together, and for cleaning up the frontend service layer that calls the API. I'm a CS student (WGU) building this to demonstrate applied Java/Angular skills.

About

mock contractor risk & compliance tracker

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages