Skip to content

Claude/erp phase 1 foundations 9mi e5#17261

Open
sufianbd wants to merge 194 commits into
react:mainfrom
sufianbd:claude/erp-phase-1-foundations-9miE5
Open

Claude/erp phase 1 foundations 9mi e5#17261
sufianbd wants to merge 194 commits into
react:mainfrom
sufianbd:claude/erp-phase-1-foundations-9miE5

Conversation

@sufianbd

Copy link
Copy Markdown

No description provided.

claude added 13 commits May 24, 2026 12:19
Sets up a complete Laravel 11 + Inertia.js + React 19 + TypeScript ERP
scaffold inside the erp/ subdirectory:

Backend
- Laravel 11 with Inertia.js v2, Ziggy, Spatie Permission v7
- Modular layout: Core / Inventory / Finance service providers
- Migrations: tenants, users (tenant_id, avatar, last_login_at), audit_logs
- Tenant model with BelongsToTenant trait (global scope + auto-assign)
- TenantMiddleware resolving tenant via X-Tenant header / subdomain / domain
- AuditLog model + HasAuditLog trait (created/updated/deleted observer)
- RBAC: 4 roles (super-admin, admin, manager, staff), 14 permissions seeded
- HandleInertiaRequests shares auth user, roles, permissions, ziggy, flash
- DashboardController with breadcrumb props

Frontend
- React 19 + TypeScript strict, Vite 6, Tailwind CSS v3
- Typed PageProps: User (with roles/permissions/initials), Tenant, Breadcrumb
- Hooks: useAuth, usePermission, useSidebar (localStorage-persisted)
- Common components: Button, Input, Badge, Modal (portal), Table (sortable)
- Layout components: Sidebar (collapsible, icon+label), Topbar, Breadcrumbs,
  UserDropdown (role badge, logout)
- AppLayout: persistent shell with flash message display
- Dashboard/Index page with stats grid and module quick-access cards
- Error pages: 403, 404, 500

Tests (Pest v3) — 51/51 passing
- Auth: login, register, logout, password reset flow
- RBAC: role seeding, permission inheritance, super-admin scope
- AuditLog: created/updated/deleted events, actor capture, password hashing
- Tenant: model creation, settings cast, user relations, middleware behavior
- Dashboard: auth redirect, Inertia component, shared props, ziggy, roles

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Complete Inventory module implementation:

Backend:
- 8 Eloquent models: Category, UnitOfMeasure, Supplier, Warehouse, Product,
  StockLevel, StockMovement, PurchaseOrder, PurchaseOrderItem
- 9 database migrations for all inventory tables
- 6 controllers with full CRUD + PO state machine (draft→submitted→approved→received/cancelled)
- Form requests with validation, API resources, ProductPolicy (RBAC)
- InventoryServiceProvider wires migrations, routes, and policies
- Routes use `web` middleware group to enable implicit route model binding
- PurchaseOrder: status default 'draft', availableTransitions(), transition endpoint

Frontend (React 19 + TypeScript + Tailwind):
- 4 shared components: StockLevelBadge, PurchaseOrderStatusBadge, Pagination, ProductForm
- 13 Inertia pages: Products (CRUD+Show), Categories, Warehouses, Suppliers (CRUD),
  StockMovements, PurchaseOrders (Index/Create/Show with dynamic line items)
- Sidebar updated with all inventory nav links

Tests:
- 81 Pest tests, 250 assertions — all passing

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Complete Finance module implementation:

Backend:
- 7 Eloquent models: Account (chart of accounts with type hierarchy),
  JournalEntry + JournalLine (double-entry bookkeeping with balance
  validation), Contact (customer/vendor/both), Invoice + InvoiceItem
  (status machine: draft→sent→paid/cancelled), Payment
- 7 database migrations for all finance tables
- 5 controllers: Accounts, Contacts, JournalEntries, Invoices, Reports
- Form requests with validation, 4 API resources, 4 policies
- FinanceServiceProvider wires routes and policy registration
- Invoice auto-numbering (INV-YYYY-NNNNN) generated post-creation
- Payment recording auto-transitions invoice to paid when fully settled
- Trial Balance report aggregates posted journal lines by account

