Web Console
The backend webapp is a React, Vite, and MUI console for the DomainTemplate CRUD API. It identifies resources by server-generated id and presents the business fields directly instead of editing a generic JSON payload.
Run the Console
Start the API and the webapp from the repository root:
make java-run
make react-run
Open http://localhost:5173. The webapp reads the API base URL from VITE_API_BASE_URL; the Docker stack builds it with http://localhost:8989, while direct local development defaults to http://localhost:8080.
Routes
| Route | Purpose |
|---|---|
/ |
Dashboard with metrics and the last 10 stored DomainTemplates. |
/domainTemplates |
List, import, export, and delete DomainTemplates. |
/domainTemplates/new |
Create a DomainTemplate with a JSON payload form. |
/domainTemplates/{id} |
View and print one DomainTemplate by ID. |
/domainTemplates/{id}/edit |
Update its label and description by ID. |
/settings |
Choose the console view mode. |
/about |
Show API, documentation, and Swagger UI links. |
View Mode
Use the icons in the top bar to choose bright, dark, or system mode. The selected mode is saved in local storage for the browser.
List DomainTemplates
The DomainTemplates page lists id, code, label, description, createdDate, and lastModifiedDate. Desktop and tablet layouts use MUI DataGrid. Mobile layouts provide the same view, edit, and delete actions in a compact list.
Create or Update a DomainTemplate
For creation, enter a required unique code, a required label, and an optional description. The server assigns the ID and dates. Create calls POST /api/v1/domaintemplate.
For update, the console loads /domainTemplates/{id} and disables code because it is immutable. Only label and description are sent to PUT /api/v1/domaintemplate/{id}.
Delete a DomainTemplate
The delete action asks for confirmation, then calls DELETE /api/v1/domaintemplate/{id}.
View and Print
The detail page shows all six fields. Use the print action to print the detail view; navigation and action controls are hidden in print output.
Import and Export
The DomainTemplates page can seed the standard DomainTemplate records and import or export JSON and CSV. Seed and import upsert by code: existing business objects are updated and missing ones are created. Imported IDs and dates never replace server-owned values.
JSON import accepts an array of records:
[
{
"id": 42,
"code": "CUSTOMER",
"label": "Customer",
"description": "Customer master data",
"createdDate": "2026-08-30T17:00:00Z",
"lastModifiedDate": "2026-08-30T17:00:00Z"
}
]
CSV import uses this header:
id,code,label,description,createdDate,lastModifiedDate
42,CUSTOMER,Customer,Customer master data,2026-08-30T17:00:00Z,2026-08-30T17:00:00Z
Both formats round-trip exports. During import, code, label, and description are the effective business input; id, createdDate, and lastModifiedDate are ignored.
Coverage
Generate coverage reports for the monorepo:
make coverage
Reports are written to:
| Stack | Report location |
|---|---|
| Java API | java/api/target/site/jacoco/index.html |
| Java client | java/java-client/target/site/jacoco/index.html |
| React backend | react/backend/coverage/index.html |
| React client | react/react-client/coverage/index.html |
| Dart client | flutter/dart-client/coverage/lcov.info |