Files
acmcc/supabase
admin cc34ae9418 Accounting: two-way bill creation + mirror pending bills
- bill_should_mirror now includes 'pending', so approval bills appear in
  Payables immediately (still excludes draft/rejected/void/cancelled/denied).
- New reverse-creation path: a bill created natively in the Accounting module
  (external_source NULL, non-auto, non-payment, non-void) now creates a matching
  public.bills row. The accounting row is pre-linked to the new public id so the
  forward sync adopts it (no duplicate mirror); vendor is mapped back to
  public.vendors and the line's GL is carried to expense_account_id.
- Backfill: mirrored existing pending public bills and reverse-created the 8
  eligible native accounting bills. Verified: 0 unlinked native, 0 duplicate
  mirrors, pending bills mirrored.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
2026-06-04 20:54:09 -04:00
..