Frontend (React 19 + TypeScript + Tailwind):
- finance.ts type definitions (Account, JournalEntry, Contact, Invoice,
  Payment, TrialBalanceRow, etc.)
- 2 components: InvoiceStatusBadge, JournalEntryStatusBadge
- 13 Inertia pages: Accounts (Index/Create/Edit), Contacts (Index/Create/Edit),
  JournalEntries (Index/Create/Show with live balance check),
  Invoices (Index/Create/Show with inline payment form),
  Reports/TrialBalance
- Sidebar updated with Finance sub-navigation

Tests:
- 111 Pest tests, 341 assertions — all passing

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- HR module: 6 migrations, 6 models (Department, Employee, LeaveType,
  LeaveRequest, PayrollRun, PayrollItem), 4 controllers, 3 form requests,
  2 resources, 1 policy with optional model param for class-level auth
- LeaveRequest: approve/reject state machine with DomainException guards
- PayrollRun: process() state machine; total_gross/total_net computed attributes
- Admin UserController: create/update/destroy with role assignment via Spatie
- DashboardController: live metrics (9 stat fields, recentInvoices, recentPos)
- Frontend: HR pages (Employees CRUD, Departments, Leave, Payroll Index/Create/Show),
  Admin/Users pages (Index/Create/Edit), Dashboard wired to live stats
- Sidebar: HR and Admin nav groups with children
- Tests: 141 passing (453 assertions) — HR + Admin Pest feature suites added

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- Analytics controller: revenue by month (last 12), invoice by status,
  headcount by dept, payroll summary, inventory value — all permission-gated
- SVG line chart + horizontal/vertical bar chart components (no external deps)
- Analytics page with KPI cards, line chart for revenue, bar charts for HR/inventory
- Notifications: Laravel database notifications table, LeaveRequestActioned class,
  dispatched on leave approve/reject if employee has linked user
- NotificationController: index, markRead, markAllRead, destroy
- NotificationBell in Topbar: unread count badge, dropdown, mark-all-read
- Inertia shared data: notifications_count on every request (lazy eval)
- AuditLogController: tenant-scoped, filterable by event/model, paginated
- Audit Log page: expandable rows showing old vs new values diff
- TenantSetting model: key-value store with getValue/setValue helpers
- SettingController: company_name, currency, timezone, fiscal_year_start
- Settings page: admin/super-admin only, validated form
- Sidebar: Analytics link (all users) + Audit Log under Admin group
- Tests: 161 passing (559 assertions) — Analytics, AuditLog, Setting, Notification suites

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- Add SearchController (GET /search?q=) returning JSON results for
  invoices, contacts, products, purchase orders, and employees;
  permission-gated per module, debounced in the client
- Add CommandPalette component (Cmd/Ctrl+K) with keyboard navigation,
  type badges, and backdrop dismiss; wired into AppLayout
- Add ExportController with streaming CSV downloads for products,
  invoices, and employees; gated by viewAny policy
- Add export routes under /export/{products,invoices,employees}
- Add Export CSV buttons to Products, Invoices, and Employees index pages
- Add InvoiceController::print() rendering standalone Print page with
  company name and currency from TenantSetting
- Add printable invoice page (Finance/Invoices/Print) with print:hidden
  controls bar and window.print() button
- Add Print / PDF button to Invoice Show page
- Fix ExportController: selling_price → sale_price (Product field name)
- Add SearchTest (6 tests) and ExportTest (5 tests); all 172 tests pass

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- Extract HasLineItemTotals trait (subtotal/tax/total/amount_due/isOverdue)
- Extract HasStatusTransitions trait (canTransitionTo/transitionTo/availableTransitions)
- Refactor Invoice model to use both traits via getTransitions()
- Add bills, bill_items, bill_payments migrations (timestamps 000003-000005)

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- Add Vendor Bills module (AP): bills/bill_items/bill_payments tables,
  Bill/BillItem/BillPayment models, BillController, BillPolicy,
  BillResource, StoreBillRequest
- Extract HasLineItemTotals + HasStatusTransitions traits (shared by
  Invoice and Bill models)
