Skip to content

订单价格同步回报价单

订单价格同步回报价单

修改接口

  1. /station/order/order_sku_list 获取批量修改单价的列表
Method:
    GET
请求:
    不变
响应:
    code    M   int     返回码,0表示成功,其他表示错误
    msg     M   string  错误信息
    data    M    list
        {
        其余字段不变
        #  这几个字段为参考价格字段,和按商品查看订单接口返回的格式一样
        # 供应商最近入库价
        last_in_stock_price: {earlier: [], newest: {purchase_supplier_name: null, purchase_supplier_id: null, price: null}}
        # 供应商最近采购价
        last_purchase_price: {earlier: [], newest: {purchase_supplier_name: null, purchase_supplier_id: null, price: null}}
        # 供应商最近询价
        last_quote_price: {earlier: [], newest: {purchase_supplier_name: null, purchase_supplier_id: null, price: null}}
        # 最近入库价
        latest_in_stock_price: null
        # 最近询价
        latest_quote_price: null
        # 库存均价
        stock_avg_price: 0
        }
  1. /station/order/edit 订单详情
Method:   GET

请求:
    不变
响应:
    {
    "data": {
        "details": [{
            新增
            latest_sale_price      最近销售价格(销售单位)  float   不存在为null
            latest_sale_unit_name    销售单位  str     不存在为null
        }],
    },
    "msg": "ok",
    "code": 0
}
  1. /station/orders 按订单查看
Method:   GET

请求:
    search_type   O  int    搜索类型:1.按订单/商户, 2. 按订单号, 3. 按商户名/ID,4.按订单备注 
    如果不传默认搜索类型为1
响应:
    不变

新增接口

  1. /station/order/sync_to_sku 订单价格同步至报价单
Method:   GET

请求:
    order_id   M  str  订单ID
响应:
    code    M   int     返回码,0表示成功,其他表示错误
    msg     M   string  错误信息
    data    M   null
  1. /station/order/batch_sync_to_sku 商品价格批量同步至报价单(异步)
Method:   GET

请求:
    当选择一部分sku是需要传的参数
    sku_data    M    list
        {
        sku_id      M     str   skuid
        order_id    M     str   订单id
        }
     当选择全部的时候需要传的参数
        和/station/order/order_sku_list的请求参数一样
响应:
    code    M   int     返回码,0表示成功,其他表示错误
    msg     M   string  错误信息
    data    M   null
逻辑:LK单不同步,时价不同步,多个价格的sku不同步
  1. /station/order/batch_sync_to_sku/result 商品价格批量同步至报价单失败的任务
Method: GET

请求:
    task_id       M   task_id        
响应:
    data         M    list
    {
        id               M    str      商品id
        name             M    str      商品名
        order_id         M    str      订单号
        address_id       M    str      商户id
        resname          M    str      商户名
        sale_price       M    float    销售单价
        sale_unit_name   M    str      销售单位
        salemenu_id      M    str      报价单id
        salemenu_name    M    str      报价单名称
        std_sale_price   M    float    基本单价
        std_unit_name    M    str      基本单位
        reason           M    str      失败的理由
        }
    code    M   int     返回码,0表示成功,其他表示错误
    msg     M   string  错误信息
  1. /station/order/update_sku_price 批量修改单价的改为异步

刷权限

开发时间6天