mirror of
https://github.com/Wei-Shaw/claude-relay-service.git
synced 2026-05-01 03:11:44 +00:00
fix: 修复 Claude 周额度统计范围,从仅 Opus 扩展到全部 Claude 模型
- 将 isOpusModel 替换为 isClaudeFamilyModel,使周额度限制覆盖所有 Claude 系列模型 - 前端 ApiKeysView 新增 Claude 周限制进度条显示 - 修复"无任何限制"提示在有周限制时仍然显示的问题 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -646,7 +646,8 @@
|
||||
<template
|
||||
v-if="
|
||||
isStatsLoading(key.id) &&
|
||||
(key.dailyCostLimit > 0 ||
|
||||
(key.weeklyOpusCostLimit > 0 ||
|
||||
key.dailyCostLimit > 0 ||
|
||||
key.totalCostLimit > 0 ||
|
||||
(key.rateLimitWindow > 0 && key.rateLimitCost > 0))
|
||||
"
|
||||
@@ -662,6 +663,16 @@
|
||||
</template>
|
||||
<!-- 已加载状态 -->
|
||||
<template v-else>
|
||||
<!-- Claude 周额度限制 - 独立显示 -->
|
||||
<LimitProgressBar
|
||||
v-if="key.weeklyOpusCostLimit > 0"
|
||||
:current="getCachedStats(key.id)?.weeklyOpusCost || 0"
|
||||
label="Claude 周限制"
|
||||
:limit="key.weeklyOpusCostLimit"
|
||||
type="opus"
|
||||
variant="compact"
|
||||
/>
|
||||
|
||||
<!-- 每日费用限制进度条 -->
|
||||
<LimitProgressBar
|
||||
v-if="key.dailyCostLimit > 0"
|
||||
@@ -727,7 +738,12 @@
|
||||
|
||||
<!-- 如果没有任何限制 -->
|
||||
<div
|
||||
v-else
|
||||
v-if="
|
||||
!(key.weeklyOpusCostLimit > 0) &&
|
||||
!(key.dailyCostLimit > 0) &&
|
||||
!(key.totalCostLimit > 0) &&
|
||||
!(key.rateLimitWindow > 0 && key.rateLimitCost > 0)
|
||||
"
|
||||
class="flex items-center justify-center gap-1.5 py-2 text-gray-500 dark:text-gray-400"
|
||||
>
|
||||
<i class="fas fa-infinity text-base" />
|
||||
|
||||
Reference in New Issue
Block a user