Skip to content

feat(split-meow): 每筆支出保存幣別與匯率快照,KRW 顯示對應 TWD#443

Closed
s123104 wants to merge 2 commits into
chore/ratewise-production-governance-v2from
converge/split-meow
Closed

feat(split-meow): 每筆支出保存幣別與匯率快照,KRW 顯示對應 TWD#443
s123104 wants to merge 2 commits into
chore/ratewise-production-governance-v2from
converge/split-meow

Conversation

@s123104

@s123104 s123104 commented Jun 26, 2026

Copy link
Copy Markdown
Contributor

摘要

收編 split-meow 每筆支出幣別快照功能至 baseline,向後相容。

變更

  • ExpenseRecord 加 optional currency + exchangeRateKrwPerTwd,記帳當下寫入快照
  • formatKrwAsTwd 嚴格 guard;歷史頁 KRW 列顯示 ≈ NT$
  • 舊資料無快照欄位仍正常渲染

測試

  • typecheck ✓ · vitest 48 tests ✓

注意

  • Base 為 governance-v2(stacked PR)
  • 已知小限制:混幣行程 trip 級總額用最後一筆幣別標籤(與 baseline 同等)
  • changeset: @app/split-meow minor

🤖 Generated with Claude Code

haotool and others added 2 commits June 26, 2026 13:54
- ExpenseRecord 新增 currency 與 exchangeRateKrwPerTwd 快照欄位
- HistoryTab 依快照顯示幣別,KRW 支出附 TWD 換算副標
- 新增 formatKrwAsTwd 與對應單元測試

測試:split-meow typecheck 與 currencies、useStore vitest 全通過

Co-authored-by: Cursor <cursoragent@cursor.com>
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Deprecation Warning: The deny-licenses option is deprecated for possible removal in the next major release. For more information, see issue 997.

Dependency Review

✅ No vulnerabilities or license issues or OpenSSF Scorecard issues found.

Scanned Files

None

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fd146e2cc4

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

<div className="shrink-0">
<p className="font-bold text-on-surface whitespace-nowrap text-base sm:text-lg">
{formatAmount(exp.totalAmount, currency)}
{formatAmount(exp.totalAmount, expenseCurrency(exp))}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Keep edit inputs on the expense snapshot currency

當使用者先以 KRW 記一筆、之後在設定切到 TWD 再編輯該筆時,列表現在會依 expenseCurrency(exp) 仍顯示 ₩,但下方 EditExpenseSheet 仍讀取目前全域 currency 來顯示輸入符號,而且 updateExpense 只更新金額欄位不更新幣別快照;使用者會在 NT$ 標示下輸入金額,儲存後卻被當成 KRW 顯示與結算。請讓編輯 sheet 使用該筆 expense 的 snapshot 幣別(或在編輯時同步更新 currency/exchangeRate)。

Useful? React with 👍 / 👎.

@s123104

s123104 commented Jun 26, 2026

Copy link
Copy Markdown
Contributor Author

關閉原因:被 #445「搶救每筆支出幣別與匯率快照」取代。#445 已將相同的 split-meow per-expense 幣別+匯率快照功能合併進 main 與 governance-v2;本 PR 基於舊 base,真實 delta 僅剩回退(移除 #445 版本的 JSDoc)。功能已上線,無需本 PR。

@s123104 s123104 closed this Jun 26, 2026
@s123104 s123104 deleted the converge/split-meow branch June 26, 2026 12:36
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