9 Commits

Author SHA1 Message Date
Jp
b95f23f223 upgrade to filament v4 2026-02-19 01:26:02 +08:00
Jp
7899ed75ea feat(sales): add discount support with ledger accounting
- Add discount_type column to transactions table via migration
- Update Sale model to use fillable instead of guarded for better security
- Implement discount account ledger creation when discount is applied
- Fix net amount calculation to include discount in CreateSaleAction
- Remove unused "Exempt" column from sale transaction table
- Make discount_type required when discount is enabled in form
- Update form data mutation to properly handle discount calculations
2026-02-18 21:40:39 +08:00
Jp
5d427cdea4 feat: add discount management and PDF export for transmittals
- Create Discount model, migration, and Filament resource with relation to Client
- Add PDF export functionality for transmittals using DomPDF
- Include discount type selection in sales transactions
- Fix account filtering logic in expense resource
- Update export job to generate PDF instead of Excel
2026-02-18 01:42:44 +08:00
Jp
f5c8ec04ad feat: add account linking and improve sales table
- Add many-to-many relationships between Sale/Expense and Account models
- Create pivot tables for account_sale and account_expense with migrations
- Implement account syncing during sale/expense creation and editing
- Add accounts_list attribute to display comma-separated account names
- Introduce SaleService with DTO for sale creation logic
- Simplify sales table columns to show branch, reference, date, and creator
- Calculate and store aggregated financial fields from transactions
- Make series field read-only instead of disabled in sale form
2026-02-15 18:57:18 +08:00
Jp
76a52d7e82 fix(database): update foreign key constraints to cascade on delete
Update foreign key constraints on accounts and transmittals tables to cascade deletions, ensuring data integrity when referenced clients or branches are removed. The down migrations revert to the previous behavior.
2026-02-11 05:24:44 +08:00
JP
92178271e4 feat: updates on sales 2024-11-18 16:36:37 +08:00
JP
3af7207ec3 feat: updates 2024-08-15 20:11:21 +08:00
JP
140e821e0c feat: initial commit 2024-08-05 08:04:35 +08:00
JP
4b00590c89 Set up a fresh Laravel app 2024-07-25 13:35:36 +08:00