- Add ReportController::profitAndLoss() and ::balanceSheet() with shared
  aggregateJournalLines() helper
- Add Bills/Index, Bills/Create, Bills/Show React pages
- Add Reports/ProfitLoss and Reports/BalanceSheet React pages
- Add BillStatusBadge component
- Add bill routes (resource + receive/cancel/recordPayment) and report routes
- Update Sidebar with Bills and new report links
- Add BillTest (12 tests) and ReportTest (5 tests); all tests passing
- npm run build passes with no TypeScript errors

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- BillController: reject payment recording on non-received bills
- BillTest: scope Bill::latest() to tenant, load payments in total test,
  add staff-cannot-create and draft-payment-rejected tests
- ReportTest: add staff-403 tests, fix date range on zero-net test,
  add total_liabilities assertion to balance sheet equation test
- Show.tsx: use replaceAll() for multi-underscore payment methods

All 192 tests passing; npm run build clean.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
…story

- Add agedReceivables, agedPayables, accountLedgerIndex, accountLedger
  methods to ReportController with bucket-based aging logic
- Register new finance report routes (aged-receivables, aged-payables,
  account-ledger index + per-account)
- Add PO receiveForm GET route and controller method rendering
  Inventory/PurchaseOrders/Receive Inertia page
- New React pages: AgedReceivables, AgedPayables, AccountLedger,
  PO Receive form
- Update Products/Show with stock movement history and adjustment form
- Update PurchaseOrders/Show with "Receive Items" button for approved POs
- Add Aged Receivables, Aged Payables, Account Ledger to sidebar
- 19 new tests across Finance ReportTest and Inventory
  PurchaseOrderReceiveTest; all 206 tests passing

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- Quote and QuoteItem models with HasLineItemTotals + HasStatusTransitions
- QuotePolicy registered in FinanceServiceProvider
- Migrations for quotes and quote_items tables
- Lifecycle: draft → sent → accepted/declined/cancelled

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Implements the full Quotes module including migrations, models, policy,
form request, resource, controller, routes, TypeScript types, React pages
(Index/Create/Show), QuoteStatusBadge component, Sidebar link, and 16
feature tests. All 222 tests pass.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
@meta-cla

meta-cla Bot commented May 31, 2026

Copy link
Copy Markdown

Hi @sufianbd!

Thank you for your pull request and welcome to our community.

Action Required

In order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you.

Process

In order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA.

Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with CLA signed. The tagging process may take up to 1 hour after signing. Please give it that time before contacting us about it.

If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks!

claude added 16 commits May 31, 2026 05:41
…, migrations)

- CreditNote + CreditNoteItem models with HasLineItemTotals + HasStatusTransitions
- CreditNotePolicy, StoreCreditNoteRequest, CreditNoteResource, CreditNoteController
- Migrations for credit_notes and credit_note_items tables
- Lifecycle: draft → issued → applied/cancelled; optional link to source invoice

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Wire up Credit Notes (routes, policy registration, frontend pages,
status badge, types, sidebar) and add the Customer Statement report
(ReportController methods, page, routes, sidebar). Adds 18 tests.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Add recurring-invoice templates that auto-generate Invoices on a
weekly/monthly/quarterly/yearly schedule. Includes models, policy,
request, resource, controller, console command + daily schedule,
Inertia pages, status badge, sidebar entry, and feature tests.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Adds a VAT Return report that summarises output tax (collected on sales
invoices) and input tax (paid on purchase bills) for a date range,
computing the net VAT payable/reclaimable figure.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Adds full user management for admin/super-admin users: view tenant users, invite new users with role assignment, change roles, toggle active/inactive status, and remove users. Includes migration for is_active column, UserManagementController, settings routes, React frontend page, Sidebar Settings > Users link, and 12 feature tests.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
claude added 30 commits June 7, 2026 18:11
Adds EmployeeEmergencyContact model with markAsPrimary() that enforces
a single primary contact per employee. Uses shallow nested routing under
employees so show/edit/update/destroy work without the parent parameter.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Adds RmaRequest and RmaRequestItem models with full lifecycle transitions:
approve → receive → inspect → close. RMA numbers auto-generated as
RMA-YYYY-NNNNN. Supports customer and supplier return types with
configurable disposition (restock/scrap/repair/replace/credit).

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
…av, AppLayout upgrades

