Commit Graph

56 Commits

Author SHA1 Message Date
Jp
673a6ce166 chore: migrate from docker compose to kubernetes deployment
- Replace Docker Compose setup with Kubernetes manifests for deployment
- Simplify Dockerfile to use PHP's built-in server instead of nginx+supervisor
- Add Makefile with build and deploy commands for local development
- Update environment configuration for production deployment
- Remove docker-specific configuration files (nginx.conf, supervisord.conf)
2026-02-25 22:05:41 +08:00
Jp
e57e6d3413 feat(docker): add standalone Docker setup and remove docker-compose
- Replace Laravel Sail docker-compose with a single-container Dockerfile
- Configure nginx and PHP-FPM via supervisor for production-like environment
- Include optimized PHP extensions and Redis support
- Simplify deployment by removing multi-service orchestration
2026-02-19 16:33:03 +08:00
Jp
feba3f1464 style: remove unnecessary !important from CSS utility classes
The !important flag was previously used to override Tailwind's default styles, but it is no longer needed after recent framework updates. This change improves maintainability and follows CSS best practices by avoiding excessive specificity.
2026-02-19 03:18:00 +08:00
Jp
6eeedbeeb0 feat(transmittal): replace PDF export with Excel export and add logo
- Remove PDF export functionality from TransmittalResource and CreateTransmittal page
- Add new TransmittalExcelExport class for formatted Excel exports with company logo
- Update export jobs to generate unique filenames per user and refresh user data
- Replace PDF export action with Excel export in table actions
- Comment out logo in PDF view template as it's no longer used
- Fix import alias for Excel export action in GeneralLedger
2026-02-19 03:11:17 +08:00
Jp
b95f23f223 upgrade to filament v4 2026-02-19 01:26:02 +08:00
Jp
90c92650b7 upgrade to filament v4 2026-02-19 01:25:41 +08:00
Jp
2bf12aa4e8 fix: correct notification class usage in PDF export job
The notification was using the wrong class (Notifications instead of Notification). This caused the export completion notification to fail. Updated the import and instantiation to use the correct Filament Notification class.
2026-02-18 23:13:46 +08:00
Jp
df66727379 refactor: use correct Filament Action import in export jobs
Update import statements to use Filament\Notifications\Actions\Action instead of the incorrect Actions\Action and NotificationAction aliases. This ensures consistency with the Filament notification system.
2026-02-18 23:07:29 +08:00
1d6238e9cb Merge pull request #9 from kingjaypee12/jp/updates-on-sales
Jp/updates on sales
2026-02-18 22:58:34 +08:00
Jp
d8077f200a feat: replace Excel export with PDF export for transmittals
- Add new TransmittalPDFExportJob to generate PDFs using dompdf
- Remove old Excel export implementation (TransmittalsExport)
- Update ExportCompleteJob to use new PDF job instead of Excel
- Add TestQueueJob for queue testing with new route
- Update notification label from "Download File" to "Download PDF File"
- Fix auth() helper usage by importing Auth facade consistently
2026-02-18 22:57:34 +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
2644be0505 Merge pull request #8 from kingjaypee12/jp/sales-clean-up
feat(SaleResource): redirect to client after sale creation
2026-02-16 02:08:01 +08:00
Jp
9ddb71f03d feat(SaleResource): redirect to client after sale creation
When a client is associated with the sale, redirect to the client's view page with the sales relation manager active instead of the default list page. This improves the user workflow by keeping the context focused on the client.
2026-02-16 02:06:59 +08:00
eadcc0b3d7 Merge pull request #7 from kingjaypee12/jp/sales-clean-up
Jp/sales clean up
2026-02-16 02:03:02 +08:00
Jp
8c6fa6cb08 refactor(client): extract base account generation to command
Move the logic for generating base accounts for a new client from the ClientObserver into a dedicated command class (GenerateBaseAccountCommand). This improves code organization and reusability.

