feat: 单卡回收接口优化 & 店铺禁用登录拦截
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m0s

单卡回收优化:
- 移除 from_shop_id 参数,系统自动识别卡所属店铺
- 保持直属下级限制,混合来源分别处理
- 新增 GetDistributedStandaloneByICCIDRange/GetDistributedStandaloneByFilters 方法

店铺禁用拦截:
- 登录时检查关联店铺状态,禁用店铺无法登录
- 新增 CodeShopDisabled 错误码

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2026-02-25 15:54:53 +08:00
parent 25e9749564
commit 037595c22e
7 changed files with 121 additions and 29 deletions

View File

@@ -71,10 +71,8 @@ type AllocationFailedItem struct {
// ========== 回收请求/响应 ==========
// RecallStandaloneCardsRequest 回收单卡请求
// 系统自动识别卡所属店铺,只要是操作者的直属下级店铺即可回收
type RecallStandaloneCardsRequest struct {
// FromShopID 来源店铺ID必填被回收方必须是直属下级
FromShopID uint `json:"from_shop_id" validate:"required,min=1" required:"true" minimum:"1" description:"来源店铺ID被回收方"`
// SelectionType 选卡方式(必填)
SelectionType string `json:"selection_type" validate:"required,oneof=list range filter" required:"true" enum:"list,range,filter" description:"选卡方式 (list:ICCID列表, range:号段范围, filter:筛选条件)"`