Skip to content

feat(B4): club collections, immutable receipts, dues and finance dashboard - #21

Open
baba-dev wants to merge 12 commits into
mainfrom
feat/b4-club-finance-dues-receipts
Open

baba-dev wants to merge 12 commits into
mainfrom
feat/b4-club-finance-dues-receipts

Conversation

@baba-dev

@baba-dev baba-dev commented Nov 11, 2026 •

Copy link
Copy Markdown
Owner

ClubKeep B4 — externally recorded club payments, dues and receipts

One coherent feature PR on top of merged B1–B3. This is operational fee recording, not ClubKeep SaaS subscription billing, payment gateway capture/settlement, external refunds or statutory invoicing.

Implemented

  • B4-A: Approved B4 contract in docs/B4_CLUB_FINANCE.md; clarified cancellation, partial payments, reversals and currency treatment.
  • B4-B: Additive PG17/Prisma 7 finance schema. Immutable receipt snapshots, per-club sequential receipt numbers, composite tenant FKs, append-only payment/reversal triggers, unique operation keys and constraints.
  • B4-C: Transactional recording/reversal services, shared Club and B1 roster locks, idempotent replays, term balance enforcement, currency-safe summaries, paginated dues and ledger, per-currency time trends.
  • B4-D: Verified-session, rate-limited, CSRF-protected payment and reversal APIs, read pagination and tenant-scoped access.
  • B4-E: Luxe owner/manager finance overview, dues pages, immutable payment ledger and role-aware desktop/mobile navigation.
  • B4-F: Staff payment recording from member profiles, term balances and receipts, owner/manager void action; no medical or Personal data queried.
  • B4-G: Private printer-friendly branded receipt with payment and membership snapshots, VOID state and an explicit externally recorded/not-tax-invoice notice.
  • B4-H: Native PG17 finance tests for cross-club FKs, amount checks, receipt/idempotency uniqueness, reversal constraints, append-only triggers, historical preservation and CI integration.

Reconciled the previously stale roadmap and updated the product document to reflect B3 all-vertical launch. The one-time B4 source formatter workflow was removed before final CI.

Final verification

Final reviewed head: 7e6c20b76420dd04829de44f76b728f9ed780f00
CI: https://github.com/baba-dev/ClubKeep/actions/runs/43111393687 — SUCCESS (all three jobs):

  • ✅ x64 lint, Prettier, TypeScript, unit/native service checks, Next.js build and standalone runtime.
  • ✅ PostgreSQL 17 fresh/legacy/no-op migrations, Prisma schema drift, B1/B2/B3/B4 tests and isolation.
  • ✅ ARM64 typecheck, Next.js standalone production build and startup smoke.

Production gates

Not yet merged or deployed. Because main has an automatic VPS release workflow, merge only after reviewing the migration/forward-only ledger and validating operator-approved staging acceptance, real club flows, mobile 360/390px, receipt printing, backup/restore and MenuMinute isolation. The UI does not claim bank-verified transactions. Free club usage quotas remain OPEN; no owner-unauthorized pricing or quota changes.

@baba-dev
baba-dev marked this pull request as ready for review November 11, 2026 22:27

This branch has not been deployed

No deployments
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.

1 participant