* 获取确认订单页面
~~~[api]
get:/index.php?ctl=Buyer_Cart&met=confirm&typ=json
string:k#key
int:u#用户id
product_id#购物车id array
ifcart#
address_id#默认地址id
cart_type#
<<<
success
{
"cmd_id": -140,
"status": 200,
"msg": "success",
"data": {
"glist": [
{
"shop_id": "8",
"shop_name": "hp的店铺",
"shop_user_id": "10013",
"shop_user_name": "hp",
"district_id": "1876",
"shop_self_support": "false",
"goods": [
{
"cart_id": "5512",
"user_id": "10014",
"shop_id": "8",
"goods_id": "435",
"goods_num": "4",
"cart_status": "0",
"id": "5512",
"transport_area_id": "0",
"buy_able": 1,
"cubage": "1.00",
"old_price": "200.00",
....
"address": [
{
"user_address_id": "5",
"user_id": "10014",
"user_address_contact": "adwq",
"user_address_province_id": "9",
"user_address_city_id": "152",
"user_address_area_id": "1892",
"user_address_area": "上海 闵行区 古美街道",
"user_address_address": "aaaaaaaaaaaaa",
"user_address_phone": "15212206900",
"user_address_company": "",
"user_address_default": "1",
"user_address_time": "2017-11-16 11:09:24",
"id": "5"
},
...
],
"cost": [
{
"cost": 0,
"con": ""
}
],
"order_discounted_price": 379.2,
"order_cost_sum": "15.80"
}
}
<<<
error
~~~
* 获取默认收货地址信息
~~~[api]
get:/index.php?ctl=Buyer_User&met=getUserConfigAddress&typ=json
string:k#key
int:u#用户id
<<<
success
{
"cmd_id": -140,
"status": 200,
"msg": "success",
"data": {
"user_address_id": "5",
"user_id": "10014",
"user_address_contact": "adwq",
"user_address_province_id": "9",
"user_address_city_id": "152",
"user_address_area_id": "1892",
"user_address_area": "上海 闵行区 古美街道",
"user_address_address": "aaaaaaaaaaaaa",
"user_address_phone": "15212111111",
"user_address_company": "",
"user_address_default": "1",
"user_address_time": "2017-11-16 11:09:24",
"id": "5"
}
}
<<<
error
{"cmd_id":-1,"status":250,"msg":"\u534f\u8bae\u5185\u5bb9\u6709\u8bef\uff1a-140","data":0}
~~~
* 获取收货地址管理列表
~~~[api]
get:/index.php?ctl=Buyer_Cart&met=confirm&typ=json
string:k#key
int:u#用户id
product_id:#购物车id array
<<<
success
{
"cmd_id": -140,
"status": 200,
"msg": "success",
"data": {
"glist": [
{
"shop_id": "8",
"shop_name": "hp的店铺",
"shop_user_id": "10013",
"shop_user_name": "hp",
"district_id": "1876",
"shop_self_support": "false",
"goods": [
{
"cart_id": "5512",
"user_id": "10014",
"shop_id": "8",
"goods_id": "435",
"goods_num": "4",
"cart_status": "0",
"id": "5512",
"transport_area_id": "0",
"buy_able": 1,
"cubage": "1.00",
"old_price": "200.00",
"now_price": "100.00",
"down_price": 100,
"order_goods_count": 1,
"IsHaveBuy": 0,
"buy_limit": "0",
"sumprice": "400.00",
"cat_commission": "1",
"commission": "4.00",
"goods_base": {
.....
"address": [
{
"user_address_id": "5",
"user_id": "10014",
"user_address_contact": "adwq",
"user_address_province_id": "9",
"user_address_city_id": "152",
"user_address_area_id": "1892",
"user_address_area": "上海 闵行区 古美街道",
"user_address_address": "aaaaaaaaaaaaa",
"user_address_phone": "15212206900",
"user_address_company": "",
"user_address_default": "1",
"user_address_time": "2017-11-16 11:09:24",
"id": "5"
},
....
],
"cost": [
{
"cost": 0,
"con": ""
}
],
"order_discounted_price": 379.2,
"order_cost_sum": "15.80"
}
}
<<<
error
~~~
* 选择收货地址
~~~[api]
get:/index.php?ctl=Buyer_Cart&met=confirm&typ=json
string:k#key
int:u#用户id
product_id#购物车id array
ifcart#
address_id#默认地址id
cart_type#
<<<
success
{
"cmd_id": -140,
"status": 200,
"msg": "success",
"data": {
"glist": [
{
"shop_id": "8",
"shop_name": "hp的店铺",
"shop_user_id": "10013",
"shop_user_name": "hp",
"district_id": "1876",
"shop_self_support": "false",
"goods": [
{
"cart_id": "5512",
"user_id": "10014",
"shop_id": "8",
"goods_id": "435",
"goods_num": "4",
"cart_status": "0",
"id": "5512",
"transport_area_id": "0",
"buy_able": 1,
"cubage": "1.00",
"old_price": "200.00",
"now_price": "100.00",
"down_price": 100,
...
"address": [
{
"user_address_id": "5",
"user_id": "10014",
"user_address_contact": "adwq",
"user_address_province_id": "9",
"user_address_city_id": "152",
"user_address_area_id": "1892",
"user_address_area": "上海 闵行区 古美街道",
"user_address_address": "aaaaaaaaaaaaa",
"user_address_phone": "15212206900",
"user_address_company": "",
"user_address_default": "1",
"user_address_time": "2017-11-16 11:09:24",
"id": "5"
},
.....
],
"cost": [
{
"cost": 0,
"con": ""
}
],
"order_discounted_price": 379.2,
"order_cost_sum": "15.80"
}
}
<<<
error
~~~
* 提交订单
~~~[api]
get:/?ctl=Buyer_Order&met=addOrder&typ=json
string:k#key
int:u#用户id
receiver_name#收货人
receiver_address#收货人地址
receiver_phone#收货人手机号
invoice#是否开发票
invoice_id#发票id
invoice_title#发票性质
invoice_content#发票内容
cart_id#购物车id
shop_id#商品店铺id
remark#留言
pay_way_id#支付方式
address_id#地址id
from#购物平台
<<<
success
success
{
"cmd_id":100,
"status":200,
"msg":"success",
"data":
{
}
}
<<<
error
success
{
"cmd_id":100,
"status":250,
"msg":"error",
"data":
{
}
}
~~~
- 商城api接口
- 首页数据获取
- 分类接口
- 购物车接口
- 商品信息接口
- 搜索接口
- 订单列表接口
- 店铺接口
- 收藏接口
- 收货地址接口
- 生成订单接口
- 支付接口
- 会员中心接口
- 登录注册接口
- 关于我们
- 图片上传
- 分销中心
- 分销明细
- 代金券
- 平台红包列表
- 分销申请列表
- 我的推广
- 微信小程序
- 简介
- 开发前准备
- 目录结构介绍
- 发起请求
- 网络请求提交表单
- 代码及开发所遇到问题总结
- 导航跳转时所遇到的问题
- 缓存数据与数据取得的问题
- 如何引入外部css
- 如何定义与使用全局变量
- 如何定义新的界面
- 微信小程序支付
- 小程序的手机验证码登录
- 上传,下载
- 提示框
- app.json配置
- 配置demo
- pages
- window
- tabBar
- networkTimeout
- debug
- page.json
- 缓存
- 特效
- 滑动方式
- 城市切换
- 五星好评
- Switch
- 上拉加载
- wxml 标签
- 视图容器
- 基础内容
- 表单组件
- 导航
- 媒体组件
- 自定义提示框
- 小程序内访问网页
- 倒计时显示
- 微信小程序,如何在返回前一个页面时,执行前一个页面的方法
- 在本地可以请求到数据,但手机上是请求不到的
- curl请求失败
- 代码同步
- 短信平台更换