Changelog: Dwi - 2026-06-08
Daily Changelog - Waste Vantage Legacy
Overview
Today's changes by Dwi focus on improving the invoicing system, fixing pickup completion problems, and updating bin hire pricing lookup logic to correctly respect service area zones. This includes transitioning legacy additional data to structured invoice extra records, modifying order controller retrievals, and refining mail/detail layouts.
Added
- Structured Invoice Extras Helper (
app/Repositories/InvoiceManagement.php)- Added the
updateOrCreateExtrastatic method to normalize legacy invoiceadditional_dataarray intoOrderInvoiceExtrarecords. - Implemented automatic recalculation of total, gst, and grandtotal within this helper after writing extra records.
- Added the
Changed
- General Waste Bin Hire Controller (
app/Http/Controllers/Admin/GeneralWasteBinHireController.php)- Updated
getServiceOptionsto receive and filter by$zoneId(service area) when retrieving pricing options. - Integrated
area_idinto pricing checks when loading bin size service configurations. - Modified rates update check to inherit existing extra hireage price/days when inserting new pricing records.
- Updated
Fixed
- Order Edit and Completion Recalculations (
app/Http/Controllers/Admin/OrderController.php)- Fixed a completion problem by automatically upgrading legacy additional invoice data to the extras table upon viewing invoices, re-fetching updated records to ensure accuracy.
- Order Detail Layout (
resources/views/admin/order/show/order-detail.blade.php)- Standardized the label format for Extra Days items and improved quantity formatting.
- Invoice Mail Template (
resources/views/mails/invoice/part-extra-service.blade.php)- Commented out the unused code block that fetched extras directly from legacy
additional_dataJSON.
- Commented out the unused code block that fetched extras directly from legacy
Removed
- None.