通过API创建过程
- 获取仓库列表
- 存储[起始仓]和[目的仓], [发货日期], [发货方式]
- 根据 起始仓, 目的仓, 发货日期, 发货方式获取物流计划
- 获取到仓调度类型, 存储[到仓调度类型], 判断是否需要填写[vat],[收货人地址]
- 获取发货方式, 存储[发货方式], 存储该[发货方式的的必填项]
- 提交
- 添加客户发货箱
- 添加客户发货箱产品
- 更改状态
...这样做太累了, 所以我们提供了一次请求, 批量创建的接口.
一. 获取预置信息
预置信息中, 只有发货批次ID是每天变动的, 其他基本不变, 不用每次都获取.
1.1 获取起始仓, 目的仓ID
/client/Warehouse/Client-Use-Warehouse
1.2 获取发货批次ID
/client/Warehouse-Dispatch-Freight/Get-Closest-Freight
1.3 获取到仓调度类型ID
/client/Client-Dispatch-Delivery-Type
1.4 获取客户发货箱类型ID
/client/Client-Dispatch-Container-Type
1.5 获取Vat Id (可选)
/client/Client-Dispatch-Vat-Number
1.6 获取地址簿 (可选)
二. 批量创建客户发货单
url | http://test.birdsystem.com/client/Client-Dispatch-Upload/Client-Dispatch-Json | ||||||||||||||||||||||||||||
method | post | ||||||||||||||||||||||||||||
body | [ { "warehouse_id_origination": "80", "warehouse_id_destination": "1", "final_freight_method": "AIR", "warehouse_dispatch_freight_id": "221", "delivery_time": "2015-07-31", "is_use_whole_warehouse_dispatch_freight": "0", "client_dispatch_delivery_type_code": "01", "client_vat_number_id": "505", "reference": "", "delivery_reference": "", "type": "NORMAL", "client_dispatch_final_address_contact": "howard", "client_dispatch_final_address_business_name": "Birdsystem", "final_address_line1": "320 Regent Street", "final_address_line2": "", "final_address_line3": "", "client_dispatch_final_address_city": "London", "client_dispatch_final_address_county": "", "client_dispatch_final_address_post_code": "W1B 3BB", "client_dispatch_final_address_country_iso": "GB", "client_dispatch_final_address_telephone": "6666 6666 666", "client_dispatch_final_address_email": "", "shipping_agent_id": "1", "shipping_agent_delivery_reference": "aabb", "shipping_agent_note": "aabb", "note": "", "client_dispatch_container_product_list": [ { "client_dispatch_container_reference": "1", "client_dispatch_container_type_code": "BIG", "client_dispatch_container_weight": "3000", "product_id": "499235", "quantity": "10" }, { "client_dispatch_container_reference": "1", "client_dispatch_container_type_code": "BIG", "client_dispatch_container_weight": "3000", "product_id": "499235", "quantity": "10" }, { "client_dispatch_container_reference": "2", "client_dispatch_container_type_code": "BIG", "client_dispatch_container_weight": "3000", "product_id": "499235", "quantity": "10" } ] } ] | ||||||||||||||||||||||||||||
返回 | {"success":true,"message":null,"data":["8288","8289"]} | ||||||||||||||||||||||||||||
参数 |
|
三. 修改发货单状态
参数为CLIENT_DISPATCHED
完成