Skip to content

订单

订单

/order/confirm 确认订单 (根据购物车中的商品生成待确认订单)

接口名: /order/confirm
Method: GET
请求:
    无
响应:
    code M int 0为成功,其它为失败
    msg M string 错误提示信息
    data M list 返回的订单信息
    {
        orders M list 订单信息
        [{
            sku_ids M list 商品ID列表
            freight M float 运费
            station_id M string 站点ID
            order_id M string 订单ID
            total_price M float 订单总价
            salemenu_ids M list 销售单ID列表
            receive_time M dict 收货信息
            {
                msg M string 收货时间提示
                order_flag M bool 是否可下单
                receive_time M dict 客户选择的收货时间
                {
                    defaultStart M string 开始时间HH:MM
                    defaultSpanStartFlag M int 开始时间间隔
                    defaultEnd M string 结束时间HH:MM
                    defaultSpanEndFlag M int 结束时间间隔
                }
                receive_time_limit M dict 收货时间限制
                {
                    r_start M string 开始时间
                    r_end M string 结束时间
                    s_span_time M int 开始时间间隔
                    e_span_time M int 结束时间间隔
                    receiveTimeSpan M int 时间间隔
                    time_config_id M string 时间配置ID
                }
            }
            order_time_limit M dict 下单时间限制
            {
                start M string 开始时间HH:MM
                end M string 结束时间HH:MM
                e_span_time M int 结束时间间隔
            }
            order_pay_method M int 订单支付方式
            is_price_timing M bool 是否存在时价商品
        }]
        finance_status M int 用户财务状态
        address M dict 店铺信息
        {
            id M int 店铺ID
            user_id M int 用户ID
            name M string 用户名
            addr_detail M string 店铺地址
            area_id M int 店铺区域ID
            begintime M string 开始收货时间
            endtime M string 结束收货时间
            finance_status M int 财务状态
            resname M string 店铺名
            telephone M string 电话
        }
        pay_method M int 付款方式
        all_price M float 订单总价(含运费)
        all_freight M float 订单运费
        is_price_timing M bool 是否存在时价商品
    }
逻辑:
    检测购物车商品
    分单
    格式化数据
    返回数据

/order/submit 下单

接口名: /order/submit
Method: POST
请求:
    orders     M   list     下单信息
    [{
        salemenu_ids     M    list    销售单ID列表
        sku_ids  M    list    商品ID列表
        station_id     M    string    站点ID
        spu_remark   M   dict   商品备注
        {
            spu_id: 备注信息
        }
    }]
响应:
    code    M    int    返回码
    msg     M    str    错误提示信息
    data    M    dict   订单信息
    [{
        code  M  int  下单结果
        msg   M  string  提示信息
        extender  M  dict  信息
        {
            _id  M  string  订单ID
            order_id  M  string  订单ID
            total_pay M  int  下单金额
            customer  M  dict
            {
                receive_begin_time  M  string  收货开始时间
                receive_end_time    M  string  收货结束时间
            }
        }
    }]

/order/paymethod 设置支付方式

接口名: /order/paymethod
Method: post
请求:
    无
响应:
    todo
逻辑:
    设置支付方式

/order/receive_time 设置收货时间

接口名: /order/receive_time
Method: post
请求:
    无
响应:
    todo
逻辑:
    设置收货时间

/order/cart 查看购物车商品

接口名: /order/cart
Method: post
请求:
    无
响应:
    todo
逻辑:
    查看购物车商品

/order/list 查看订单列表

接口名: /order/list
Method: GET
请求:
    无
响应:
    todo
逻辑:
    查看订单列表

/order/count 查看订单数量

接口名: /order/count
Method: GET
请求:
    无
响应:
    todo
逻辑:
    查看订单数量

/order/detail 查看订单详情

接口名: /order/detail
Method: GET
请求:
    无
响应:
    todo
逻辑:
    查看订单详情

/order/receipt 签收订单

接口名: /order/receipt
Method: POST
请求:
    无
响应:
    todo
逻辑:
    设置订单状态为已签收

/order/week 获取周期内待支付订单

接口名: /order/week
Method: GET
请求:
    无
响应:
    todo
逻辑:
    周结用户获取周期内待支付订单

/order/paid 获取周期内待支付订单

接口名: /order/paid
Method: POST
请求:
    无
响应:
    todo
逻辑:
    应付金额为0的订单设置为已支付