|
|
d85d7bffd6
|
refactor: 更新路由和 OpenAPI 注册以接入 AssetWallet
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:55 +08:00 |
|
|
|
fe77d9ca72
|
refactor: 注册 AssetWallet 组件到 Bootstrap
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:49 +08:00 |
|
|
|
9b83f92fb6
|
feat: 新增 AssetWallet Handler,实现资产钱包 API 接口
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:42 +08:00 |
|
|
|
2248558bd3
|
refactor: 适配 asset_wallet 更名,更新订单、充值和购买验证服务
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:37 +08:00 |
|
|
|
2aae31ac5f
|
feat: 新增 AssetWallet Service,实现资产钱包业务逻辑
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:29 +08:00 |
|
|
|
5031bf15b9
|
refactor: 更新 wallet 常量和队列类型以适配 asset_wallet
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:22 +08:00 |
|
|
|
9c768e0719
|
refactor: 重命名 card_wallet store 为 asset_wallet,新增 transaction store
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:17 +08:00 |
|
|
|
b6c379265d
|
refactor: 重命名 CardWallet 模型为 AssetWallet,新增 DTO
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:43:11 +08:00 |
|
|
|
4156bfc9dd
|
feat: 新增 asset_wallet 和 reference_no 数据库迁移
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 15:42:52 +08:00 |
|
|
|
0ef136f008
|
fix: 修复资产套餐列表时间字段返回异常时区偏移问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m54s
待生效套餐的 activated_at/expires_at 在 DB 中存储为零值(0001-01-01),
Go 序列化时因 Asia/Shanghai 历史 LMT(+08:05:36)导致输出异常时区偏移。
- AssetPackageResponse.ActivatedAt/ExpiresAt 改为 *time.Time + omitempty
- 新增 nonZeroTimePtr 辅助函数,零值时间转 nil,避免序列化问题
- 同步修复 GetPackages 和 GetCurrentPackage 两处赋值
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
2026-03-16 11:42:39 +08:00 |
|
|
|
b1d6355a7d
|
fix: resolve 接口 series_name 永远为空,asset service 注入套餐系列 store
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m58s
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 10:59:29 +08:00 |
|
|
|
907e500ffb
|
修复列表没有正确返回新增字段问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m58s
|
2026-03-16 10:51:15 +08:00 |
|
|
|
275debdd38
|
fix: IoT 卡列表补充 virtual_no 字段和查询过滤,修正设备/卡导入 API 文档描述
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Has been cancelled
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-16 10:44:38 +08:00 |
|
|
|
b9c3875c08
|
feat: 新增数据库迁移,重命名 device_no 为 virtual_no,新增 iot_card.virtual_no 和 package.virtual_ratio 字段
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m3s
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-14 18:27:28 +08:00 |
|
|
|
b5147d1acb
|
设备的部分改造
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m34s
|
2026-03-10 10:34:08 +08:00 |
|
|
|
86f8d0b644
|
fix: 适配 Gateway 响应模型变更,更新轮询处理器和 Mock 服务
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m25s
- polling_handler: Status→RealStatus, UsedFlow→Used, parseRealnameStatus 参数改为 bool
- mock_gateway: 同步接口路径和响应结构与上游文档一致
|
2026-03-07 11:29:40 +08:00 |
|
|
|
a83dca2eb2
|
fix: 修复 Gateway 流量卡接口路径、响应模型和时间戳与上游文档不一致
- 时间戳从 UnixMilli (13位) 改为 Unix (10位秒级)
- 实名状态接口路径 /realname-status → /realName
- 实名链接接口路径 /realname-link → /RealNameVerification
- RealnameStatusResp: status string → realStatus bool + iccid
- FlowUsageResp: usedFlow int64 → used float64 + iccid
- RealnameLinkResp: link → url
|
2026-03-07 11:29:34 +08:00 |
|
|
|
51ee38bc2e
|
使用超级管理员权限去访问gateway
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m44s
|
2026-03-07 11:10:22 +08:00 |
|
|
|
9417179161
|
fix: 修复设备限速和切卡接口请求字段解析错误
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 9m15s
SetSpeedLimit 和 SwitchCard 的 Handler 直接解析 gateway 结构体(驼峰命名),
导致与 OpenAPI 文档(DTO 蛇形命名)不一致,前端按文档调用时参数被静默丢弃。
改为先解析 DTO,再手动映射到 gateway 结构体,使文档与实际行为一致。
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
2026-03-06 18:16:10 +08:00 |
|
|
|
b52cb9a078
|
fix: 修复梯度佣金档位字段缺失,补全授权接口响应字段及强充有效状态
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m27s
- OneTimeCommissionTierDTO 补充 operator 字段映射
- GrantCommissionTierItem 补充 dimension/stat_scope 字段(从全局配置合并)
- 系列授权列表/详情补充强充锁定状态和强充金额的有效值计算
- 同步 OpenSpec 主规范并归档变更文档
|
2026-03-05 11:23:28 +08:00 |
|
|
|
de9eacd273
|
chore: 新增 systematic-debugging 技能,更新项目开发规范
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m27s
新增 systematic-debugging Skill(四阶段根因分析流程),在 AGENTS.md 和 CLAUDE.md 中补充触发条件说明。opencode.json 配置同步更新。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:38:01 +08:00 |
|
|
|
f40abaf93c
|
docs: 同步 OpenSpec 主规范,新增系列授权 capability 并更新强充预检规范
三个 capability 同步:
- agent-series-grant(新建):定义系列授权 CRUD,覆盖固定/梯度佣金模式和强充层级场景
- force-recharge-check(更新):新增「代理层强充层级判断」Requirement,更新钱包充值和套餐购买预检场景以反映平台/代理层级规则
- shop-series-allocation(更新):在 REMOVED 区域追加三个已废弃接口的文档说明(/shop-series-allocations、/shop-package-allocations、enable_one_time_commission 等字段)
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:37:46 +08:00 |
|
|
|
e0cb4498e6
|
docs: 归档 refactor-agent-series-grant 变更文档
将已完成的变更(proposal、design、tasks、delta specs)归档至 openspec/changes/archive/2026-03-04-refactor-agent-series-grant/。变更内容:合并系列分配和套餐分配为系列授权(Grant)、新增梯度佣金模式、新增代理层强充层级规则。50/50 任务全部完成。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:37:33 +08:00 |
|
|
|
c7b8ecfebf
|
refactor: 佣金计算适配梯度阶梯 Operator 比较,套餐服务集成代理强充逻辑
commission_calculation: matchOneTimeCommissionTier() 接收 agentTiers 参数,根据 tier.Operator(>、>=、<、<=,默认 >=)执行对应比较逻辑,支持代理专属梯度阶梯计算。package/service: 套餐购买预检调用更新后的强充层级判断接口。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:37:02 +08:00 |
|
|
|
2ca33b7172
|
fix: 强充预检按平台/代理层级判断,代理自设强充在平台未设时生效
checkForceRechargeRequirement() 新增层级逻辑:平台(PackageSeries)的强充配置具有最高优先级;平台未设强充时,读取 order.SellerShopID 对应的 ShopSeriesAllocation 强充配置;两者均未设时返回 need_force_recharge=false(降级处理)。GetPurchaseCheck 复用同一函数,无需额外修改。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:36:49 +08:00 |
|
|
|
769f6b8709
|
refactor: 更新路由总线和 OpenAPI 文档注册
admin.go 删除 registerShopSeriesAllocationRoutes、registerShopPackageAllocationRoutes 两处调用,注册 registerShopSeriesGrantRoutes。OpenAPI handlers.go 同步移除旧 Handler 引用,注册 ShopSeriesGrant Handler 供文档生成器使用。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:36:39 +08:00 |
|
|
|
dd68d0a62b
|
refactor: 更新 Bootstrap 注册,移除旧分配服务,接入系列授权
Types、Services、Handlers 三个文件同步:删除 ShopSeriesAllocation 和 ShopPackageAllocation 的 Handler/Service 字段及初始化逻辑,注册新的 ShopSeriesGrant Handler 和 Service。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:36:30 +08:00 |
|
|
|
c5018f110f
|
feat: 新增系列授权 Handler 和路由(/shop-series-grants)
Handler 实现 POST /shop-series-grants(创建)、GET /shop-series-grants(列表)、GET /shop-series-grants/:id(详情)、PUT /shop-series-grants/:id(更新佣金和强充配置)、PUT /shop-series-grants/:id/packages(管理授权内套餐)、DELETE /shop-series-grants/:id(删除)六个接口。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:36:20 +08:00 |
|
|
|
ad3a7a770a
|
feat: 新增系列授权 Service,支持固定/梯度佣金模式和代理自设强充
实现 /shop-series-grants 全套业务逻辑:
- 创建授权(固定/梯度模式):原子性创建 ShopSeriesAllocation + ShopPackageAllocation;校验分配者天花板和阶梯阈值匹配;平台创建无天花板限制
- 强充层级:首次充值类型由平台锁定;累计充值类型平台已设时代理配置被忽略,平台未设时代理可自设
- 查询(列表/详情):聚合套餐列表,梯度模式从 PackageSeries 读取 operator 合并响应
- 更新佣金和强充配置;套餐增删改(事务保证)
- 删除:有下级依赖时禁止删除
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:36:09 +08:00 |
|
|
|
beed9d25e0
|
refactor: 删除旧套餐系列分配和套餐分配 Service
业务逻辑已全部迁移至 shop_series_grant/service.go,旧 Service 层完整删除。底层 Store(shop_series_allocation_store、shop_package_allocation_store)保留,仍被佣金计算、订单服务和 Grant Service 使用。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:35:56 +08:00 |
|
|
|
163d01dae5
|
refactor: 删除旧套餐系列/套餐分配 Handler 和路由
/shop-series-allocations 和 /shop-package-allocations 接口已被 /shop-series-grants 完全替代,开发阶段干净删除,不保留兼容接口。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:35:46 +08:00 |
|
|
|
e7d52db270
|
refactor: 新增系列授权 DTO,删除旧套餐/系列分配 DTO
新增 ShopSeriesGrantDTO(含 packages 列表聚合视图)、CreateShopSeriesGrantRequest(支持固定/梯度模式及强充配置)、UpdateShopSeriesGrantRequest、ManageGrantPackagesRequest 等请求/响应结构。删除已被 Grant 接口取代的 ShopSeriesAllocationDTO 和 ShopPackageAllocationDTO。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:35:38 +08:00 |
|
|
|
672274f9fd
|
refactor: 更新套餐系列分配和套餐模型,支持梯度佣金和代理强充
ShopSeriesAllocation 新增 commission_tiers_json(梯度模式专属阶梯 JSON)、enable_force_recharge(代理自设强充开关)、force_recharge_amount(强充金额,0 表示使用阈值)字段;移除与 PackageSeries 重复的三个字段。Package 模型补充 PackageSeriesID 字段,用于系列授权套餐归属校验。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:35:27 +08:00 |
|
|
|
b52744b149
|
feat: 新增数据库迁移,重构套餐系列分配佣金和强充字段
迁移编号 000071,在 tb_shop_series_allocation 中新增梯度佣金字段(commission_tiers_json)、代理自设强充字段(enable_force_recharge、force_recharge_amount),删除与 PackageSeries 语义重复的三个冗余字段(enable_one_time_commission、one_time_commission_trigger、one_time_commission_threshold)。
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-opencode)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-03-04 11:34:55 +08:00 |
|
|
|
61155952a7
|
feat: 新增代理分配套餐上架状态(shelf_status)功能
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m56s
- 新增数据库迁移:为 shop_package_allocation 表添加 shelf_status 字段
- 更新模型/DTO:ShopPackageAllocation 增加 ShelfStatus 字段及相关枚举
- 更新套餐分配 Service:支持上架/下架状态管理逻辑
- 更新套餐 Store/Service:根据 shelf_status 过滤可售套餐
- 更新购买验证 Service:引入上架状态校验逻辑
- 归档 OpenSpec 变更:2026-03-02-agent-allocation-shelf-status
- 同步更新主规范文档:allocation-shelf-status、package-management、purchase-validation
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
2026-03-02 15:38:54 +08:00 |
|
|
|
8efe79526a
|
fix: 修复平台自营资源(未分配代理)无法线下下单的问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m56s
offline 支付分支新增平台自营子场景判断:
- 资源 shopID 为空时(未分配给任何代理商),使用零售价直接创建订单
- 资源 shopID 不为空时(属于代理商),走原有平台代购逻辑
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
2026-03-02 11:44:18 +08:00 |
|
|
|
a625462205
|
更新opencode
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 46s
|
2026-03-02 11:08:58 +08:00 |
|
|
|
c5429e7287
|
fix: 修复平台/超管用户订单列表查询为空的问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m5s
Service 层无条件将空 buyer_type 和 0 buyer_id 写入查询过滤条件,
导致平台/超管用户查询时附加 WHERE buyer_type = '' AND buyer_id = 0,
与任何订单均不匹配,返回空列表。
修复方式:仅当 buyerType 非空且 buyerID 非零时才添加过滤条件,
平台/超管用户不限定买家范围,可查看全部订单。
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
|
2026-03-02 10:48:11 +08:00 |
|
|
|
e661b59bb9
|
feat: 实现订单超时自动取消功能,支持钱包余额解冻和 Asynq Scheduler 统一调度
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m58s
- 新增 expires_at 字段和复合索引,待支付订单 30 分钟超时自动取消
- 实现 cancelOrder/unfreezeWalletForCancel 钱包余额解冻逻辑
- 创建 Asynq 定时任务(order_expire/alert_check/data_cleanup)
- 将原有 time.Ticker 轮询迁移至 Asynq Scheduler 统一调度
- 同步 delta specs 到 main specs 并归档变更
|
2026-02-28 17:16:15 +08:00 |
|
|
|
5bb0ff0ddf
|
fix: 修复代理钱包订单创建逻辑,拆分后台/H5端下单方法并归档变更
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m54s
- 拆分订单创建为 CreateAdminOrder(后台一步支付)和 CreateH5Order(H5 两步支付)
- 新增 CreateAdminOrderRequest DTO,后台仅允许 wallet/offline 支付方式
- 同步 delta specs 到主规格(order-payment 更新 + admin-order-creation 新增)
- 归档 fix-agent-wallet-order-creation 变更
- 新增 implement-order-expiration 变更提案
|
2026-02-28 16:31:31 +08:00 |
|
|
|
8ed3d9da93
|
feat: 实现代理钱包订单创建和订单角色追踪功能
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m0s
新增功能:
- 代理在后台使用 wallet 支付时,订单直接完成(扣款 + 激活套餐)
- 支持代理自购和代理代购场景
- 新增订单角色追踪字段(operator_id、operator_type、actual_paid_amount、purchase_role)
- 订单查询支持 OR 逻辑(buyer_id 或 operator_id)
- 钱包流水记录交易子类型和关联店铺
- 佣金逻辑调整:代理代购不产生佣金
数据库变更:
- 订单表新增 4 个字段和 2 个索引
- 钱包流水表新增 2 个字段
- 包含迁移脚本和回滚脚本
文档:
- 功能总结文档
- 部署指南
- OpenAPI 文档更新
- Specs 同步(新增 agent-order-role-tracking capability)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
2026-02-28 14:11:42 +08:00 |
|
|
|
c5bf85c8de
|
refactor: 移除 IoT 卡未使用的价格字段
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m2s
- 移除 IotCard 模型的 cost_price 和 distribute_price 字段
- 移除 StandaloneIotCardResponse DTO 中对应的字段
- 添加数据库迁移文件 000066_remove_iot_card_price_fields
- 更新 opencode.json 配置
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
2026-02-27 15:38:33 +08:00 |
|
|
|
f5000f2bfc
|
修复超管无法回收资产的问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m0s
|
2026-02-27 11:03:44 +08:00 |
|
|
|
4189dbe98f
|
debug: 添加资产回收店铺查询的调试日志
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m3s
在 RecallCards 方法中添加日志,用于诊断平台账号回收资产失败的问题:
- 记录操作者店铺ID
- 记录请求查询的店铺IDs
- 记录实际查询到的店铺数量和IDs
- 记录直属下级店铺集合
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
2026-02-27 09:36:48 +08:00 |
|
|
|
bc60886aea
|
fix: 修复 GetByIDs 缺少数据权限过滤导致平台账号无法回收资产
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m2s
在 ShopStore.GetByIDs 方法中添加 ApplyShopIDFilter,确保:
- 平台用户可以查询所有店铺(用于资产回收)
- 代理用户只能查询自己和下级店铺(保持权限隔离)
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
2026-02-26 18:07:45 +08:00 |
|
|
|
6ecc0b5adb
|
fix: 修复套餐系列/套餐分配权限过滤问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m19s
代理用户只能看到自己分配出去的记录,而不是被分配的记录。
- 新增 ApplyAllocatorShopFilter 过滤函数
- ShopSeriesAllocationStore: List 和 GetByID 改用 ApplyAllocatorShopFilter
- ShopPackageAllocationStore: List 和 GetByID 改用 ApplyAllocatorShopFilter
- 平台用户和超管不受限制
- 代理用户只能看到 allocator_shop_id = 自己店铺ID 的记录
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
|
2026-02-26 17:10:20 +08:00 |
|
|
|
1d602ad1f9
|
fix: 修复代理用户能看到全部店铺的问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m3s
在 ShopStore.List 中应用数据权限过滤,新增 ApplyShopIDFilter
函数用于对 Shop 表的 id 字段进行过滤。
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-02-26 16:55:47 +08:00 |
|
|
|
03a0960c4d
|
refactor: 数据权限过滤从 GORM Callback 改为 Store 层显式调用
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m2s
- 移除 RegisterDataPermissionCallback 和 SkipDataPermission 机制
- 在 Auth 中间件预计算 SubordinateShopIDs 并注入 Context
- 新增 ApplyShopFilter/ApplyEnterpriseFilter/ApplyOwnerShopFilter 等 Helper 函数
- 所有 Store 层查询方法显式调用数据权限过滤函数
- 权限检查函数 CanManageShop/CanManageEnterprise 改为从 Context 获取数据
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-02-26 16:38:52 +08:00 |
|
|
|
4ba1f5b99d
|
fix: 添加角色名重复检查
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 6m46s
- 创建角色时检查角色名是否已存在
- 更新角色时检查角色名是否与其他角色重复
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-02-26 14:55:46 +08:00 |
|
|
|
1382cbbf47
|
fix: 修复代理用户能看到未分配套餐系列的问题
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Has been cancelled
问题:代理用户登录后能看到所有套餐系列,即使没有分配给该店铺
原因:PackageSeries 模型没有 shop_id 字段,GORM Callback 无法自动过滤
修复:
- 在 package_series Service 的 List 方法中添加权限过滤
- 代理用户只能看到通过 shop_series_allocation 分配给自己店铺的系列
- 平台用户/超级管理员可以看到所有套餐系列
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
|
2026-02-26 14:54:52 +08:00 |
|