Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
285 commits
Select commit Hold shift + click to select a range
a041bc8
feat: Phase 28 — Product Categories with colour badges and product fi…
claude Jun 1, 2026
06d55be
feat: Phase 29 — Reorder points with low-stock suggestions and one-cl…
claude Jun 1, 2026
f921e31
feat: Phase 30 — Price Lists with product overrides and global discounts
claude Jun 1, 2026
d756b71
feat: Phase 31 — Project Tracking with billable hours and invoice lin…
claude Jun 1, 2026
35b0d90
feat: Phase 32 — File Attachments for invoices, bills, expenses, and …
claude Jun 1, 2026
33ce8f9
feat: Phase 33 — Credit Notes for invoices and bills
claude Jun 2, 2026
66c543c
feat: Phase 34 — Recurring Invoices with auto-generation
claude Jun 2, 2026
e191fa0
feat: Phase 35 — Aged Receivables and Payables reports
claude Jun 2, 2026
44b1fbf
feat: Phase 36 — Inventory Adjustments for stock count corrections
claude Jun 3, 2026
7767ef9
feat: Phase 37 — Cash Flow Forecast report
claude Jun 3, 2026
8cd0ce5
feat: Phase 38 — Purchase Requisitions with approval workflow
claude Jun 3, 2026
60a728c
feat: Phase 39 — Batch Payments for invoices and bills
claude Jun 3, 2026
142bad4
feat: Phase 40 — Sales Orders with invoice conversion
claude Jun 3, 2026
abc465a
feat: Phase 41 — Delivery Notes linked to sales orders and invoices
claude Jun 3, 2026
f6cb966
feat: Phase 42 — Customer Statements with PDF export
claude Jun 3, 2026
71d4a2f
feat: Phase 43 — Supplier Statements report
claude Jun 3, 2026
d6550e7
feat: Phase 44 — Comparative Profit and Loss report
claude Jun 3, 2026
3d9073c
feat: Phase 45 — Employee Onboarding Checklists
claude Jun 3, 2026
04a8a31
feat: Phase 46 — Performance Reviews with ratings and goals
claude Jun 4, 2026
c3bfbaa
feat: Phase 47 — Training Records and certifications
claude Jun 4, 2026
a2c9e75
feat(hr): Phase 48 — Job Positions & Recruitment Pipeline
claude Jun 4, 2026
53aa649
feat(hr): Phase 49 — Time & Attendance tracking
claude Jun 4, 2026
4d9bec1
chore: ignore .env.bak files
claude Jun 4, 2026
22e6598
feat(inventory): Phase 50 — Asset Management
claude Jun 4, 2026
f7bb222
feat(finance): Phase 51 — Vendor Management profiles and evaluations
claude Jun 4, 2026
494e728
feat(finance): Phase 52 — Customer Portal with token-based access
claude Jun 4, 2026
dfd2ae5
feat(finance): Phase 53 — Budget Management
claude Jun 4, 2026
5d42784
feat(finance): Phase 54 — Multi-Currency Exchange Rate Management
claude Jun 4, 2026
a24c6a8
feat(core): Phase 55 — Audit Log system-wide activity trail
claude Jun 4, 2026
368cf63
feat(core): Phase 56 — Notifications & Alerts inbox
claude Jun 4, 2026
8647dd3
feat(finance): Phase 57 — Document Templates with variable substitution
claude Jun 4, 2026
b857ea1
feat(inventory): Phase 58 — Product Bundles with component tracking
claude Jun 4, 2026
aeea5db
feat(inventory): Phase 59 — Multi-Location Inventory with stock trans…
claude Jun 4, 2026
1961bc9
feat(finance): Phase 60 — Subscription Billing with recurring invoice…
claude Jun 4, 2026
e0c4a0f
feat(finance): Phase 61 — Commission Tracking for sales reps
claude Jun 4, 2026
3d00f1d
feat(finance): Phase 62 — Contract Management
claude Jun 4, 2026
fc7e10f
feat(hr): Phase 63 — Loan & Advance Management
claude Jun 4, 2026
0f051a9
feat(inventory): Phase 64 — Quality Control with checklists and inspe…
claude Jun 4, 2026
c76c3d7
feat(finance): Phase 65 — Return & Refund Management
claude Jun 4, 2026
32957df
feat(inventory): Phase 66 — Inventory Costing (FIFO / Average Cost)
claude Jun 4, 2026
3669530
feat(hr): Phase 67 — HR Shift Scheduling with templates and assignments
claude Jun 4, 2026
cd005e2
feat(hr): Phase 68 — Expense Management with approval workflow
claude Jun 4, 2026
de9c1e9
feat(finance): Phase 69 — Price Lists & Customer Pricing with tiered …
claude Jun 4, 2026
7d867b3
feat(finance): Phase 70 — Tax Management with rates, groups, and comp…
claude Jun 4, 2026
d8dbf6d
feat(hr): Phase 71 — Performance Reviews with KPIs and achievement tr…
claude Jun 4, 2026
d0dc070
feat(finance): Phase 72 — Project Management with tasks and time trac…
claude Jun 4, 2026
6c5562d
feat(hr): Phase 73 — Payroll Processing with payslip generation
claude Jun 4, 2026
00df34d
feat(finance): Phase 74 — Service Agreements & Maintenance Contracts
claude Jun 4, 2026
56154ca
feat(inventory): Phase 75 — Demand Forecasting with moving average an…
claude Jun 4, 2026
4620da2
feat(inventory): Phase 76 — Warehouse Bin & Location Tracking with zones
claude Jun 4, 2026
f309372
feat(finance): Phase 77 — Customer Loyalty & Rewards with points and …
claude Jun 4, 2026
47e2b86
feat(finance): Phase 78 — CRM Leads Pipeline with activities and win/…
claude Jun 4, 2026
c6748fb
feat(inventory): Phase 79 — Product Variants & Attributes with SKU ma…
claude Jun 5, 2026
79ef28b
feat(finance): Phase 80 — Bank Reconciliation with accounts and trans…
claude Jun 5, 2026
887dba1
feat(hr): Phase 81 — Employee Onboarding Checklists with task tracking
claude Jun 5, 2026
d26f662
feat(finance): Phase 82 — Budget Planning & Variance Tracking
claude Jun 5, 2026
b95c8ee
feat(hr): Phase 83 — Employee Leave Management with approval workflow
claude Jun 5, 2026
1c8c85d
feat(hr): Phase 84 — Employee Training & Certifications
claude Jun 5, 2026
06e8036
feat(finance): Phase 85 — Multi-Currency Support with exchange rates
claude Jun 5, 2026
d7fff49
feat(inventory): Phase 86 — Fleet & Vehicle Management with trip logs
claude Jun 5, 2026
90d2afa
feat(finance): Phase 87 — Customer Support Ticketing with comments
claude Jun 5, 2026
e1fa812
feat(inventory): Phase 88 — Supplier Performance Tracking with review…
claude Jun 5, 2026
a309069
feat(hr): Phase 89 — Disciplinary Cases & Grievance Management
claude Jun 5, 2026
ac0f504
feat(inventory): Phase 90 — Lot & Serial Number Tracking with traceab…
claude Jun 5, 2026
921746a
feat(hr): Phase 91 — Timesheet Management with weekly entries and app…
claude Jun 5, 2026
fc7fb8c
feat(finance): Phase 92 — Contract Management with lifecycle and rene…
claude Jun 5, 2026
46db117
feat(core): Phase 93 — Audit Log & Activity Tracking
claude Jun 5, 2026
f177cdd
feat(hr): Phase 94 — Employee Benefits Administration
claude Jun 5, 2026
985f057
feat(inventory): Phase 95 — Purchase Order Management with receiving …
claude Jun 5, 2026
e422d7d
feat(hr): Phase 96 — Employee Performance Reviews with ratings and wo…
claude Jun 5, 2026
5c04833
feat(finance): Phase 97 — Expense Claims Management with approval wor…
claude Jun 5, 2026
9c603e5
feat(finance): Phase 97 — Expense Claims Management with approval wor…
claude Jun 5, 2026
f4dc210
feat(inventory): Phase 98 — Sales Order Management with fulfillment w…
claude Jun 5, 2026
3fb9455
feat(hr): Phase 99 — Job Positions & Recruitment Management
claude Jun 5, 2026
5d45942
feat(hr): Phase 100 — Work Schedules & Shift Management
claude Jun 5, 2026
6f78341
feat(inventory): Phase 101 — Product Price Lists & Customer Discounts
claude Jun 5, 2026
1efca99
feat(finance): Phase 102 — Vendor Bills & Accounts Payable
claude Jun 5, 2026
0d9f25f
feat(finance): Phase 103 — Credit Notes & Invoice Adjustments
claude Jun 5, 2026
ba020a4
feat(hr): Phase 104 — Employee Document Management
claude Jun 6, 2026
f1bc91d
feat(finance): Phase 105 — Payment Terms Management
claude Jun 6, 2026
4cfae70
feat(hr): Phase 106 — Employee Skills & Competency Tracking
claude Jun 6, 2026
00297a8
feat(hr): Phase 107 — HR Announcements & Company Notices
claude Jun 6, 2026
b2ff06d
feat(inventory): Phase 108 — Units of Measure Management
claude Jun 6, 2026
6756fa7
feat(hr): Phase 109 — Employee Exit Management
claude Jun 6, 2026
a6f3beb
feat(finance): Phase 110 — Petty Cash Management
claude Jun 6, 2026
dc5dcb2
feat(inventory): Phase 111 — Inventory Cycle Counting
claude Jun 6, 2026
64c0463
feat(hr): Phase 112 — Employee Position Changes & Promotions
claude Jun 6, 2026
fc2a1b4
feat(inventory): Phase 113 — Product Tags
claude Jun 6, 2026
14463e0
feat(finance): Phase 114 — Bank Transfers between Accounts
claude Jun 6, 2026
ce7308f
feat(hr): Phase 115 — Salary Grades & Pay Bands
claude Jun 6, 2026
7212d64
feat(finance): Phase 116 — Customer Groups & Segmentation
claude Jun 6, 2026
cc3c57a
feat(finance): Phase 117 — Advance Payments & Customer Deposits
claude Jun 6, 2026
0948e15
feat(inventory): Phase 118 — Product Substitutes & Alternatives
claude Jun 6, 2026
14012ea
feat(hr): Phase 119 — Overtime Requests & Approval
claude Jun 6, 2026
f26eae4
feat(finance): Phase 120 — Finance Debit Notes
claude Jun 6, 2026
0f5a8e8
feat(hr): Phase 121 — Employee Surveys & Pulse Checks
claude Jun 6, 2026
c399476
feat(inventory): Phase 122 — Inventory Backorder Management
claude Jun 6, 2026
555a749
feat(finance): Phase 123 — Finance Write-offs (Bad Debt)
claude Jun 6, 2026
a71f322
feat(hr): Phase 124 — HR Flexible Working Arrangements
claude Jun 6, 2026
ce39d39
feat(finance): Phase 125 — Finance Intercompany Transactions
claude Jun 6, 2026
4e3a969
feat(inventory): Phase 126 — Inventory Product Bundles
claude Jun 6, 2026
33f5ba6
feat(inventory): Phase 126 — Inventory Product Bundles (revised)
claude Jun 6, 2026
eb81f73
feat(hr): Phase 127 — HR Job Offer Letters
claude Jun 6, 2026
112d54e
feat(finance): Phase 128 — Finance Budget Management
claude Jun 6, 2026
5780308
feat(hr): Phase 129 — HR Training Sessions Calendar
claude Jun 6, 2026
444701a
feat(inventory): Phase 130 — Inventory Reorder Rules
claude Jun 6, 2026
1e6d2ea
feat(finance): Phase 131 — Finance Cash Flow Forecasting
claude Jun 6, 2026
376124a
Merge branch 'claude/erp-phase-1-foundations-9miE5' of http://127.0.0…
claude Jun 6, 2026
322017b
feat(hr): Phase 132 — HR Competency Frameworks
claude Jun 6, 2026
dd658a5
feat(inventory): Phase 133 — Inventory Supplier Scorecards
claude Jun 6, 2026
f67ff91
fix(finance): add missing migration and routes for Phase 131 Cash Flo…
claude Jun 6, 2026
730ee97
feat(finance): Phase 134 — Finance Recurring Expenses
claude Jun 6, 2026
939cc29
feat(hr): Phase 135 — HR Employee Goals & KPIs
claude Jun 6, 2026
2d3f857
feat(inventory): Phase 136 — Inventory Quality Alerts
claude Jun 6, 2026
d257d1e
feat(finance): Phase 137 — Finance Vendor Payments
claude Jun 6, 2026
8ee8604
feat(hr): Phase 138 — HR Succession Planning
claude Jun 6, 2026
6154a74
feat(hr): Phase 138 — HR Succession Planning
claude Jun 6, 2026
1e5311a
feat(inventory): Phase 139 — Inventory Stock Reservations
claude Jun 7, 2026
fc6ed3f
feat(finance): Phase 140 — Finance Payment Schedules
claude Jun 7, 2026
8bb7231
feat(hr): Phase 141 — HR Employee Mentorship Programs
claude Jun 7, 2026
48c9905
fix(hr): add start_date to makeMentorEmployee helper in Phase 141 tests
claude Jun 7, 2026
d7f9166
feat(inventory): Phase 142 — Inventory Purchase Requests
claude Jun 7, 2026
eef2a00
feat(finance): Phase 143 — Finance Customer Credits
claude Jun 7, 2026
af398e2
feat(hr): Phase 144 — HR Interview Scheduling
claude Jun 7, 2026
3b6bd4e
feat(inventory): Phase 145 — Inventory Goods Receipts
claude Jun 7, 2026
375323f
feat(inventory): Phase 145 — complete controller authorization and Re…
claude Jun 7, 2026
a20b873
feat(finance): Phase 146 — Finance Expense Budgets
claude Jun 7, 2026
fa4b151
feat(inventory): Phase 147 — Inventory Shipment Tracking
claude Jun 7, 2026
7ad792d
feat(finance): Phase 148 — Finance Profit Centers
claude Jun 7, 2026
9b5812f
feat(hr): Phase 149 — HR Employee Emergency Contacts
claude Jun 7, 2026
2ea54bb
feat(inventory): Phase 150 — Inventory RMA Requests
claude Jun 7, 2026
8826eb8
feat: UI quality pass — categories tree, module dashboards, sidebar n…
claude Jun 7, 2026
37be050
WIP: Phases 151-155 — Warranty, Put-Away Rules, StockPickings, Replen…
claude Jun 7, 2026
e9af40d
Phases 151-155 complete + Phase 157 WIP: Odoo inventory features + Mu…
claude Jun 7, 2026
536533b
Phases 156-160: Multi-Currency, Multi-Company, HR Reports
claude Jun 8, 2026
5d3cdb5
Phase 159: Inventory Reports + Multi-Warehouse
claude Jun 8, 2026
a2990c3
Phases 161-165: Manufacturing/MRP Module
claude Jun 8, 2026
0b89e86
Phases 166-170 (partial): CRM Module — backend complete
claude Jun 8, 2026
dab22c7
Phases 166-170: CRM Module — React pages + tests (21 passing)
claude Jun 8, 2026
f4c5cd9
Phases 171-175: Project Management Module — 21 tests passing
claude Jun 8, 2026
bdfd1e4
Phases 176-180: Point of Sale Module + Finance table rename fix — 165…
claude Jun 8, 2026
2adc2bb
Phases 181-185: Helpdesk Module — 19 tests passing
claude Jun 8, 2026
9cb73e1
Phases 186-190: Accounting Module — 21 tests passing
claude Jun 8, 2026
bcca3d0
Phases 191-195: Fleet Management Module — 16 tests passing
claude Jun 8, 2026
892d1b5
Phases 196-200: Email Marketing Module — 23 tests passing
claude Jun 8, 2026
59f2b67
Phases 201-205: Field Service Module — 18 tests passing
claude Jun 8, 2026
77fc2d5
Phases 206-210: REST API Layer (v1) — 34 tests, 1806 total passing
claude Jun 8, 2026
ad59139
Phases 211-215: Executive Dashboard + Bulk Import — 19 tests passing
claude Jun 8, 2026
904180c
Phases 216-220: PDF Export — 6 tests passing
claude Jun 8, 2026
91fc1eb
Phases 221-225: Approval Workflows Module — 20 tests passing
claude Jun 8, 2026
0ea9c6f
Phases 226-230: E-commerce Module — 25 tests passing
claude Jun 8, 2026
1c59aa2
Phases 231-233: Global Search — 10 tests passing
claude Jun 8, 2026
8bb20db
Phases 234-240: 2FA + Webhooks + Audit Log UI — 29 tests passing
claude Jun 8, 2026
dcb20bc
Phase 241-243: Kanban + Calendar views — 10 tests passing
claude Jun 8, 2026
ef57a9d
Phase 244: Discuss / Team Chat module — 13 tests passing
claude Jun 8, 2026
00878a4
Phase 244 addendum: Add Discuss/Show.tsx chat page
claude Jun 8, 2026
a13a767
feat: Salary Structure Engine for HR payroll — 10 tests passing
claude Jun 9, 2026
391685f
feat: add Subcontracting and Rental modules (backend, WIP)
claude Jun 9, 2026
552bc89
feat: Subscriptions module — recurring billing with MRR/churn — 10 te…
claude Jun 9, 2026
73223f7
feat: Subcontracting/Rental React pages + Survey module + 10 Subcontr…
claude Jun 9, 2026
067e8a6
feat: Rental tests + Survey React pages — 20 tests passing
claude Jun 9, 2026
36fa095
feat: Events + Documents DMS modules — 20 tests passing
claude Jun 16, 2026
1b36957
feat: Knowledge Base + Planning/Shifts modules — 20 tests passing
claude Jun 16, 2026
b60b8f6
feat: Sign / E-Signature module — 10 tests passing
claude Jun 16, 2026
29ab535
feat: Manufacturing Scheduling Engine + E-commerce Storefront — 35 te…
claude Jun 16, 2026
b658a15
feat: E-commerce storefront additional tests + checkout coupon UI
claude Jun 16, 2026
adcc754
feat: POS Terminal, Bank Reconciliation, Helpdesk SLA, CRM Email Sequ…
claude Jun 17, 2026
b51085a
Merge branch 'react:main' into claude/erp-phase-1-foundations-9miE5
sufianbd Jun 17, 2026
f7f2eb9
feat: Phase 3 Frontend Polish — TipTap editor, DomPDF payslips, drag-…
claude Jun 17, 2026
4ef79ad
feat: Phase 4 Enterprise — Multi-currency, Background Jobs, OpenAPI D…
claude Jun 17, 2026
ff6fc83
feat(phase-5): Quality Control, Equipment Maintenance, Sprint/Gantt, …
claude Jun 17, 2026
8b1196d
chore: add missing QualityControl feature test directory
claude Jun 17, 2026
dbb4faa
feat(phase-6): add Repairs, Live Chat, Social Marketing, and Frontdes…
claude Jun 17, 2026
3e7af4e
feat(phase-7): add Lunch, Appointments, Website/CMS, and Purchase mod…
claude Jun 18, 2026
1c108cc
fix: register QualityControl module in CoreServiceProvider
claude Jun 18, 2026
0868a14
chore: add missing Purchase module migration files
claude Jun 18, 2026
3fd4f2a
feat: fill 18 missing frontend TSX pages identified in final audit
claude Jun 18, 2026
8f317da
feat(phase-8): add cross-module integration events and listeners
claude Jun 18, 2026
a4c1ef4
feat(phase-9): add Finance, Accounting, Purchase API controllers (par…
claude Jun 18, 2026
de0bd75
feat(phase-9): add API controllers for 16 modules (batch 1)
claude Jun 18, 2026
c0f7810
feat(phase-9): add API controllers for Discuss, Documents, Events, Fr…
claude Jun 18, 2026
0743797
feat(phase-9): add Approvals, Subcontracting API controllers and API …
claude Jun 18, 2026
d44a0fe
feat(phase-9): add API test files for all remaining modules
claude Jun 18, 2026
cdf44e8
feat(phase-9): complete REST API layer — routes, controller fixes, an…
claude Jun 18, 2026
5b6fb89
fix(phase-8): guard stock movement creation when warehouse_id is null…
claude Jun 18, 2026
f9ac16b
feat(phase-10): demo data seeders for all 35 ERP modules
claude Jun 19, 2026
3dedafc
feat(phase-11): real-time WebSockets via Laravel Reverb + Echo
claude Jun 19, 2026
1c21ab6
feat(phase-11): wire channels route and add Reverb server config
claude Jun 19, 2026
864d8d3
feat(phase-12/13/14): jobs, mail notifications, and PDF views (in-pro…
claude Jun 19, 2026
d408e8e
feat(phase-12/13/16): tests, exports, dashboard enhancements (in-prog…
claude Jun 19, 2026
4f8e939
feat(phase-14/15/16): PDF controller, import/export, dashboard tests
claude Jun 19, 2026
aa42259
feat(phase-12-17): complete queue/mail/pdf/import-export/dashboard/is…
claude Jun 19, 2026
f04b953
chore: add maatwebsite/excel to composer dependencies
claude Jun 19, 2026
28ee11d
chore: ignore root-level vendor/ directory
claude Jun 19, 2026
f3648b0
feat(phase-18): api rate limiting and security headers
claude Jun 19, 2026
cb360a0
feat(phase-19): global search api and frontend component
claude Jun 19, 2026
f1c56cd
feat(phase-19/20): global search controller, search route, audit log …
claude Jun 19, 2026
3803562
feat(phase-20/23): audit log models, notification controller, traits …
claude Jun 19, 2026
c3a09a0
feat(phase-23): in-app notifications system
claude Jun 19, 2026
560c544
feat(phase-21/22): github actions ci/cd, reports api, claude.md
claude Jun 19, 2026
a880eae
fix(phase-19/22): fix search closure capture bug and report column names
claude Jun 19, 2026
8ffed30
fix(phase-20): fix audit_log migration to add columns not recreate table
claude Jun 19, 2026
0c57346
feat(phase-24/25): scheduled report delivery and health check endpoints
claude Jun 19, 2026
4c9a002
feat(phase-26/27): custom dashboard widgets and email template manage…
claude Jun 19, 2026
321ecf4
feat(phase-28/29): tenant feature flags and user preferences
claude Jun 19, 2026
9fde9fa
feat(phase-30): activity feed api with stats and filtering
claude Jun 19, 2026
0b216f7
feat(phase-31): unified calendar api aggregating multi-module events
claude Jun 19, 2026
2bf70bb
feat(phase-32): financial forecasting api with revenue and cash-flow …
claude Jun 19, 2026
f732929
feat(phase-33): smart alert rules with threshold monitoring and notif…
claude Jun 19, 2026
497f072
feat(phase-34): budget management rest api with variance analysis
claude Jun 19, 2026
fa8a575
docs: update CLAUDE.md with phases 24-34
claude Jun 19, 2026
f844202
feat(phase-35): customer credit limits with per-contact enforcement
claude Jun 19, 2026
6d30db1
feat(phase-36): product variants REST API with attribute matrix
claude Jun 19, 2026
90e4bf1
feat(phase-37): webhook management REST API with delivery log and HMAC
claude Jun 19, 2026
7314404
feat(phase-38): API token management with scoped abilities and expiry
claude Jun 19, 2026
afb4359
feat(phase-39): inventory reorder suggestions API with urgency levels
claude Jun 19, 2026
83c00c7
feat(phase-40): HR leave balance API with team view and allocation
claude Jun 19, 2026
a18776b
feat(phase-41): CRM pipeline analytics with funnel, win rate, and vel…
claude Jun 19, 2026
fc279bd
feat(phase-42): project time tracking API with billable hours summary
claude Jun 19, 2026
e932894
feat(phase-43): expense claim workflow API with full approval lifecycle
claude Jun 19, 2026
bbf1025
Phase 44: Vendor Performance Scoring API
claude Jun 19, 2026
36c9566
Phases 45-47: Custom Fields, Bulk Operations, Tenant Settings APIs
claude Jun 19, 2026
a925307
Phases 48-49: Employee Self-Service & Contract Management APIs
claude Jun 20, 2026
d02d3ac
Phase 50: Inventory Valuation API
claude Jun 20, 2026
073c8c0
Phase 51: Payment Terms & Schedules REST API
claude Jun 20, 2026
13aa9e4
Fix duplicate makeContract function name in ContractApiTest
claude Jun 20, 2026
1fc4b82
Phase 52: SLA Tracking API
claude Jun 20, 2026
3aaae18
Phase 53: Multi-Warehouse Stock API
claude Jun 20, 2026
7328d7e
Phase 54: Sales Commission Tracking API
claude Jun 20, 2026
16cc2c2
Phase 55: Price List Management API
claude Jun 20, 2026
5d6f2dc
Phase 56: Customer Loyalty Points API
claude Jun 20, 2026
8737515
Phase 57: Recurring Invoice Scheduling API
claude Jun 20, 2026
610d9f1
Phase 58: Product Bundling API
claude Jun 20, 2026
cd11c49
Phase 59: Tax Configuration API
claude Jun 20, 2026
36953e6
Phase 60: Credit Notes API
claude Jun 20, 2026
730ba2c
Phase 61: Purchase Requisition API
claude Jun 20, 2026
14dc569
Phase 62: Fixed Asset & Depreciation API
claude Jun 20, 2026
fb037b0
Phase 63: Sales Order Management API
claude Jun 20, 2026
d0640f1
Phase 64: Quotation/Proposal API
claude Jun 20, 2026
1a1f034
Phase 65: Batch Payment Processing API
claude Jun 20, 2026
ab46963
Phase 66: Debit Notes API
claude Jun 20, 2026
bf43457
Fix: rename test helper functions to avoid global collision
claude Jun 20, 2026
d06d69b
Phase 67: Quality Control API
claude Jun 20, 2026
a316fad
Phase 68: Survey Management API — full lifecycle, questions, analytics
claude Jun 20, 2026
c1831c0
Phase 69: Timesheet REST API — CRUD, entries, submit/approve/reject w…
claude Jun 20, 2026
d9ba844
Phase 70: Shift Scheduling & Overtime REST API — templates, assignmen…
claude Jun 20, 2026
22e025d
Phase 71: Succession Planning & Mentorship REST API — plans, candidat…
claude Jun 20, 2026
d950fda
Phase 72: Employee Lifecycle REST API — onboarding checklists, positi…
claude Jun 20, 2026
1a3104d
Phase 73: Employee Loans & Benefits REST API — loans, repayments, ben…
claude Jun 20, 2026
50603d2
Phase 74: Manufacturing BOM & Work Orders REST API — BOM CRUD, lines,…
claude Jun 20, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
110 changes: 110 additions & 0 deletions .github/workflows/erp-ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,110 @@
name: ERP CI

on:
push:
branches: [main, claude/erp-phase-1-foundations-9miE5]
paths:
- 'erp/**'
pull_request:
branches: [main]
paths:
- 'erp/**'

jobs:
php-tests:
name: PHP Tests (Laravel/Pest)
runs-on: ubuntu-latest
defaults:
run:
working-directory: erp

steps:
- uses: actions/checkout@v4

- name: Setup PHP
uses: shivammathur/setup-php@v2
with:
php-version: '8.3'
extensions: mbstring, pdo, pdo_sqlite, sqlite3, xml, curl, zip
coverage: none

- name: Cache Composer dependencies
uses: actions/cache@v4
with:
path: erp/vendor
key: ${{ runner.os }}-composer-${{ hashFiles('erp/composer.lock') }}
restore-keys: ${{ runner.os }}-composer-

- name: Install PHP dependencies
run: composer install --no-interaction --prefer-dist --optimize-autoloader

- name: Copy .env
run: cp .env.example .env

- name: Generate app key
run: php artisan key:generate

- name: Run migrations
run: php artisan migrate --force
env:
DB_CONNECTION: sqlite
DB_DATABASE: ':memory:'

- name: Run Pest tests
run: php artisan test --stop-on-failure
env:
DB_CONNECTION: sqlite
DB_DATABASE: ':memory:'
APP_ENV: testing
CACHE_STORE: array
QUEUE_CONNECTION: sync
SESSION_DRIVER: array
MAIL_MAILER: log
BROADCAST_CONNECTION: log

typescript-check:
name: TypeScript Check
runs-on: ubuntu-latest
defaults:
run:
working-directory: erp

steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: erp/package-lock.json

- name: Install Node dependencies
run: npm ci

- name: TypeScript type check
run: npx tsc --noEmit

lint:
name: Frontend Lint
runs-on: ubuntu-latest
defaults:
run:
working-directory: erp

steps:
- uses: actions/checkout@v4

- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20'
cache: 'npm'
cache-dependency-path: erp/package-lock.json

- name: Install Node dependencies
run: npm ci

- name: Run ESLint
run: npx eslint resources/js --ext .ts,.tsx --max-warnings 0
continue-on-error: true
6 changes: 6 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,3 +12,9 @@ yarn-debug.log*
yarn-error.log*
/.changelog
.npm/
.claude/
.env.bak
*.env.bak

# Stray PHP vendor dir
vendor/
198 changes: 198 additions & 0 deletions CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,198 @@
# ERP System — Claude Code Guide

## Project Overview

Full-featured multi-tenant ERP built with **Laravel 13 + Inertia.js v2 + React 19 + TypeScript + Tailwind CSS v3**.

The ERP application lives entirely under `erp/`. The repo root contains a legacy React Create App project — ignore it for ERP work.

## Quick Start

```bash
cd erp
composer install
npm install
cp .env.example .env
php artisan key:generate
php artisan migrate --seed
npm run dev
# In another terminal:
php artisan serve
```

## Architecture

### Stack

- **Backend**: Laravel 13, PHP 8.3, SQLite (dev/test), MySQL (prod)
- **Frontend**: Inertia.js v2, React 19, TypeScript, Tailwind CSS v3
- **Auth**: Laravel Sanctum (API tokens) + Spatie Roles/Permissions
- **Queue**: Database queue (`QUEUE_CONNECTION=database`)
- **WebSockets**: Laravel Reverb + Laravel Echo
- **PDF**: barryvdh/laravel-dompdf
- **Excel**: maatwebsite/excel v3.1
- **Testing**: Pest v3

### Module Structure (35 modules)

All modules live under `app/Modules/{Name}/`:

```
app/Modules/
├── Core/ # Tenant model, BelongsToTenant trait
├── Finance/ # Invoices, Bills, Contacts, Chart of Accounts
├── Inventory/ # Products, Warehouses, Stock Movements, Transfers
├── HR/ # Employees, Leave, Payroll
├── CRM/ # Leads, Opportunities, Activities
├── PM/ # Projects, Tasks, Milestones
├── Purchase/ # Purchase Orders, RFQs, Vendors
├── Accounting/ # Journal Entries, General Ledger
├── Manufacturing/ # BOMs, Work Orders, Quality
├── Maintenance/ # Assets, Work Orders
├── Subscriptions/ # Plans, Subscriptions
├── LiveChat/ # Channels, Sessions, Messages
├── Discuss/ # Channels, Messages
├── HelpDesk/ # Tickets, SLAs
├── KnowledgeBase/ # Articles
├── Survey/ # Surveys, Questions, Responses
├── Timesheets/ # Entries
├── Expenses/ # Claims
├── Fleet/ # Vehicles, Trips
├── Recruitment/ # Job Postings, Applications
├── Training/ # Programs, Enrollments
├── Events/ # Events, Registrations
├── Subcontracting/ # Contracts
├── FieldService/ # Work Orders
├── Rental/ # Items, Bookings
├── POS/ # Sessions, Orders
└── ...
```

### Multi-Tenancy Pattern

Every module model uses the `BelongsToTenant` trait (`app/Traits/BelongsToTenant.php`):

- Global scope auto-filters by `tenant_id`
- Observer auto-sets `tenant_id` on create
- Always call `app()->instance('tenant', $tenant)` in tests to set the active tenant

### API Structure

All REST endpoints at `/api/v1/*`. Base controller: `app/Http/Controllers/Api/V1/ApiController.php`.

- `success($data)` — 200 with `{data: ...}`
- `error($msg, $code)` — error response
- `paginated($paginator)` — paginated response

Auth: Bearer token via `withToken($token)` in tests.

### Tenant Detection in Controllers

```php
$tenantId = app()->has('tenant') ? app('tenant')->id : $request->user()->tenant_id;
```

### Broadcasting (WebSockets)

Events in `app/Events/` implement `ShouldBroadcast`. Channels in `routes/channels.php`.

- Live Chat: `private-chat-session.{id}` → `.NewChatMessage`
- Discuss: `private-discuss-channel.{id}` → `.NewDiscussMessage`
- Notifications: `private-tenant.{id}` → `.ErpNotification`

Frontend hook: `useEchoPrivateChannel(channelName, event, handler)` in `resources/js/Hooks/useEchoChannel.ts`.

### Key Conventions

- Migrations always start with `Schema::dropIfExists('table')` before `Schema::create`
- Event auto-discovery: Laravel 13 discovers listeners automatically — no manual EventServiceProvider needed
- Use `broadcast(new Event())->toOthers()` to exclude the sender from WebSocket events
- Rate limiting: 60 req/min on `/api/v1/*`, 10 req/min on auth endpoints
- Audit logging: `LogsActivity` trait auto-logs created/updated/deleted on key models
- Security headers: `SecurityHeaders` middleware appended globally

## Testing

```bash
cd erp
php artisan test # Run all tests
php artisan test --filter "FinanceTest" # Filter by name
php artisan test tests/Feature/Finance/ # Run a directory
```

All tests use SQLite in-memory (`DB_CONNECTION=sqlite DB_DATABASE=:memory:`). `tests/Pest.php` applies `RefreshDatabase` globally.

Test pattern:

```php
beforeEach(function () {
$this->seed(RolePermissionSeeder::class);
$this->tenant = Tenant::create(['name' => 'Test Co', 'slug' => 'test-co']);
$this->user = User::factory()->create(['tenant_id' => $this->tenant->id]);
$this->user->assignRole('super-admin');
$this->token = $this->user->createToken('test')->plainTextToken;
app()->instance('tenant', $this->tenant);
});
```

## Development Phases Completed

| Phase | Description | Status |
| ----- | ----------------------------------------------------------------- | ------ |
| 1–8 | Core modules, models, migrations, seeders, Inertia pages | ✅ |
| 9 | REST API — 200+ endpoints across 40 modules | ✅ |
| 10 | Demo data seeders for all 35 modules | ✅ |
| 11 | WebSockets — Laravel Reverb + Echo | ✅ |
| 12 | Queue jobs — invoice, low stock, payroll, bulk import | ✅ |
| 13 | Mail notifications — invoice, low stock, payroll, approval | ✅ |
| 14 | PDF generation — invoices, purchase orders, payslips | ✅ |
| 15 | Import/Export — CSV/XLSX for products, contacts, invoices | ✅ |
| 16 | Dashboard analytics — module stats + activity feed | ✅ |
| 17 | Tenant isolation tests — 22 cross-tenant security tests | ✅ |
| 18 | API rate limiting (60/min) + security headers | ✅ |
| 19 | Global search — 7 modules, frontend component | ✅ |
| 20 | Audit log — migration, trait, observer, API endpoint | ✅ |
| 21 | GitHub Actions CI/CD — PHP tests + TS check + ESLint | ✅ |
| 22 | Reports API — financial/inventory/HR + CLAUDE.md | ✅ |
| 23 | In-app notifications — DB model, API, frontend bell | ✅ |
| 24 | Scheduled Report Delivery — ReportSchedule model + job + mail | ✅ |
| 25 | Health Checks & Metrics — /api/v1/health + /api/v1/metrics | ✅ |
| 26 | Dashboard Widgets — per-user customizable widget layout | ✅ |
| 27 | Email Template Management — CRUD + variable preview | ✅ |
| 28 | Tenant Feature Flags — per-tenant feature toggle system | ✅ |
| 29 | User Preferences — timezone, locale, UI density, etc. | ✅ |
| 30 | Activity Feed API — filterable event stream from audit logs | ✅ |
| 31 | Unified Calendar API — tasks, leaves, events, invoices | ✅ |
| 32 | Financial Forecasting — revenue + cash-flow projections | ✅ |
| 33 | Smart Alert Rules — threshold monitoring + notifications | ✅ |
| 34 | Budget Management REST API — CRUD + activate + variance | ✅ |
| 35 | Customer Credit Limits — per-contact limits, hold, check API | ✅ |
| 36 | Product Variants REST API — attributes, variants, matrix view | ✅ |
| 37 | Webhook Management REST API — CRUD, delivery log, ping, HMAC | ✅ |
| 38 | API Token Management — named tokens with abilities and expiry | ✅ |
| 39 | Inventory Reorder Suggestions — deficit calc + urgency levels | ✅ |
| 40 | HR Leave Balance API — allocation, team view, year filters | ✅ |
| 41 | CRM Pipeline Analytics — funnel, win rate, velocity, leaderboard | ✅ |
| 42 | Project Time Tracking API — log hours, project summaries by user | ✅ |
| 43 | Expense Claim Workflow API — submit, approve, reject, paid states | ✅ |

## File Locations Reference

| Concern | Path |
| --------------------- | --------------------------------------- |
| Module models | `app/Modules/{Name}/Models/` |
| API controllers | `app/Http/Controllers/Api/V1/` |
| Inertia pages | `resources/js/Pages/` |
| Shared components | `resources/js/Components/` |
| Layouts | `resources/js/Layouts/AppLayout.tsx` |
| Routes (web) | `routes/web.php` |
| Routes (api) | `routes/api.php` |
| Broadcasting channels | `routes/channels.php` |
| Migrations | `database/migrations/` |
| Seeders | `database/seeders/` |
| Jobs | `app/Jobs/` |
| Mail | `app/Mail/` + `resources/views/emails/` |
| Events | `app/Events/` |
| Traits | `app/Traits/` |
| Services | `app/Services/` |
| Tests | `tests/Feature/` |
6 changes: 6 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"require": {
"barryvdh/laravel-dompdf": "^3.1",
"maatwebsite/excel": "^3.1"
}
}
Loading