CrmSettingsChange
Field-level audit trail for a CRM settings save; one row per changed field.
| Table | crm_settings_changes |
| Tenant-scoped | Yes — extends TenantOwned |
| Columns | 6 |
| Relationships | 1 |
| Source | backend/src/main/java/com/motorph/payroll/model/CrmSettingsChange.java |
Columns
| Field | Type | Column | Null | Notes |
|---|---|---|---|---|
changeId | Integer | change_id | — | primary key, generated |
modifiedBy | String | modified_by | — | — |
modificationDate | LocalDateTime | modification_date | — | — |
fieldChanged | String | field_changed | Yes | — |
oldValue | String | old_value | Yes | — |
newValue | String | new_value | 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 |
|---|---|---|---|---|
crmSettings | @ManyToOne | CrmSettings | crm_settings_id | Yes |
Neighbourhood
Repository
CrmSettingsChangeRepository
Declared over CrmSettingsChange with id type Integer. Source: backend/src/main/java/com/motorph/payroll/repository/CrmSettingsChangeRepository.java
| Method | Returns | Notes |
|---|---|---|
findAllByCrmSettings_CrmSettingsIdOrderByModificationDateDesc(Integer crmSettingsId) | List<CrmSettingsChange> | derived |
Reached by
These controllers hold — directly or through a service they depend on — a repository over CrmSettingsChange.
| Controller | Base path | Endpoints | Module |
|---|---|---|---|
| CrmDealController | /api/crm/deals | 11 | CRM |
| CrmSettingsController | /api/crm/settings | 3 | CRM |
Generated page
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/.