Compare commits
base: joelthomastrenser/Training-VehicleService-May26:develop-sm-payment-management
joelthomastrenser/Training-VehicleService-May26:main
joelthomastrenser/Training-VehicleService-May26:develop
joelthomastrenser/Training-VehicleService-May26:develop-sm-bugfix-3
joelthomastrenser/Training-VehicleService-May26:develop-sm-bugfix-2
joelthomastrenser/Training-VehicleService-May26:develop-sm-bugfix-1
joelthomastrenser/Training-VehicleService-May26:develop-sm-events
joelthomastrenser/Training-VehicleService-May26:develop-sm-payment-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-inventory-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-service-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-authentication-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-notification-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-user-management
joelthomastrenser/Training-VehicleService-May26:develop-bugfix-1
joelthomastrenser/Training-VehicleService-May26:develop-bugfix-2
joelthomastrenser/Training-VehicleService-May26:develop-bugfix-3
joelthomastrenser/Training-VehicleService-May26:develop-demo-feedback-2
joelthomastrenser/Training-VehicleService-May26:develop-demo-feedback-1
joelthomastrenser/Training-VehicleService-May26:feature
joelthomastrenser/Training-VehicleService-May26:feature-display
joelthomastrenser/Training-VehicleService-May26:bugfix-1
joelthomastrenser/Training-VehicleService-May26:bugfix-3
joelthomastrenser/Training-VehicleService-May26:bugfix-2
joelthomastrenser/Training-VehicleService-May26:feature-1553-1598
joelthomastrenser/Training-VehicleService-May26:feature-1552-1560
joelthomastrenser/Training-VehicleService-May26:feature-1551-1561-1708
joelthomastrenser/Training-VehicleService-May26:feature-admin-management
joelthomastrenser/Training-VehicleService-May26:feature-file-management
joelthomastrenser/Training-VehicleService-May26:feature-customer-management
joelthomastrenser/Training-VehicleService-May26:feature-payment-management
joelthomastrenser/Training-VehicleService-May26:feature-service-management
joelthomastrenser/Training-VehicleService-May26:feature-notification-management
joelthomastrenser/Training-VehicleService-May26:feature-inventory-management
...
compare: joelthomastrenser/Training-VehicleService-May26:f3e42a8b172c8c138965cc82309f987cdd3e0d01
joelthomastrenser/Training-VehicleService-May26:main
joelthomastrenser/Training-VehicleService-May26:develop
joelthomastrenser/Training-VehicleService-May26:develop-sm-bugfix-3
joelthomastrenser/Training-VehicleService-May26:develop-sm-bugfix-2
joelthomastrenser/Training-VehicleService-May26:develop-sm-bugfix-1
joelthomastrenser/Training-VehicleService-May26:develop-sm-events
joelthomastrenser/Training-VehicleService-May26:develop-sm-payment-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-inventory-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-service-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-authentication-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-notification-management
joelthomastrenser/Training-VehicleService-May26:develop-sm-user-management
joelthomastrenser/Training-VehicleService-May26:develop-bugfix-1
joelthomastrenser/Training-VehicleService-May26:develop-bugfix-2
joelthomastrenser/Training-VehicleService-May26:develop-bugfix-3
joelthomastrenser/Training-VehicleService-May26:develop-demo-feedback-2
joelthomastrenser/Training-VehicleService-May26:develop-demo-feedback-1
joelthomastrenser/Training-VehicleService-May26:feature
joelthomastrenser/Training-VehicleService-May26:feature-display
joelthomastrenser/Training-VehicleService-May26:bugfix-1
joelthomastrenser/Training-VehicleService-May26:bugfix-3
joelthomastrenser/Training-VehicleService-May26:bugfix-2
joelthomastrenser/Training-VehicleService-May26:feature-1553-1598
joelthomastrenser/Training-VehicleService-May26:feature-1552-1560
joelthomastrenser/Training-VehicleService-May26:feature-1551-1561-1708
joelthomastrenser/Training-VehicleService-May26:feature-admin-management
joelthomastrenser/Training-VehicleService-May26:feature-file-management
joelthomastrenser/Training-VehicleService-May26:feature-customer-management
joelthomastrenser/Training-VehicleService-May26:feature-payment-management
joelthomastrenser/Training-VehicleService-May26:feature-service-management
joelthomastrenser/Training-VehicleService-May26:feature-notification-management
joelthomastrenser/Training-VehicleService-May26:feature-inventory-management
1 Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
f3e42a8b17 |
Merged PR 1172: Payment Management Refactoring - 1930
User Story #1949 User Story #1950 **Changes** * Added `DataStoreLockGuard` header to project configuration and implemented the class for scoped mutex management. * Refactored `Invoice` model to replace CSV-based serialization with `SerializedInvoice` struct, removing legacy `getHeaders()` and string parsing logic. * Updated `DataStore::getInvoices()` to load records via `loadRecords`, refresh cache, and automatically enrich `Invoice` objects with linked `ServiceBooking` and `InventoryItem` entities. * Implemented `DataStore::saveInvoices()` using the `saveRecords<Invoice, SerializedInvoice>` template for direct shared memory persistence. * Integrated `DataStoreLockGuard` across all critical methods in `PaymentManagementService`: `sendPaymentReminders`, `generateInvoice`, `getInvoices`, `completePayment`, `getAllInvoices`, and `confirmPayment`. * Refactored invoice creation and modification flows to use `createNewRecord` for insertion and explicitly set `RecordState::MODIFIED` before triggering `saveInvoices()`. * Updated data access patterns to extract `.data` pointers from `TrackedRecord` wrappers instead of accessing raw map values directly. * Added validation logic in `getInvoices()` to throw `runtime_error` if referenced ServiceBookings or InventoryItems are missing. * Added necessary header dependencies (`Invoice.h`, `DataStoreLockGuard.h`) in service and store layers. Related work items: #1930, #1949, #1950 |