fix
This commit is contained in:
parent
f6f305f0f3
commit
b868ef19ae
|
@ -48,8 +48,9 @@ type CartSnapshot struct {
|
||||||
LightInfo LightInfo `json:"light_info"` //灯光数据
|
LightInfo LightInfo `json:"light_info"` //灯光数据
|
||||||
}
|
}
|
||||||
type ProductInfo struct {
|
type ProductInfo struct {
|
||||||
ProductName string `json:"product_name"`
|
ProductName string `json:"product_name"` //产品名
|
||||||
ProductSn string `json:"product_sn"`
|
ProductSn string `json:"product_sn"` //产品sn
|
||||||
|
ProductWebsiteUnit string `json:"product_website_unit"` //产品前台网站单位
|
||||||
}
|
}
|
||||||
type ModelInfo struct {
|
type ModelInfo struct {
|
||||||
ModelJson interface{} `json:"model_json"` //模型设计json数据
|
ModelJson interface{} `json:"model_json"` //模型设计json数据
|
||||||
|
|
|
@ -240,8 +240,9 @@ func (l *AddToCartLogic) AddToCart(req *types.AddToCartReq, userinfo *auth.UserI
|
||||||
},
|
},
|
||||||
SizeInfo: sizeKeyInfo,
|
SizeInfo: sizeKeyInfo,
|
||||||
ProductInfo: gmodel.ProductInfo{
|
ProductInfo: gmodel.ProductInfo{
|
||||||
ProductName: *productInfo.Title,
|
ProductName: *productInfo.Title,
|
||||||
ProductSn: *productInfo.Sn,
|
ProductSn: *productInfo.Sn,
|
||||||
|
ProductWebsiteUnit: req.ProductWebsiteUnit,
|
||||||
},
|
},
|
||||||
UserDiyInformation: gmodel.UserDiyInformation{
|
UserDiyInformation: gmodel.UserDiyInformation{
|
||||||
Phone: req.DiyInfo.Phone,
|
Phone: req.DiyInfo.Phone,
|
||||||
|
|
|
@ -6,18 +6,19 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
type AddToCartReq struct {
|
type AddToCartReq struct {
|
||||||
ProductId int64 `json:"product_id"` //产品id
|
ProductId int64 `json:"product_id"` //产品id
|
||||||
TemplateId int64 `json:"template_id,optional"` //模板id(不可定制的不传)
|
ProductWebsiteUnit string `json:"product_website_unit,optional"` //产品单位
|
||||||
IsHighlyCustomized int64 `json:"is_highly_customized"` //是否高度定制
|
TemplateId int64 `json:"template_id,optional"` //模板id(不可定制的不传)
|
||||||
SelectColorIndex int64 `json:"select_color_index"` //选择的颜色索引
|
IsHighlyCustomized int64 `json:"is_highly_customized"` //是否高度定制
|
||||||
SizeId int64 `json:"size_id"` //尺寸id
|
SelectColorIndex int64 `json:"select_color_index"` //选择的颜色索引
|
||||||
FittingId int64 `json:"fitting_id,optional"` //配件id(没有可以不传)
|
SizeId int64 `json:"size_id"` //尺寸id
|
||||||
PurchaseQuantity int64 `json:"purchase_quantity"` //购买数量
|
FittingId int64 `json:"fitting_id,optional"` //配件id(没有可以不传)
|
||||||
Logo string `json:"logo,optional"` //logo地址(没有可以不传)
|
PurchaseQuantity int64 `json:"purchase_quantity"` //购买数量
|
||||||
CombineImage string `json:"combine_image,optional"` //合图地址 (没有可以不传)
|
Logo string `json:"logo,optional"` //logo地址(没有可以不传)
|
||||||
RenderImage string `json:"render_image,optional"` //渲染结果图 (没有可以不传)
|
CombineImage string `json:"combine_image,optional"` //合图地址 (没有可以不传)
|
||||||
SwitchInfo map[string]interface{} `json:"switch_info,optional"` //开关信息
|
RenderImage string `json:"render_image,optional"` //渲染结果图 (没有可以不传)
|
||||||
DiyInfo DiyInfo `json:"diy_info,optional"` //用户diy数据(可选)
|
SwitchInfo map[string]interface{} `json:"switch_info,optional"` //开关信息
|
||||||
|
DiyInfo DiyInfo `json:"diy_info,optional"` //用户diy数据(可选)
|
||||||
}
|
}
|
||||||
|
|
||||||
type DiyInfo struct {
|
type DiyInfo struct {
|
||||||
|
|
|
@ -28,18 +28,19 @@ service shopping-cart {
|
||||||
|
|
||||||
//加入购物车
|
//加入购物车
|
||||||
type AddToCartReq {
|
type AddToCartReq {
|
||||||
ProductId int64 `json:"product_id"` //产品id
|
ProductId int64 `json:"product_id"` //产品id
|
||||||
TemplateId int64 `json:"template_id,optional"` //模板id(不可定制的不传)
|
ProductWebsiteUnit string `json:"product_website_unit,optional"` //产品单位
|
||||||
IsHighlyCustomized int64 `json:"is_highly_customized"` //是否高度定制
|
TemplateId int64 `json:"template_id,optional"` //模板id(不可定制的不传)
|
||||||
SelectColorIndex int64 `json:"select_color_index"` //选择的颜色索引
|
IsHighlyCustomized int64 `json:"is_highly_customized"` //是否高度定制
|
||||||
SizeId int64 `json:"size_id"` //尺寸id
|
SelectColorIndex int64 `json:"select_color_index"` //选择的颜色索引
|
||||||
FittingId int64 `json:"fitting_id,optional"` //配件id(没有可以不传)
|
SizeId int64 `json:"size_id"` //尺寸id
|
||||||
PurchaseQuantity int64 `json:"purchase_quantity"` //购买数量
|
FittingId int64 `json:"fitting_id,optional"` //配件id(没有可以不传)
|
||||||
Logo string `json:"logo,optional"` //logo地址(没有可以不传)
|
PurchaseQuantity int64 `json:"purchase_quantity"` //购买数量
|
||||||
CombineImage string `json:"combine_image,optional"` //合图地址 (没有可以不传)
|
Logo string `json:"logo,optional"` //logo地址(没有可以不传)
|
||||||
RenderImage string `json:"render_image,optional"` //渲染结果图 (没有可以不传)
|
CombineImage string `json:"combine_image,optional"` //合图地址 (没有可以不传)
|
||||||
SwitchInfo map[string]interface{} `json:"switch_info,optional"` //开关信息
|
RenderImage string `json:"render_image,optional"` //渲染结果图 (没有可以不传)
|
||||||
DiyInfo DiyInfo `json:"diy_info,optional"` //用户diy数据(可选)
|
SwitchInfo map[string]interface{} `json:"switch_info,optional"` //开关信息
|
||||||
|
DiyInfo DiyInfo `json:"diy_info,optional"` //用户diy数据(可选)
|
||||||
}
|
}
|
||||||
type DiyInfo {
|
type DiyInfo {
|
||||||
Phone string `json:"phone,optional"` //电话(可选)
|
Phone string `json:"phone,optional"` //电话(可选)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user