@@ -2,6 +2,7 @@ package dto
2
2
3
3
import (
4
4
"github.com/allegro/bigcache"
5
+
5
6
"github.com/yituoshiniao/gin-api-http/internal/api/http"
6
7
)
7
8
@@ -26,7 +27,7 @@ type StatusLocalCacheTaskResponse struct {
26
27
}
27
28
28
29
type ProductTerritoryPriceRequest struct {
29
- ProductId string `form:"productId" binding:"required"` //产品id
30
+ ProductId string `form:"productId" binding:"required"` // 产品id
30
31
Territory string `form:"territory" binding:"required,min=2,max=3"` // 国家地区编码 三位,参数最小长度2,最大长度3
31
32
Channel string `form:"channel" binding:"required"` // 渠道 如 camexam(蜜蜂试卷)
32
33
Timestamp int64 `form:"timestamp" binding:"required"` // 传递时间戳
@@ -35,87 +36,87 @@ type ProductTerritoryPriceRequest struct {
35
36
}
36
37
37
38
type ProductTerritoryPriceInternalRequest struct {
38
- ProductId string `form:"productId" binding:"required"` //产品id
39
+ ProductId string `form:"productId" binding:"required"` // 产品id
39
40
// Territory string `form:"territory" binding:"required,min=2,max=3"` // 国家地区编码 三位,参数最小长度2,最大长度3
40
41
Channel string `form:"channel,default=cs"` // 渠道 如 camexam(蜜蜂试卷)
41
42
Vector string `form:"vector"`
42
43
}
43
44
44
45
type AppleTokenRequest struct {
45
- ProductId string `form:"productId" binding:"required"` //产品id
46
+ ProductId string `form:"productId" binding:"required"` // 产品id
46
47
Territory string `form:"territory" binding:"required"` // 国家地区编码 三位
47
48
Channel string `form:"channel" binding:"required"` // 渠道 如 camexam(蜜蜂试卷)
48
49
Timestamp int64 `form:"timestamp"` // 传递时间戳
49
50
}
50
51
51
52
type AppleTokenResponse struct {
52
- Params map [string ]string `json:"params"` //请求参数
53
- Token string `json:"token"` //生成token
53
+ Params map [string ]string `json:"params"` // 请求参数
54
+ Token string `json:"token"` // 生成token
54
55
}
55
56
56
57
type ProductTerritoryPriceResponse struct {
57
58
Number int64 `json:"number,string"` // int64 javascript前段精度问题,转字符串返回
58
- ProductId string `json:"productId"` //产品id
59
- Name string `json:"name"` //产品名
60
- CustomerPrice float64 `json:"customerPrice"` //价格
61
- FirstPrice float64 `json:"firstPrice"` //首单优惠价格
62
- Territory string `json:"territory"` //地区编码
63
- Currency string `json:"currency"` //货币
59
+ ProductId string `json:"productId"` // 产品id
60
+ Name string `json:"name"` // 产品名
61
+ CustomerPrice float64 `json:"customerPrice"` // 价格
62
+ FirstPrice float64 `json:"firstPrice"` // 首单优惠价格
63
+ Territory string `json:"territory"` // 地区编码
64
+ Currency string `json:"currency"` // 货币
64
65
ManualPricesId string `json:"manualPricesId"`
65
66
SubscriptionsPricePointsId string `json:"subscriptionsPricePointsId"`
66
- Channel string `json:"channel"` //渠道
67
+ Channel string `json:"channel"` // 渠道
67
68
Type int8 `json:"type"` // 订阅类型
68
- SubscriptionPeriod string `json:"subscriptionPeriod"` //订阅周期
69
+ SubscriptionPeriod string `json:"subscriptionPeriod"` // 订阅周期
69
70
InAppPurchaseType string `json:"InAppPurchaseType"`
70
- FamilySharable int8 `json:"familySharable"` //是否家庭共享
71
- AvailableInAllTerritories int8 `json:"availableInAllTerritories"` //是否适用于所有地区
72
- Price string `json:"price"` //原价
73
- PriceMonthly string `json:"priceMonthly"` //原价折月价
74
- PriceYear string `json:"priceYear"` //原价折年价
75
- OfferPrice string `json:"offerPrice"` //优惠价
76
- OfferPriceMonthly string `json:"offerPriceMonthly"` //优惠折月价
77
- OfferPriceYear string `json:"offerPriceYear"` //优惠折年价
78
- TerritoryName string `json:"territoryName"` //国家名称
71
+ FamilySharable int8 `json:"familySharable"` // 是否家庭共享
72
+ AvailableInAllTerritories int8 `json:"availableInAllTerritories"` // 是否适用于所有地区
73
+ Price string `json:"price"` // 原价
74
+ PriceMonthly string `json:"priceMonthly"` // 原价折月价
75
+ PriceYear string `json:"priceYear"` // 原价折年价
76
+ OfferPrice string `json:"offerPrice"` // 优惠价
77
+ OfferPriceMonthly string `json:"offerPriceMonthly"` // 优惠折月价
78
+ OfferPriceYear string `json:"offerPriceYear"` // 优惠折年价
79
+ TerritoryName string `json:"territoryName"` // 国家名称
79
80
PriceNumMap map [string ]string `json:"priceNumMap"`
80
81
MonthPriceMap map [string ]string `json:"monthPriceMap"`
81
82
YearPriceMap map [string ]string `json:"yearPriceMap"`
82
83
OfferMonthPriceMap map [string ]string `json:"offerMonthPriceMap"`
83
84
OfferYearPriceMap map [string ]string `json:"offerYearPriceMap"`
84
85
}
85
86
type ExtendSubscriptionRenewalDateRequest struct {
86
- ExtendByDays string `form:"extendByDays" binding:"required,min=1,max=90"` //延长订阅续天数 最大90天
87
- //ExtendReasonCode延迟原因;
88
- //0、未申报;没有提供信息。
89
- //1、延长续订日期是为了让客户满意。
90
- //2、续订日期延期是出于其他原因。
91
- //3、续订日期延期是由于服务问题或中断。
92
- ExtendReasonCode string `form:"extendReasonCode" binding:"required"` //延迟原因
93
- OriginalTransactionId string `form:"originalTransactionId" binding:"required"` //订单id
94
- Channel string `form:"channel" binding:"required"` //渠道 cs || 蜜蜂等
95
- Sign string `form:"sign" binding:"required"` //签名
87
+ ExtendByDays string `form:"extendByDays" binding:"required,min=1,max=90"` // 延长订阅续天数 最大90天
88
+ // ExtendReasonCode延迟原因;
89
+ // 0、未申报;没有提供信息。
90
+ // 1、延长续订日期是为了让客户满意。
91
+ // 2、续订日期延期是出于其他原因。
92
+ // 3、续订日期延期是由于服务问题或中断。
93
+ ExtendReasonCode string `form:"extendReasonCode" binding:"required"` // 延迟原因
94
+ OriginalTransactionId string `form:"originalTransactionId" binding:"required"` // 订单id
95
+ Channel string `form:"channel" binding:"required"` // 渠道 cs || 蜜蜂等
96
+ Sign string `form:"sign" binding:"required"` // 签名
96
97
}
97
98
98
99
type OfferSignRequest struct {
99
100
// 购买项id example:com.premiums.oneyear.autorenewable.free.limited2
100
- ProductID string `form:"productId" binding:"required"` //产品id
101
- //offerID example:firstyear178
101
+ ProductID string `form:"productId" binding:"required"` // 产品id
102
+ // offerID example:firstyear178
102
103
OfferID string `form:"offerId" binding:"required"`
103
- //Channel 渠道 example: cs
104
+ // Channel 渠道 example: cs
104
105
Channel string `form:"channel" binding:"required"`
105
- //ApplicationUsername
106
+ // ApplicationUsername
106
107
ApplicationUsername string `form:"applicationUsername" binding:"required"`
107
108
}
108
109
109
110
type OfferSignResponse struct {
110
111
http.ResponseData
111
112
}
112
113
type ProductTerritoryPriceInternalResponse struct {
113
- ProductId string `json:"productId"` //产品id
114
- Price string `json:"price"` //原价
115
- PriceMonthly string `json:"priceMonthly"` //原价折月价
116
- OfferPrice string `json:"offerPrice"` //优惠价
117
- OfferPriceMonthly string `json:"offerPriceMonthly"` //优惠折月价
118
- TerritoryName string `json:"territoryName"` //国家名称
119
- PriceYear string `json:"priceYear"` //原价折年价
120
- OfferPriceYear string `json:"offerPriceYear"` //优惠折年价
114
+ ProductId string `json:"productId"` // 产品id
115
+ Price string `json:"price"` // 原价
116
+ PriceMonthly string `json:"priceMonthly"` // 原价折月价
117
+ OfferPrice string `json:"offerPrice"` // 优惠价
118
+ OfferPriceMonthly string `json:"offerPriceMonthly"` // 优惠折月价
119
+ TerritoryName string `json:"territoryName"` // 国家名称
120
+ PriceYear string `json:"priceYear"` // 原价折年价
121
+ OfferPriceYear string `json:"offerPriceYear"` // 优惠折年价
121
122
}
0 commit comments