Repository navigation
fix(users): 用户列表额度列改回钱包口径 - #120
Conversation
suanova#110 把「剩余额度/总额度」列的口径从钱包额度换成了有效订阅 token 额度,且没有回退:UserQuotaCell 在订阅总额与已用均为 0 时渲染「无余额」, 而 FillUsersSubscriptionQuotaStats 只统计 status=active 且未过期的 user_subscriptions。钱包/组织计费、没有订阅数据的站点因此整列恒显示 「无余额」(例如 root 钱包 99962113/37887 也显示无余额)。 改回钱包口径:remaining = quota,total = quota + used_quota,total 为 0 时才显示「无余额」;订阅信息继续由同页「订阅余额」列展示。 - user-quota-cell: 恢复 used/remaining props,去掉 total/unlimited - users-columns / ops-users-table: 传 used_quota/quota, ops 列 accessorKey 由 subscription_remain_quota 改回 quota - 新增 quota-column 回归测试:无订阅用户按钱包渲染、有订阅时仍按钱包 口径、全 0 时才显示无余额 Co-Authored-By: Claude Code <[email protected]>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: suanova/cuberouter/.coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (4)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe quota cell now derives its total from wallet usage and remaining quota. Both user tables pass wallet values to the cell. Tests verify the users table’s quota display with and without a subscription, and when the wallet total is zero. ChangesWallet quota display
Priority: ⬇️ Low Estimated code review effort: 2 (Simple) | ~10 minutes Change: Bug fix Suggested reviewers: Merge Risk: ⚪ Minimal · up to The quota column displays wallet balances as intended. No identified issue blocks merging after normal checks. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
This pull request does not currently match the merge queue conditions, so it cannot be queued from here. The box comes back if it matches again. |
#110 把「剩余额度/总额度」列的口径从钱包额度换成了有效订阅 token
额度,且没有回退:UserQuotaCell 在订阅总额与已用均为 0 时渲染「无余额」,
而 FillUsersSubscriptionQuotaStats 只统计 status=active 且未过期的 user_subscriptions。钱包/组织计费、没有订阅数据的站点因此整列恒显示
「无余额」(例如 root 钱包 99962113/37887 也显示无余额)。
改回钱包口径:remaining = quota,total = quota + used_quota,total 为 0 时才显示「无余额」;订阅信息继续由同页「订阅余额」列展示。
Summary by CodeRabbit