fix: 管理员重置配额补全 monthly 字段并修复 ristretto 缓存异步问题
- 后端 handler:ResetSubscriptionQuotaRequest 新增 Monthly 字段,
验证逻辑扩展为 daily/weekly/monthly 至少一项为 true
- 后端 service:AdminResetQuota 新增 resetMonthly 参数,
调用 ResetMonthlyUsage;重置后追加 subCacheL1.Wait(),
保证 ristretto Del() 的异步删除立即生效,消除重置后
/v1/usage 返回旧用量数据的竞态窗口
- 后端测试:更新存量测试用例匹配新签名,补充
TestAdminResetQuota_ResetMonthlyOnly /
TestAdminResetQuota_ResetMonthlyUsageError 两个新用例
- 前端 API:resetQuota options 类型新增 monthly: boolean
- 前端视图:confirmResetQuota 改为同时重置 daily/weekly/monthly
- i18n:中英文确认提示文案更新,提及每月配额
Co-Authored-By:
Claude Sonnet 4.6 <noreply@anthropic.com>
Please register or sign in to comment