- Rewrite Inventory/Categories/Index.tsx with tree view (parent + children rows),
  inline create form for top-level categories, inline edit per row, and "+ Sub"
  button to add sub-categories with parent_id pre-filled; removes broken links
  to non-existent /create and /edit routes
- Add InventoryDashboardController, FinanceDashboardController, HRDashboardController
  with KPI queries and recent-record lists; register GET dashboard routes in each
  module's route file
- Create Inventory/Dashboard.tsx, Finance/Dashboard.tsx, HR/Dashboard.tsx with
  KPI cards, data tables, and AppLayout
- Update Sidebar.tsx: add Dashboard as first child of Inventory, Finance, and HR
  sections; add Shipments and RMA Requests to Inventory; add Profit Centers and
  Expense Budgets to Finance
- Upgrade 8 stub pages (Shipments Index/Show/Create, RmaRequests Index/Show,
  ProfitCenters Index, ExpenseBudgets Index, EmergencyContacts Index) from bare
  HTML to AppLayout + Button + proper Tailwind slate/indigo design system

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
…ishment, Traceability (in progress)

Migrations, models, controllers, policies for:
- Phase 151: ProductWarranty + WarrantyClaim (Warranty Management)
- Phase 152: PutAwayRule
- Phase 153: StockPicking + StockPickingLine
- Phase 154: ReplenishmentOrder
- Phase 155: traceability columns on stock_movements

React pages in progress (Warranties Index/Create/Show, WarrantyClaims Index).
Remaining pages, tests, and sidebar updates still being built by background agents.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
…lti-Company

Phase 151 — Warranty Management:
- ProductWarranty, WarrantyClaim models + controllers + React pages (Index/Create/Show)
- WarrantyPolicy, migrations, routes

Phase 152 — Put-Away Rules:
- PutAwayRule model + controller + React pages (Index/Create/Edit/Show)
- PutAwayRulePolicy, migration, activate/deactivate actions

Phase 153 — Stock Pickings (Odoo stock.picking):
- StockPicking, StockPickingLine models + controller + React pages (Index/Create/Edit/Show)
- WH/IN/, WH/OUT/, WH/INT/, WH/RET/ picking number prefixes
- confirm/start/validate/cancel workflow

Phase 154 — Replenishment Orders:
- ReplenishmentOrder model + controller + React pages (Index/Create/Show)
- REP-YYYY-NNNNN numbering, buy/manufacture/resupply routes
- confirm/start/complete/cancel workflow

Phase 155 — Product Traceability:
- TraceabilityController (read-only lot/serial movement history)
- Traceability/Index.tsx with lot + serial dropdowns

Phase 157 WIP — Multi-Company:
- companies + company_user migrations
- Company model (hierarchy, fullName accessor)
- CompanyController, CompanyPolicy, Core routes

Sidebar updated: Stock Pickings, Replenishments, Traceability, Put-Away Rules,
Warranties, Warranty Claims added. Tests: 57 new tests.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Phase 156 — Multi-Currency:
- CurrencyController: added create() + edit() methods, rounding validation
- Currency routes: enabled create/edit (was excluded)

Phase 157 — Multi-Company (Multi-Business):
- companies table: tenant-scoped, parent_company_id hierarchy, fiscal_year_start,
  currency_code, tax_id, address/contact fields
- company_user pivot table for user-company membership
- Company model: fullName accessor, parent/subsidiaries/users relations
- CompanyController: full CRUD
- Core routes: /core/companies resource
- React pages: Companies/Index, Create, Edit, Show
- Sidebar: Companies added under System section

Phase 158 — Finance Reports:
- FinanceReportController: profitLoss, agedReceivables, agedPayables,
  invoiceSummary, expenseSummary

