xy_sh-20260724115439/xy_sh/internal/entities/response.go

33 lines
1.3 KiB
Go
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package entities
// ApiResponse 通用API响应
type ApiResponse struct {
Code int `json:"code"` // 返回状态编码0成功 -1失败
Msg string `json:"msg"` // 返回错误信息
Data interface{} `json:"data"` // JSON格式业务数据进行SM4加密后的字符串
}
// OrderResponse 下单接口响应业务参数
type OrderResponse struct {
OrderNo string `json:"orderNo"` // 权益订单号
CouponNo string `json:"couponNo,omitempty"` // 卡号
CouponCode string `json:"couponCode,omitempty"` // 卡密
Status int `json:"status"` // 状态
ExpireTime string `json:"expireTime,omitempty"` // 有效期
}
// QueryResponse 查询接口响应业务参数
type QueryResponse struct {
OrderNo string `json:"orderNo"` // 权益订单号
Status int `json:"status"` // 订单状态
Account string `json:"account,omitempty"` // 充值账号
CardInfo *CardInfo `json:"cardInfo,omitempty"` // 卡券信息
CouponId string `json:"couponId,omitempty"` // 优惠id
}
// WechatRechargeResponse 微信立减金充值响应业务参数
type WechatRechargeResponse struct {
OrderNo string `json:"orderNo"` // 权益订单号
Status int `json:"status"` // 订单状态
CouponId string `json:"couponId,omitempty"` // 微信优惠id
}