Phase 3: Bank reconciliation system
Added complete bank statement reconciliation workflow: Database Schema: - BankStatement: metadata for uploaded statements - BankStatementLine: individual transactions from statements - BankReconciliation: links system transactions to bank lines Features: - CSV import with flexible format detection (DD/MM/YYYY, YYYY-MM-DD dates) - Auto-matching algorithm: exact amount+date = 100% confidence, fuzzy matching up to 7 days - Manual matching UI for unmatched transactions - Discrepancy detection (amount mismatches) - Reconciliation dashboard with summary stats - Statement history view with status tracking Pages: - /admin/accounts/reconciliation: Dashboard and statement list - /admin/accounts/reconciliation?id=X: Statement detail with matching UI - /admin/accounts/reconciliation/upload: CSV upload form Server Actions: - uploadBankStatement: CSV parsing and auto-matching - manualMatch: User-initiated transaction linking - unmatchBankLine: Remove incorrect match - archiveStatement: Mark statement as complete - markReconciled: Finalize reconciliation Utils: - parseCSV: Flexible bank statement parser - autoMatchTransactions: Fuzzy matching algorithm - getReconciliationSummary: Stats calculation UI Components: - ReconciliationClient: Interactive matching interface with tabs - Manual match form: User-friendly transaction linking Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Haiku 4.5
parent
2d55203c1c
commit
7f88379d3b
@@ -7,6 +7,7 @@ import { logoutAdmin } from '@/app/admin/login/actions';
|
||||
const ADMIN_LINKS = [
|
||||
{ href: '/admin/orders', label: 'Orders' },
|
||||
{ href: '/admin/accounts', label: 'Accounts' },
|
||||
{ href: '/admin/accounts/reconciliation', label: 'Bank reconciliation' },
|
||||
{ href: '/admin/products/new', label: 'Add product' },
|
||||
{ href: '/admin/products', label: 'All products' },
|
||||
{ href: '/admin/categories/new', label: 'Add category' },
|
||||
|
||||
Reference in New Issue
Block a user