mirror of
https://github.com/Wei-Shaw/claude-relay-service.git
synced 2026-01-23 18:44:51 +00:00
feat: 支持账号维度的数据统计
This commit is contained in:
@@ -497,6 +497,9 @@ class ClaudeAccountService {
|
||||
schedulable: account.schedulable !== 'false', // 默认为true,兼容历史数据
|
||||
// 添加自动停止调度设置
|
||||
autoStopOnWarning: account.autoStopOnWarning === 'true', // 默认为false
|
||||
// 添加5小时自动停止状态
|
||||
fiveHourAutoStopped: account.fiveHourAutoStopped === 'true',
|
||||
fiveHourStoppedAt: account.fiveHourStoppedAt || null,
|
||||
// 添加统一User-Agent设置
|
||||
useUnifiedUserAgent: account.useUnifiedUserAgent === 'true', // 默认为false
|
||||
// 添加统一客户端标识设置
|
||||
@@ -2333,7 +2336,7 @@ class ClaudeAccountService {
|
||||
for (const account of accounts) {
|
||||
// 只检查因5小时限制被自动停止的账号
|
||||
// 重要:不恢复手动停止的账号(没有fiveHourAutoStopped标记的)
|
||||
if (account.fiveHourAutoStopped === 'true' && account.schedulable === 'false') {
|
||||
if (account.fiveHourAutoStopped === true && account.schedulable === false) {
|
||||
result.checked++
|
||||
|
||||
// 使用分布式锁防止并发修改
|
||||
|
||||
Reference in New Issue
Block a user