Phase 160 — HR Reports:
- HRReportController: headcount, leaveSummary, departmentSummary, employeeTenure
- HR routes: /hr/reports/* group
- React pages: HR/Reports/Headcount, LeaveSummary, DepartmentSummary, EmployeeTenure
- Sidebar: HR Reports links added

1587 tests passing

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- InventoryReportController: stock-valuation, stock-movement, low-stock, abc-analysis
- MultiWarehouseController: warehouse overview with stock summaries
- warehouses table: address, city, country, phone, email, timezone, costing_method
- React pages: Reports/StockValuation, StockMovement, LowStock, AbcAnalysis, MultiWarehouse/Index
- Sidebar: Inventory Reports + Multi-Warehouse links added
- 8 tests

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- Module: app/Modules/Manufacturing/ (new module)
- Phase 161: BillOfMaterials model + BomLine; BomController (CRUD + inline lines);
  React pages: BillsOfMaterials/Index, Create, Edit, Show
- Phase 162: WorkCenter model; WorkCenterController CRUD;
  React pages: WorkCenters/Index, Create, Edit
- Phase 163: ManufacturingOrder + MoComponent models; MO number = MO-YYYY-NNNNN;
  confirm/start/complete/cancel lifecycle; fromBom() auto-populates components;
  React pages: ManufacturingOrders/Index, Create, Show
- Phase 164: WorkOrder model; nested controller under MOs;
  start/finish/cancel transitions; React pages: WorkOrders shown in MO/Show
- Phase 165: ManufacturingDashboardController; ManufacturingReportController;
  React pages: Manufacturing/Dashboard, Reports/ProductionOutput, Reports/BomCost
- ManufacturingServiceProvider registered via CoreServiceProvider
- Sidebar: Manufacturing section added
- 21 tests, all passing

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Migrations, models (CrmStage/CrmLead/CrmActivity), controllers
(Dashboard/Stage/Lead/Activity/Report), routes, CRMServiceProvider,
and CoreServiceProvider registration. React pages pending.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Dashboard, Leads CRUD (Index/Create/Show/Edit), Pipeline Stages,
Reports (Pipeline/WinLoss/Source), Sidebar nav wiring, and 21
feature tests covering all CRUD + markWon/markLost/convert/activities.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
5 migrations (projects, project_members, tasks, milestones, time_entries),
4 models (Project/Task/Milestone/TimeEntry), ProjectPolicy, 5 controllers
(Project/Task/Milestone/TimeEntry/Dashboard), PMServiceProvider registered,
9 React pages (Dashboard, Projects CRUD, Tasks CRUD, TimeEntries),
Sidebar PM section. 21/21 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
…8 tests

POS: 4 migrations (pos_sessions, pos_orders, pos_order_items, pos_payments),
4 models (PosSession/Order/OrderItem/Payment with POS-YYYY-NNNNN / REC-YYYY-NNNNN
numbering), PosPolicy, 3 controllers (Session/Order/Dashboard), POSServiceProvider,
7 React pages (Dashboard, Sessions CRUD+ZReport, Orders Index+Receipt), 17 tests.

Fix: renamed Finance projects tables to finance_projects/finance_project_tasks/
finance_project_time_entries to avoid collision with PM module's projects table.

1658/1658 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
4 migrations (helpdesk_teams+pivot, helpdesk_tickets, helpdesk_messages,
helpdesk_sla_policies), 4 models (Team/Ticket/Message/SlaPolicy), HelpdeskPolicy,
3 controllers (Dashboard/Ticket/Team), HelpdeskServiceProvider, 5 React pages
(Dashboard, Tickets CRUD + Show with message thread, Teams), Sidebar section.
SLA deadline auto-set from policy, overdue detection, resolve/close/reopen/reply
actions, internal notes. 19/19 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
5 migrations (chart_of_accounts, accounting_periods, accounting_journal_entries,
journal_entry_lines, account_balances), 5 models (Account with 22-entry default COA
seeder, JournalEntry with post/reverse/isBalanced, AccountingPeriod/Line/Balance),
AccountingPolicy, 4 controllers (Account/JournalEntry/Period/Reports), 11 React pages
(Accounts CRUD, Journal Entries CRUD+Show, Periods, TrialBalance/BalanceSheet/
IncomeStatement/GeneralLedger), Sidebar Accounting section. 21/21 tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
4 migrations (fleet_vehicles, fleet_fuel_logs, fleet_maintenances,
fleet_vehicle_assignments — prefixed to avoid Inventory vehicles collision),
4 models (Vehicle/FuelLog/VehicleMaintenance/VehicleAssignment with expiry
detection and cost aggregation), FleetPolicy, 4 controllers (Dashboard/
Vehicle/FuelLog/Maintenance), 7 React pages, Sidebar Fleet section.
16/16 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
5 migrations (mailing_lists, subscribers, pivot, email_campaigns, campaign_sends),
4 models (MailingList/Subscriber/EmailCampaign/CampaignSend with send()/cancel()/
openRate()/clickRate()/markOpened()/markClicked()), MarketingPolicy, 4 controllers
(Dashboard/MailingList/Subscriber/Campaign with CSV import), 8 React pages
(Dashboard, MailingLists CRUD+Show, Subscribers, Campaigns CRUD+Show),
Sidebar Marketing section. 23/23 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
5 migrations (service_orders, service_order_items, service_checklists,
service_checklist_items, service_order_checklist_results), 5 models
(ServiceOrder with FS-YYYY-NNNNN numbering + start/complete/cancel workflow,
ServiceOrderItem, ServiceChecklist/Item, ChecklistResult), FieldServicePolicy,
3 controllers (Dashboard/Order/Checklist), 6 React pages (Dashboard, Orders
CRUD+Show with checklist, Checklists), Sidebar Field Service section.
18/18 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Sanctum token auth (login/logout/me), abstract ApiController base with
success/error/paginated helpers. 11 API controllers exposing: Products,
Invoices, Customers, Inventory (stock/movements/adjust), CRM leads,
Helpdesk tickets, HR (employees/departments/leave), Manufacturing orders+BOMs,
POS sessions+orders, cross-module Dashboard summary. All routes under
/api/v1/ with auth:sanctum middleware. 34/34 API tests, 1806 total passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
ExecutiveDashboardController: cross-module KPIs (financial, operations, people,
pipeline), 6-month revenue trend, recent activity feed. Executive.tsx with pure
CSS bar chart and activity feed. ImportController: CSV import for Products
(match-on-SKU), Employees (match-on-email), Contacts (supplier→vendor mapping),
with skip-bad-rows error handling and flash counts. Import/Index.tsx with 3
import cards and data URI sample downloads. Sidebar: Executive Dashboard link
at top, Import Data under Admin. 19/19 tests, 1825 total passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Install barryvdh/laravel-dompdf. SendsDocuments trait with renderDocumentPdf()
helper. Blade templates: pdf/invoice, pdf/bill, pdf/quote, pdf/receipt (80mm
thermal). pdf() methods on InvoiceController, BillController, QuoteController,
PosOrderController. Routes: GET finance/invoices/{id}/pdf, finance/bills/{id}/pdf,
finance/quotes/{id}/pdf, pos/orders/{id}/pdf. 6/6 PDF tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
4 migrations (approval_workflows, approval_steps, approval_requests,
approval_actions), 4 models (ApprovalWorkflow with findFor()/stepCount(),
ApprovalRequest with approve()/reject()/cancel()/canApprove()/createFor(),
ApprovalStep, ApprovalAction), ApprovalsPolicy, 3 controllers (Dashboard/
Workflow/Request with myPending), 8 React pages (Dashboard, Workflows CRUD+Show,
Requests Index+Show+MyPending), Sidebar Approvals section. Multi-step approval
flow with per-step user/role assignment. 20/20 tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
5 migrations (store_settings, store_categories, store_products bridge,
store_orders, store_order_items), 5 models (StoreSettings/Category/Product with
isOnSale()/discountPercent(), StoreOrder with SO-YYYY-NNNNN + confirm/markPaid/
ship/deliver/cancel, StoreOrderItem), EcommercePolicy, 6 controllers (Dashboard/
Settings/Category/Product/Order/Storefront), 13 React pages (admin CRUD + public
storefront at /store/{slug} with no auth), Sidebar E-commerce section.
25/25 feature tests passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
GlobalSearchController searches 8 modules (Products, Invoices, Contacts, CRM
Leads, Helpdesk Tickets, Employees, PM Projects, Store Orders) with LIKE queries,
5 results per type, tenant-scoped, min 2-char query. GlobalSearch.tsx component
with 300ms debounce, Cmd+K shortcut, arrow-key navigation, colored type badges.
Integrated into Topbar. CommandPalette Cmd+K conflict resolved. 10/10 tests,
1886 total passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
2FA: pragmarx/google2fa-laravel, TOTP setup/enable/disable/challenge/verify,
encrypted secrets + 8 recovery codes, RequiresTwoFactor middleware. Webhooks:
webhooks + webhook_deliveries tables, Webhook model with subscribesTo()/dispatch(),
WebhookService with HMAC-SHA256 signing, Http::fake delivery tests, deliveries
and test-ping views. Audit Log UI: enhanced index with user/date filters, new
show page with old/new value diff (changed keys only). Sidebar: 2FA Setup +
Webhooks links under Settings. 29/29 tests, 1915 total passing.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- PM Task Kanban: drag-drop board grouping tasks by status (todo/in_progress/review/done/cancelled)
- PM Task Calendar: month view with tasks plotted by due_date, today highlight
- CRM Pipeline Kanban: drag-drop board grouping opportunities by stage with revenue display
- PATCH move-status and move-stage endpoints for optimistic UI drag-drop updates
- Routes added before resource declarations to avoid route-model binding conflicts

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- DiscussChannel model: public/private channels, member management, unread counts, markReadFor()
- DiscussMessage model: threaded replies, edit (marks is_edited), pin/unpin, soft-delete
- DiscussController: index, show, store channel, send/edit/delete messages, join/leave
- React pages: Discuss/Index (channel list with unread badges) and Discuss/Show (chat UI with avatar initials, timeAgo, Enter-to-send)
- Migrations: discuss_channels, discuss_channel_members (pivot w/ last_read_at), discuss_messages

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Full-height channel view with scrollable message list, avatar initials (color-hashed),
timeAgo timestamps, edited/pinned indicators, reply count, Enter-to-send textarea.

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
- SalaryStructure model with rules-based compute() supporting fixed,
  percentage_of_basic, percentage_of_gross, percentage_of_rule types
- SalaryRule and PayslipLine models; Employee/Payslip/PayrollRun updated
- PayrollRun::generatePayslips() uses attached salary structure with flat fallback
- SalaryStructureController (CRUD + nested storeRule/destroyRule)
- Salary structure routes added to hr.php; kanban/move-stage added to crm.php
- React pages: HR/SalaryStructures/Index and Show
- 4 migrations: salary_structures, salary_rules, payslip_lines, employee FK

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Subcontracting:
- SubcontractOrder and SubcontractComponent models with BelongsToTenant
- Status transitions: draft → sent → in_progress → received/cancelled
- SubcontractController with CRUD + send/startProduction/receive/cancel/addComponent/removeComponent
- 2 migrations: subcontracts, subcontract_components

Rental:
- RentalItem and RentalAgreement models with BelongsToTenant
- Item statuses: available/rented/maintenance; Agreement: active/returned/overdue/cancelled
- RentalController with CRUD + rent/return/calendar/agreements actions
- 2 migrations: rental_items, rental_agreements

React pages and tests pending (agents still running)

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
…sts passing

- SubscriptionPlan model with billing_cycle (monthly/quarterly/annual),
  monthlyEquivalent(), cycleDays()
- Subscription model with cancel(), renew() (creates invoice, advances period),
  isActive(), daysUntilRenewal(), mrr()
- SubscriptionInvoice with markPaid() / markFailed()
- SubscriptionController: index (with MRR total), plans, store, cancel, renew,
  payInvoice, metrics (MRR + churn rate + active/trial counts)
- 3 migrations: subscription_plans, subscriptions, subscription_invoices
- React pages: Index (dashboard with MRR card, plans tab) and Show (invoices + actions)
- CoreServiceProvider: registered Rental + Subscriptions providers

https://claude.ai/code/session_01RdUGwo74JXChRCF88Yu27d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants