forked from all_user/stat_center
54 lines
2.0 KiB
Go
54 lines
2.0 KiB
Go
package proto
|
|
|
|
import (
|
|
"stat/models/refundOrderMod"
|
|
)
|
|
|
|
// ============ 退款订单管理 ============
|
|
|
|
// RefundOrderListReq 退款订单查询。所有过滤条件均为可选,不传表示不限制
|
|
type RefundOrderListReq struct {
|
|
AppId *int32 `json:"appId" form:"appId"` // appId
|
|
UserId *uint64 `json:"userId" form:"userId"` // 用户ID
|
|
CID *string `json:"cid" form:"cid"` // 渠道id
|
|
ChannelName *string `json:"channelName" form:"channelName"` // 支付渠道名字
|
|
DistrictCode *string `json:"districtCode" form:"districtCode"` // 渠道码
|
|
PageNum int64 `json:"pageNum" form:"pageNum" binding:"required,gte=1"`
|
|
PageSize int64 `json:"pageSize" form:"pageSize" binding:"required,gte=1,lte=500"`
|
|
}
|
|
|
|
type RefundOrderListResp struct {
|
|
Total int64 `json:"total"`
|
|
List refundOrderMod.RefundOrderList `json:"list"`
|
|
}
|
|
|
|
// AddRefundOrderReq 按 cid 回填新增。服务端据此查询 log_recharge 的成功订单并逐条落库
|
|
type AddRefundOrderReq struct {
|
|
CID string `json:"cid" binding:"required"` // 渠道id
|
|
}
|
|
|
|
// BatchAddRefundOrderReq 批量按 cid 回填新增
|
|
type BatchAddRefundOrderReq struct {
|
|
CIDs []string `json:"cids" binding:"required,min=1,max=200"` // 渠道id列表
|
|
}
|
|
|
|
// AddRefundOrderResp 回填结果
|
|
type AddRefundOrderResp struct {
|
|
Matched int64 `json:"matched"` // log_recharge 命中的成功订单数
|
|
Inserted int64 `json:"inserted"` // 实际新增条数
|
|
Skipped int64 `json:"skipped"` // 因已存在而跳过的条数
|
|
Details []RefundCidStat `json:"details"` // 按 cid 分项,单条新增时只有一项
|
|
}
|
|
|
|
type RefundCidStat struct {
|
|
CID string `json:"cid"`
|
|
Matched int64 `json:"matched"`
|
|
Inserted int64 `json:"inserted"`
|
|
Skipped int64 `json:"skipped"`
|
|
}
|
|
|
|
// DelRefundOrderReq 按 _id 删除
|
|
type DelRefundOrderReq struct {
|
|
Id string `json:"id" binding:"required"` // 记录 _id (24位十六进制)
|
|
}
|