Skip to content

remove order refunds and rebase donation/payout on grant-excluded accounting - #65

Merged
minodevss merged 3 commits into
mainfrom
feature/remove-order-refunds
Jul 13, 2026
Merged

minodevss merged 3 commits into
mainfrom
feature/remove-order-refunds

Conversation

@minodevss

Copy link
Copy Markdown
Contributor

Summary

Removes the order-refund concept entirely — a paid order is now terminal (no reversal path; admin adjustment remains the only manual escape hatch). Drops the refunds table, order_status='refunded', transaction_type='refund', the refund columns/indexes, POST /v1/refunds, and all refund UI across the four clients. Rebases donation/payout on base-grant-excluded accounting: per user 기부 = max(0, spent − grant), 환급 = min(charge, balance), so 실충전 = 기부 + 환급. Migration 0013_drop_refunds.sql hand-corrected for the enum swap (status DEFAULT drop/restore + type-predicate partial index recreate).

Verification

  • pnpm lint — passed
  • pnpm build (7 packages) — passed
  • pnpm --filter api test — passed (105 tests, incl. new grant-excluded donation/payout coverage)
  • pnpm --filter {pos,admin,app,kiosk} test — passed (6/6/7/1)
  • drizzle-kit migrate applied to dev DB; schema verified (enums trimmed, refunds dropped, columns removed, partial indexes recreated)

@minodevss
minodevss merged commit 1e80b0b into main Jul 13, 2026
1 check passed
@minodevss
minodevss deleted the feature/remove-order-refunds branch July 13, 2026 23:45
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