feat: 新增退款管理模块 — 完整的退款审批流程、佣金回扣和资产重置
All checks were successful
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Successful in 7m8s

新增退款申请全生命周期管理:创建/列表/详情/审批通过/拒绝/退回/重新提交
审批通过后异步执行佣金全额回扣(扣减各代理佣金钱包)和资产重置(套餐失效+停机+世代重置)
新增 tb_refund_request 表(迁移 000093)、RefundRequest Model、8 个 DTO
新增 Store/Service/Handler/路由注册,仅平台用户可访问
This commit is contained in:
2026-03-28 17:57:52 +08:00
parent 5e64c64ce3
commit 02b10f87cf
18 changed files with 1345 additions and 26 deletions

View File

@@ -23,11 +23,12 @@ const (
// 代理钱包交易类型
const (
AgentTransactionTypeRecharge = "recharge" // 充值
AgentTransactionTypeDeduct = "deduct" // 扣款
AgentTransactionTypeRefund = "refund" // 退款
AgentTransactionTypeCommission = "commission" // 分佣
AgentTransactionTypeWithdrawal = "withdrawal" // 提现
AgentTransactionTypeRecharge = "recharge" // 充值
AgentTransactionTypeDeduct = "deduct" // 扣款
AgentTransactionTypeRefund = "refund" // 退款
AgentTransactionTypeCommission = "commission" // 分佣
AgentTransactionTypeWithdrawal = "withdrawal" // 提现
AgentTransactionTypeCommissionDeduct = "commission_deduct" // 退款佣金回扣
)
// 代理钱包交易子类型(当 transaction_type = "deduct" 用于订单支付时)
@@ -112,6 +113,7 @@ const (
ReferenceTypeCommission = "commission" // 分佣
ReferenceTypeWithdrawal = "withdrawal" // 提现
ReferenceTypeTopup = "topup" // 充值
ReferenceTypeRefund = "refund" // 退款
)
// ========== Redis Key 生成函数 ==========