简要描述:
- 购物车
请求URL:
POST/wapstore/addons/execute/addons/store/controller/wapstore/action/cart
参数:
参数名 | 是否必须 | 类型 | 说明 |
---|---|---|---|
is_deduction | 否 | int | 是否积分抵扣 0否, 1是 |
discount | 否 | string | 打多少折 |
manual_amout | 否 | string | 优惠多少金额 |
is_membercard_deduction | 否 | int | 是否会员卡抵扣 0否, 1是 |
返回示例:
正确时返回:
{
"data": {
"goods_amout": 200,
"amount": 195,
"cart_list": [
{
"shop_id": 0,
"goods_id": 1,
"sku_id": "1",
"num": "2",
"goods_picture": 1,
"store_id": 1,
"cart_id": 1,
"price": "100.00",
"discount_price": "100.00",
"stock": 2422,
"goods_name": "啊啊啊",
"sku_name": "",
"sku_name_arr": [],
"point_exchange_type": null,
"point_exchange": null,
"max_buy": 0,
"min_buy": 0,
"point_deduction_max": "20",
"point_return_max": "15",
"picture_info": "",
"return_point": 30,
"return_freight_point": 0
}
],
"msg": "",
"deduction_point": {
"point": 0,
"total_deduction_money": 0,
"total_deduction_point": 0
},
"is_point_deduction": "1",
"is_point": "1",
membercard_info:{
membercard_balance:0.00,
membercard_name:金卡
}
},
"message": "获取成功",
"code": 0
}
购物车商品发生变动时状态码返回,需弹出变动信息:
{
"code": 3,
"message": "商品发生变动的提示信息",
"data": "返回的对象数据"
}
错误时返回:
{
"code": -1,
"message": "获取失败"
}
返回参数说明:
参数名 | 类型 | 说明 |
---|---|---|
goods_amout | string | 商品小计 |
amount | string | 合计 |
shop_id | int | 店铺ID |
goods_id | int | 商品ID |
goods_name | string | 商品名 |
sku_id | int | 规格ID |
sku_name | string | 规格名 |
price | string | 价格 |
num | int | 购买数量 |
goods_picture | int | 图片ID |
picture_info | string | 图片名 |
upload_time | string | 上传时间 |
return_point | int | 返回积分 |
point_return_max | string | 最大返回积分比例 |
point_deduction_max | string | 最大积分抵扣比例 |
membercard_balance | float | 会员卡余额 |
membercard_name | string | 会员卡名称 |
total_memebrcard_deduction | float | 会员卡抵扣金额 |