Revert "feat: 支持尊享包渠道"

This reverts commit 70ae2fab44.
This commit is contained in:
ccnetcore
2025-12-31 00:10:44 +08:00
parent 70ae2fab44
commit 0c31b97824
28 changed files with 34 additions and 1666 deletions

View File

@@ -179,16 +179,10 @@ public class DailyTaskService : ApplicationService
var tomorrow = today.AddDays(1);
// 查询今日所有使用尊享包模型的消息role=system 表示消耗)
// 先获取所有尊享模型的ModelId列表
var premiumModelIds = await _aiModelRepository._DbQueryable
.Where(x => x.IsPremium)
.Select(x => x.ModelId)
.ToListAsync();
var totalTokens = await _messageRepository._DbQueryable
.Where(x => x.UserId == userId)
.Where(x => x.Role == "system") // system角色表示实际消耗
.Where(x => premiumModelIds.Contains(x.ModelId)) // 尊享包模型
.Where(x => PremiumPackageConst.ModeIds.Contains(x.ModelId)) // 尊享包模型
.Where(x => x.CreationTime >= today && x.CreationTime < tomorrow)
.SumAsync(x => x.TokenUsage.TotalTokenCount);