Compare commits
No commits in common. "cf427ec269007403e29e3e004366dc7cfc7baa48" and "95a6219fd7494885338a5a8d632e3f8bbab57969" have entirely different histories.
cf427ec269
...
95a6219fd7
@ -442,7 +442,6 @@ func BundleLangDetailV2(req *bundle.BundleDetailRequest) (res *bundle.BundleProf
|
|||||||
if err != nil {
|
if err != nil {
|
||||||
return res, errors.New("获取套餐信息失败")
|
return res, errors.New("获取套餐信息失败")
|
||||||
}
|
}
|
||||||
|
|
||||||
lang, err := dao.BundleDetailByUuidAndLanguage(req.Uuid, req.Language)
|
lang, err := dao.BundleDetailByUuidAndLanguage(req.Uuid, req.Language)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return res, errors.New("获取套餐信息失败")
|
return res, errors.New("获取套餐信息失败")
|
||||||
@ -456,16 +455,6 @@ func BundleLangDetailV2(req *bundle.BundleDetailRequest) (res *bundle.BundleProf
|
|||||||
res.Sort = detail.Sort
|
res.Sort = detail.Sort
|
||||||
res.ShelfStatus = detail.ShelfStatus
|
res.ShelfStatus = detail.ShelfStatus
|
||||||
res.Contract = detail.Contract
|
res.Contract = detail.Contract
|
||||||
if len(detail.BundleToValueAddService) > 0 {
|
|
||||||
var serviceLangInfos []*bundle.ServiceLangInfo
|
|
||||||
for _, service := range detail.BundleToValueAddService {
|
|
||||||
serviceLangInfos = append(serviceLangInfos, &bundle.ServiceLangInfo{
|
|
||||||
ValueAddUuid: service.ValueUid,
|
|
||||||
BenefitsType: service.BenefitsType,
|
|
||||||
})
|
|
||||||
}
|
|
||||||
res.ServiceLangInfo = serviceLangInfos
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
if lang != nil {
|
if lang != nil {
|
||||||
res.Name = lang.Name
|
res.Name = lang.Name
|
||||||
|
|||||||
@ -599,9 +599,6 @@ func ValueAddServiceDetailByUuidAndLanguage(req *bundle.ValueAddServiceDetailReq
|
|||||||
Options: langOptions,
|
Options: langOptions,
|
||||||
CreatedAt: time.Unix(detail.CreatedAt, 0).Format("2006-01-02 15:04:05"),
|
CreatedAt: time.Unix(detail.CreatedAt, 0).Format("2006-01-02 15:04:05"),
|
||||||
UpdatedAt: time.Unix(detail.UpdatedAt, 0).Format("2006-01-02 15:04:05"),
|
UpdatedAt: time.Unix(detail.UpdatedAt, 0).Format("2006-01-02 15:04:05"),
|
||||||
QuotaType: detail.QuotaType,
|
|
||||||
QuotaValue: detail.QuotaValue,
|
|
||||||
IsExpired: detail.IsExpired,
|
|
||||||
}
|
}
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|||||||
@ -292,16 +292,8 @@ message BundleProfileLang {
|
|||||||
string bgImg2 = 15 [json_name = "bgImg2"];
|
string bgImg2 = 15 [json_name = "bgImg2"];
|
||||||
int64 shelfStatus = 16 [json_name = "shelfStatus"]; // 1 上架 2 下架
|
int64 shelfStatus = 16 [json_name = "shelfStatus"]; // 1 上架 2 下架
|
||||||
int32 imgOption = 17 [json_name = "imgOption"];
|
int32 imgOption = 17 [json_name = "imgOption"];
|
||||||
repeated ServiceLangInfo serviceLangInfo = 18 [json_name = "serviceLangInfo"];//增值服务信息
|
|
||||||
//repeated ValueAddServiceLang valueAddServiceLang = 12 [json_name = "ValueAddServiceLang"];
|
//repeated ValueAddServiceLang valueAddServiceLang = 12 [json_name = "ValueAddServiceLang"];
|
||||||
}
|
}
|
||||||
|
|
||||||
message ServiceLangInfo {
|
|
||||||
string valueAddUuid = 1 [json_name = "valueAddUuid"];//增值服务uuid
|
|
||||||
int32 benefitsType = 2 [json_name = "benefitsType"];//权益类型 1:套餐权益 2:可选附加权益
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
message SaveResponse {
|
message SaveResponse {
|
||||||
string msg = 1 [json_name = "msg"];
|
string msg = 1 [json_name = "msg"];
|
||||||
string uuid = 2 [json_name = "uuid"];
|
string uuid = 2 [json_name = "uuid"];
|
||||||
@ -313,7 +305,7 @@ message SelectValueAddService {
|
|||||||
string serviceName= 2 [json_name = "serviceName"];// 服务名称
|
string serviceName= 2 [json_name = "serviceName"];// 服务名称
|
||||||
bool isDisplay = 3 [json_name = "isDisplay"];// 是否显示
|
bool isDisplay = 3 [json_name = "isDisplay"];// 是否显示
|
||||||
int32 serviceType = 4 [json_name = "serviceType"];// 服务类型
|
int32 serviceType = 4 [json_name = "serviceType"];// 服务类型
|
||||||
int32 quotaType = 5 [json_name = "quotaType"];// 额度类型 1;不限额度 2:每月限额度
|
int32 quotaType = 5 [json_name = "quotaType"];// 额度类型
|
||||||
int32 quotaValue = 6 [json_name = "quotaValue"];// 额度值
|
int32 quotaValue = 6 [json_name = "quotaValue"];// 额度值
|
||||||
bool isExpired = 7 [json_name = "isExpired"];// 是否过期作废
|
bool isExpired = 7 [json_name = "isExpired"];// 是否过期作废
|
||||||
int32 defaultServiceValue = 8 [json_name = "defaultServiceValue"];// 默认服务值
|
int32 defaultServiceValue = 8 [json_name = "defaultServiceValue"];// 默认服务值
|
||||||
@ -325,7 +317,7 @@ message SelectValueAdditionalService {
|
|||||||
string serviceName= 2 [json_name = "serviceName"];// 服务名称
|
string serviceName= 2 [json_name = "serviceName"];// 服务名称
|
||||||
bool isDisplay = 3 [json_name = "isDisplay"];// 是否显示
|
bool isDisplay = 3 [json_name = "isDisplay"];// 是否显示
|
||||||
int32 serviceType = 4 [json_name = "serviceType"];// 服务类型
|
int32 serviceType = 4 [json_name = "serviceType"];// 服务类型
|
||||||
int32 quotaType = 5 [json_name = "quotaType"];// 额度类型 1;不限额度 2:每月限额度
|
int32 quotaType = 5 [json_name = "quotaType"];// 额度类型
|
||||||
int32 quotaValue = 6 [json_name = "quotaValue"];// 额度值
|
int32 quotaValue = 6 [json_name = "quotaValue"];// 额度值
|
||||||
bool isExpired = 7 [json_name = "isExpired"];// 是否过期作废
|
bool isExpired = 7 [json_name = "isExpired"];// 是否过期作废
|
||||||
int32 defaultServiceValue = 8 [json_name = "defaultServiceValue"];// 默认服务值
|
int32 defaultServiceValue = 8 [json_name = "defaultServiceValue"];// 默认服务值
|
||||||
@ -544,7 +536,7 @@ message ValueAddService {
|
|||||||
string serviceName = 2 [json_name = "serviceName"]; //服务名称
|
string serviceName = 2 [json_name = "serviceName"]; //服务名称
|
||||||
int32 serviceType = 3 [json_name = "serviceType"]; //服务类型
|
int32 serviceType = 3 [json_name = "serviceType"]; //服务类型
|
||||||
repeated ValueAddServiceLang serviceLang = 4 [json_name = "serviceLang"]; //不太语言的服务详细
|
repeated ValueAddServiceLang serviceLang = 4 [json_name = "serviceLang"]; //不太语言的服务详细
|
||||||
int32 quotaType = 5 [json_name = "quotaType"];//额度类型 1;不限额度 2:每月限额度
|
int32 quotaType = 5 [json_name = "quotaType"];//额度类型
|
||||||
int32 quotaValue = 6 [json_name = "quotaValue"];//额度值
|
int32 quotaValue = 6 [json_name = "quotaValue"];//额度值
|
||||||
bool isExpired = 7 [json_name = "isExpired"];//是否过期作废
|
bool isExpired = 7 [json_name = "isExpired"];//是否过期作废
|
||||||
int32 defaultServiceValue = 8 [json_name = "defaultServiceValue"];//默认服务值
|
int32 defaultServiceValue = 8 [json_name = "defaultServiceValue"];//默认服务值
|
||||||
|
|||||||
File diff suppressed because it is too large
Load Diff
@ -112,16 +112,6 @@ func (this *BundleProfile) Validate() error {
|
|||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
func (this *BundleProfileLang) Validate() error {
|
func (this *BundleProfileLang) Validate() error {
|
||||||
for _, item := range this.ServiceLangInfo {
|
|
||||||
if item != nil {
|
|
||||||
if err := github_com_mwitkow_go_proto_validators.CallValidatorIfExists(item); err != nil {
|
|
||||||
return github_com_mwitkow_go_proto_validators.FieldError("ServiceLangInfo", err)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
func (this *ServiceLangInfo) Validate() error {
|
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
func (this *SaveResponse) Validate() error {
|
func (this *SaveResponse) Validate() error {
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user