- The command is now used in the ClientObserver::created method.
- The command is also made available as a manual action in the AccountsRelationManager table header, allowing admins to generate base accounts for existing clients that lack them.
- Added necessary imports to the CreateSale page, though the command is not directly used there in this diff, suggesting preparatory work for future integration.
2026-02-16 02:02:26 +08:00
Jp
7bcfaff311 refactor: extract transaction creation and account syncing to actions
- Introduce CreateRecordTransactionsAction to handle transaction creation for any model
- Introduce SyncAccountsAction to encapsulate account synchronization logic
- Refactor CreateSaleAction to use new actions and handle full sale creation flow
- Simplify CreateExpense and CreateSale pages by delegating to actions
- Ensure proper transaction handling with database rollback on failure
2026-02-16 01:48:25 +08:00
Jp
e04689acca refactor(sales): replace service with command and action pattern
- Replace SaleService with CreateSaleCommand and CreateSaleAction for better separation of concerns
- Move sale creation logic into dedicated command class following command pattern
- Update CreateSale.php to use new action instead of direct service call
- Wrap sale creation in database transaction for data consistency
2026-02-16 01:22:00 +08:00
3cf5f6db6a Merge pull request #6 from kingjaypee12/fix/sales-related-table
feat: add account linking and improve sales table
2026-02-15 18:57:49 +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
7bbe6e2d2a Merge pull request #5 from kingjaypee12/jp/fix-sales-breadcrumbs
feat(client): add client context to sales and expenses creation
2026-02-15 17:44:32 +08:00
Jp
fbc01bf1a4 feat(client): add client context to sales and expenses creation
- Disable branch selection in sale form when creating from client context
- Pass client ID to create pages via URL parameter
- Update breadcrumbs to reflect client navigation path
- Simplify relation managers by reusing resource tables and adding custom create actions
2026-02-15 17:43:33 +08:00
Jp
ff07f6f810 fix: remove debug statement from account options query
The dd() statement was accidentally left in production code, causing debug output to be displayed. This removes it to ensure proper functionality.
2026-02-14 14:14:33 +08:00
Jp
2bd8e99f64 fix: remove branch filter and add debug output for revenue accounts
The branch filter was incorrectly limiting available revenue accounts in certain scenarios. Temporarily added debug output to investigate account query results.
2026-02-14 14:13:24 +08:00
Jp
950e5613e6 Merge https://git.jpaleviado.site/kingjaypee12/MKM 2026-02-12 16:30:41 +08:00
Jp
fc118b8a6c Merge branch 'main' of https://github.com/kingjaypee12/MKM-App 2026-02-12 16:29:36 +08:00
Jp
a80e9a7b1c feat: add Laravel Horizon for queue monitoring and management
- Install Horizon package and configure with default settings
- Add HorizonServiceProvider with access gate for super_admin role only
- Integrate Horizon dashboard link into Filament admin panel navigation
- Update composer dependencies including Horizon and related package updates
2026-02-12 16:29:30 +08:00
d793abec9e Merge pull request #4 from kingjaypee12/fix/error-on-production
feat(TransmittalResource): enhance search functionality across relate…
2026-02-12 16:29:16 +08:00
fcac27b34d Merge pull request 'feat(TransmittalResource): enhance search functionality across related models' (#5) from fix/error-on-production into main
Reviewed-on: #5
2026-02-12 08:15:26 +00:00
Jp
fc672e4f4a feat(TransmittalResource): enhance search functionality across related models
Implement wildcard search on transmittal series, notes, and files to improve user experience when filtering records. Also extend search capabilities to client company and branch code fields for more comprehensive filtering.
2026-02-12 16:12:35 +08:00
22ea384d52 Merge pull request #3 from kingjaypee12/fix/error-on-production
Fix/error on production
2026-02-11 05:52:54 +08:00
7174bd6c90 Merge pull request 'feat: implement FilamentUser interface for User model' (#4) from fix/error-on-production into main
Reviewed-on: #4
2026-02-10 21:45:13 +00:00
Jp
a77e95d2a5 feat: implement FilamentUser interface for User model
Add FilamentUser interface to allow access control within Filament admin panel. The canAccessPanel method currently returns true for all users, providing a foundation for future permission-based access restrictions.
2026-02-11 05:44:49 +08:00
4f9ec9ebfb Merge pull request 'fix: force HTTPS scheme in all environments' (#3) from fix/error-on-production into main
Reviewed-on: #3
2026-02-10 21:42:11 +00:00
Jp
ee65bdfb31 fix: force HTTPS scheme in all environments
Previously HTTPS was only enforced in production, which could lead to insecure URLs in other environments like staging. This change ensures consistent URL generation across all environments.
2026-02-11 05:41:22 +08:00
f63be7fa5e Merge pull request 'fix: enforce HTTPS in production environment' (#2) from fix/error-on-production into main
Reviewed-on: #2
2026-02-10 21:38:32 +00:00
Jp
7fa8b75b29 fix: enforce HTTPS in production environment
Add URL::forceScheme('https') in AppServiceProvider to ensure all generated URLs use HTTPS when the application is in production. This improves security by enforcing secure connections.
2026-02-11 05:37:54 +08:00
Jp
a8ad07676a Merge branch 'main' of https://git.jpaleviado.site/kingjaypee12/MKM 2026-02-11 05:27:40 +08:00
Jp
6f04a60e43 Merge branch 'main' of https://github.com/kingjaypee12/MKM-App 2026-02-11 05:25:34 +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
5715ab10f2 Merge pull request 'update/ledger' (#1) from update/ledger into main
Reviewed-on: #1
2026-02-10 07:07:10 +00:00
138740648c Merge pull request #2 from kingjaypee12/update/ledger
refactor: streamline sales and expenses management in client resource
2026-02-10 15:06:57 +08:00
Jp
0131193b8d refactor: streamline sales and expenses management in client resource
- Move create/edit logic from relation managers to dedicated resource pages
- Add transaction handling with proper rollback in sale create/update
- Fix expense transaction creation by using correct array access
- Set default client from query parameter in sale/expense forms
- Exclude 'type' field from balance creation to prevent errors
2026-02-10 15:05:36 +08:00
13a0f69ce3 Merge pull request #1 from kingjaypee12/update/ledger
fix: cascade delete related transactions and ledgers for sales and ex…
2026-02-09 22:26:19 +08:00
Jp
0e4da559d6 fix: cascade delete related transactions and ledgers for sales and expenses
Ensure data integrity by cleaning up dependent records when deleting Sale or Expense models. This prevents orphaned transactions and ledgers in the database.
2026-02-09 22:25:08 +08:00
Jp
1548e178bc feat(client): add journals relation and improve transaction ledger handling
- Add journals relation to Client model via Branch
- Update branch selection in JournalsRelationManager to use code instead of name
- Improve tax, withholding, and cash account ledger queries by adding client_id filter and amount checks
- Add missing import for GenerateVoucher command in ExpensesRelationManager
- Label 'Normal Balance' column in AccountsRelationManager
2026-02-09 22:16:10 +08:00
Jp
207f4c1609 feat(client): add financial reports and ledger management
- Add trial balance and general ledger pages to client resource with interactive tables
- Implement sales and expenses relation managers for client-specific transactions
- Enhance transaction handling with proper tax and withholding calculations
- Add date casting to Transaction model and define client relationships
- Configure super admin role bypass in AppServiceProvider
- Update Filament components and fix JavaScript formatting issues
2026-02-09 16:20:55 +08:00
JP
91eb1fbe63 feat: updates on expenses 2025-05-19 00:32:02 +08:00
JP
92178271e4 feat: updates on sales 2024-11-18 16:36:37 +08:00
JP
06a2035cc8 feat: updates on expenses 2024-10-31 00:53:13 +08:00