ReimbursementRequest
The ReimbursementRequest entity, mapped to the reimbursement_requests table.
| Table | reimbursement_requests |
| Tenant-scoped | Yes — extends TenantOwned |
| Columns | 7 |
| Relationships | 3 |
| Source | backend/src/main/java/com/motorph/payroll/model/ReimbursementRequest.java |
Columns
| Field | Type | Column | Null | Notes |
|---|---|---|---|---|
requestId | Integer | request_id | — | primary key, generated |
requestDate | LocalDate | request_date | — | — |
amount | BigDecimal | amount | — | — |
description | String | description | Yes | — |
status | String | status | — | — |
approvedDate | LocalDateTime | approved_date | Yes | — |
processedDate | LocalDateTime | processed_date | Yes | — |
Plus tenant_id, inherited from TenantOwned. Hibernate stamps it on insert and adds where tenant_id = ? to every query, so it is never written or read by application code.
Relationships
| Field | Kind | Target | Join column | Required |
|---|---|---|---|---|
employee | @ManyToOne | Employee | employee_number | Yes |
approvedBy | @ManyToOne | Employee | approved_by | — |
processedBy | @ManyToOne | Employee | processed_by | — |
Referenced by
| Entity | Field | Kind |
|---|---|---|
| ReimbursementTransaction | request | @ManyToOne |
Neighbourhood
Repository
ReimbursementRequestRepository
Declared over ReimbursementRequest with id type Integer, with JpaSpecificationExecutor for dynamic filtering. Source: backend/src/main/java/com/motorph/payroll/repository/ReimbursementRequestRepository.java
| Method | Returns | Notes |
|---|---|---|
findWithDetailsByRequestId(Integer requestId) | Optional<ReimbursementRequest> | derived |
findAllByEmployee_EmployeeNumberOrderByRequestDateDesc(Integer employeeId) | List<ReimbursementRequest> | derived |
Reached by
These controllers hold — directly or through a service they depend on — a repository over ReimbursementRequest.
| Controller | Base path | Endpoints | Module |
|---|---|---|---|
| ReimbursementRequestController | /api/reimbursement-requests | 7 | Payroll |
| ReimbursementTransactionController | /api/reimbursement-transactions | 6 | Payroll |
This page is rebuilt from the source on every docs build by docs-site/scripts/gen-code-wiki.mjs. Editing it has no effect — change the code, or, if what you want to say is prose, write it in docs/.