Commit Graph

13 Commits

Author SHA1 Message Date
admin 3cea807353 refactor: change agent cloud data permission to cloud variables only
- Rename permission from '查看云端数据' to '查看云端变量'
- Remove cloud constants API and page for agents
- Add cloud variable records API for agents (stream type)
- Add agent cloud-variables page with full variable details
- Add agent cloud-variable records page (read-only)
- Update navigation from cloud-data to cloud-variables
- Update i18n keys: cloudData -> cloudVariables
- Backend returns var_type, default_value, max_records etc.
- Records page supports dynamic columns and date filtering
2026-05-11 08:05:40 +08:00
admin 6dcb5cde02 fix: add can_view_cloud_data to login and profile API responses
- Add can_view_cloud_data field to auth login response
- Add can_view_cloud_data field to agent profile response
- Fetch latest user permissions from /agent/profile on agent layout mount
- Update localStorage with latest can_view_cloud_data value
2026-05-11 00:15:21 +08:00
admin df4ad079f3 fix: agent finance page styling and cloud data API implementation
- Fix agent finance page: confirmed backend integration is working
- Add agent cloud-variables and cloud-constants API endpoints
- Rewrite agent cloud-data page to use real API calls instead of mock data
- Fix API path: /agent/applications -> /agent/apps
- Remove 'all' value from app filter SelectItem (empty string issue)
- Add cloudData i18n keys for zh and en
- Cloud data is read-only for agents, with CanViewCloudData permission check
2026-05-10 23:38:04 +08:00
admin 409ec4f75b 修复: 1.管理员编辑代理云端数据权限switch无效(后端缺少CanViewCloudData字段) 2.代理卡密status显示disabledbanned 3.代理用户管理只显示代理/子代理卡密充值过的用户 2026-05-10 14:12:35 +08:00
admin f3b9feca6a agent后台finance和users添加服务端分页和统计 2026-05-10 08:41:49 +08:00
admin c495f9b417 修复代理商卡密管理页面:增加服务端筛选、批量导出、复制功能 2026-05-10 04:27:55 +08:00
admin 83cd822717 fix: 修复代理卡密统计和列表查询逻辑
- 前端使用后端返回的total字段显示总数
- 后端查询条件兼容旧数据(agent_id IS NULL AND creator_id = ?)
- handleGetStats统计接口使用相同查询逻辑

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-10 02:36:26 +08:00
admin d83e7dfac9 fix: 添加代理生成卡密余额检查和扣费逻辑
- 检查代理余额是否足够
- 检查并限制生成数量(1-100)
- 使用事务确保数据一致性
- 扣除代理余额
- 记录消费记录

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-10 02:20:45 +08:00
admin 0cc3e85714 fix: 修复代理卡密列表数据不显示问题
- Card模型添加AgentID字段
- 生成卡密时设置AgentID
- handleGetCards返回正确格式的数据(包含app_name, card_type_name, code等)

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-10 02:04:45 +08:00
admin a2ce784ac0 fix: 修复代理生成卡密权限检查和参数问题
- 后端兼容application_id和app_id参数
- 添加卡类权限检查,确保代理只能生成有权限的卡类
- 前端使用application_id参数名
- 移除卡类显示中的billing_type原始值,改为显示价格

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-10 01:16:28 +08:00
admin e63753a853 feat: 添加代理获取应用详情和卡类列表API
- 添加 GET /agent/apps/:id 接口
- 返回代理有权使用的卡类列表及其价格

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-09 23:58:34 +08:00
admin 4ed00f29e2 refactor: 移除佣金比例字段,将developer统一为admin 2026-05-01 08:08:11 +08:00
Admin 5c63882e71 更新开发者平台:代理商管理、版本管理、UI优化 2026-04-29 15:19:17 +08:00