gmw 5 anni fa
parent
commit
330c33a4b9
1 ha cambiato i file con 207 aggiunte e 74 eliminazioni
  1. 207 74
      README.md

+ 207 - 74
README.md

@@ -188,27 +188,6 @@
 }
 ```
 
-## 查询订单接口
-
-**简要描述:** 请使用查询订单v2接口
-
-**请求 URL:** `/order/find_order`
-
-**请求方式:** get
-
-**需要认证:** 是
-
-**调用频率限制:** 一小时内最多调用一万次,超过会提示操作频繁
-
-**请求参数:**
-
-| 参数名 | 必选 | 类型 | 说明 |
-|:----:|:---:|:-----:|:-----:|
-| `orderNumber` | 否 | `String` | 订单号,多个订单用','隔开  |
-| `phoneNumber` | 否 | `String` | 发货人手机号 |
-| `customerNumber` | 否 | `String` | 客户自定义单号 |
-||||不传任何参数则查询所有|
-
 
 ## 查询订单接口v2
 
@@ -229,7 +208,7 @@
 | `orderNumber` | 否 | `String` | 订单号,多个订单用','隔开  |
 | `phoneNumber` | 否 | `String` | 发货人手机号 |
 | `customerNumber` | 否 | `String` | 客户自定义单号 |
-||||不传任何参数则查询所有|
+||||不传任何参数则查询所有,但最多只会返回50条最近创建的数据|
 
 **返回示例**
 
@@ -241,63 +220,220 @@
     "message": null,
     "data": [
         {
-            "number": "1707171455038482",// 订单号
-            "wmsNumber": null,// wms订单号
-            "wmsLocation": null, // 集货号
-            "deliveryTime": 1500274800,// 提货时间
-            "customerOrderNumber": "", // 客户单号
-            "consigner": { // 发货人
-                "name": "张三",//姓名
-                "phone": "13311111111",//电话
-                "address": {
-                    "province": null,//省
-                    "city": null,//市
-                    "district": null,//地区
-                    "name": "计量大厦",//详细地址
-                    "address": "计量大厦",//详细地址
-                    "lng": 120.12592,//纬度
-                    "lat": 30.277378//经度
+            "id": "5c4ad2619c023a001044079a", //订单id
+            "uid": "5bc725b6e4b07d20a861600f", //主账号uid
+            "number": "1901251709800228", //运单号
+            "wmsNumber": null, //wmsNumber,即创建订单时的orderNumber
+            "wmsLocation": null, //集货位
+            "operator": "5bc725b6e4b07d20a861600f", //操作人uid
+            "createUserId": "15161181167", //创建人手机号
+            "createUsername": "gmw", //创建人姓名
+            "deliveryTime": 1548669600, //提货时间,秒为单位的时间戳
+            "deliveryType": null, //提送类型 1, "自提"  2, "送货"
+            "appointArriveTime": 1548980160, //预约送达时间,秒为单位的时间戳
+            "customerOrderNumber": "JSOUT1234567", //客户单号
+            "startAddress": "杭州", //起始地址
+            "endAddress": "千岛湖", //目的地址
+            "consigner": { //发货方信息
+                "name": "发货方", //发货人姓名
+                "phone": "15161151543", //发货人手机
+                "address": { //发货人地址相关信息
+                    "province": null, //省
+                    "cityCode": null, //城市代码
+                    "city": null, //城市
+                    "district": null, //区
+                    "name": "浙江省温州市鹿城区浙江温州化工总厂",
+                    "address": "浙江省温州市鹿城区浙江温州化工总厂", //地址
+                    "lng": 120.579412, //经度
+                    "lat": 28.024421 //纬度
                 }
             },
-            "consignees": [//收货人
+            "consignees": [ //收货方信息
                 {
-                     "name": "李四",//姓名
-                    "phone": "13311111111",//电话
+                    "name": "收货方",
+                    "phone": "15161128126",
                     "address": {
-                        "province": null,//省
-                        "city": null,//市
-                        "district": null,//地区
-                        "name": "计量大厦",//详细地址
-                        "address": "计量大厦",//详细地址
-                        "lng": 120.12592,//纬度
-                        "lat": 30.277378//经度
+                        "province": null,
+                        "cityCode": null,
+                        "city": null,
+                        "district": null,
+                        "name": "浙江省杭州市淳安县绿城千岛湖喜来登度假酒店",
+                        "address": "浙江省杭州市淳安县绿城千岛湖喜来登度假酒店",
+                        "lng": 119.039414,
+                        "lat": 29.608042
                     }
                 }
             ],
-            "cargo": {//货物
-                "name": "书本",//货物名称
-                "quantity": 3,//数量
-                "weight": 55,//重量(KG)
-                "volume": 6,//体积(L)
-                "value": 56,//货值(元)
+            "cargo": {
+                "id": null, //货物id
+                "uid": null, //创建人id
+                "name": "货物1", //货物名字,取第一个货物的名字
+                "quantity": 3, //货物总数量
+                "weight": 5, //货物总重量
+                "volume": 7, //货物总体积
+                "productModel": "货物1备注", //货物备注
+                "note1": "货物1备注1", //货物自定义备注1
+                "note2": "货物1备注2", //货物自定义备注2
+                "note3": "货物1备注3", //货物自定义备注3
+                "note4": "", //货物自定义备注4
+                "note5": "", //货物自定义备注5
+                "note6": "", //货物自定义备注6
+                "value": null, //货值
+                "consignerPhone": null, //发货人手机号
+                "consigneePhones": null, //收货人手机号
+                "created": null, //创建货物时间
+                "updated": null //更新货物数据时间
+            },
+            "totalCargoes": 2, //货物总数量
+            "settlementParty": 1, //结算方
+            "freightIn": { //上游运费
+                "payType": 1, //上游费用支付方式, 1现付,2到付,3回付,4周结,5月结
+                "amount": 11 //上游费用
             },
-            "freightIn": {//上游运费
-                "amount": 22
+            "freightOut": { //司机运费
+                "payType": 5, //上游费用支付方式, 1现付,2到付,3回付,4周结,5月结
+                "amount": 12 //司机费用
             },
-            "freightOut": {//下游运费
-                "amount": 11
+            "totalFreightIn": 11, //总上游费用
+            "freightReceived": null, //已收费用
+            "freightUnreceived": 11, //未收费用
+            "freightCollect": null, //代收运费
+            "freightCollectReceived": null, //已收代收运费
+            "freightCollectUnReceived": 0, //未收代收运费
+            "paymentCollect": null, //代收货款
+            "paymentCollectReceived": null, //已收代收货款
+            "paymentCollectUnReceived": 0, //未收代收货款
+            "needReceipt": 1, //是否需要回单
+            "receiptCount": 1, //回单数量
+            "note": "运单备注", //运单备注
+            "extraFields": {
+                "uppay1": "", // 上游自定义运费1
+                "uppay2": "", // 上游自定义运费2
+                "uppay3": "", // 上游自定义运费3
+                "uppay4": "", // 上游自定义运费4
+                "uppay5": "", // 上游自定义运费5
+                "uppay6": "", // 上游自定义运费6
+                "pay1": "", // 司机自定义运费1
+                "pay2": "", // 司机自定义运费2
+                "pay3": "", // 司机自定义运费3
+                "pay4": "", // 司机自定义运费4
+                "pay5": "", // 司机自定义运费5
+                "pay6": "", // 司机自定义运费6
+                "note1": "", // 自定义备注1
+                "note2": "", // 自定义备注2
+                "note3": "", // 自定义备注3
+                "note4": "", // 自定义备注4
+                "note5": "", // 自定义备注5
+                "note6": "", // 自定义备注6
+                "note7": "", // 自定义备注7
+                "note8": "", // 自定义备注8
+                "note9": "", // 自定义备注9
+                "note10": "", // 自定义备注10
+                "note11": "", // 自定义备注11
+                "note12": "" // 自定义备注12
             },
-            "paymentCollect": 33,//代收货款
-            "needReceipt": 1,//是否需要回单
-            "receiptCount": 1,//回单数量
-            "note": "",//备注
-            "state": 2000,//状态
-            "publishTime": 1500274522,//发布时间
-            "receiveTime": 1500274522,//接单时间
-            "shipmentTime": null,//装货时间
-            "signedTime": null,//签收时间
-            "receiptStatus": null,//接单状态
-            "created": 1500274505,//订单创建时间
+            "option1": null, //自定义选项1
+            "option2": null, //自定义选项2
+            "option3": null, //自定义选项3
+            "organizationPath": "0", //所属组织机构的path字段(不是名字),具体请参考常见问题指南
+            "dispatchInfo": { //调度信息
+                "driverPhone": null, //司机电话
+                "driverUids": [], //司机列表
+                "gids": [], //车队列表
+                "carMode": null, //车型
+                "orderCount": 1, //生成订单数量
+                "shouldNotifyDriver": false, //是否给司机发动提醒
+                "needDriverAgree": false, //是否需要司机同意,默认否(只有一个订单时有效)
+                "driverTags": null, //司机标签
+                "vehicleTagIds": null //车辆标签
+            },
+            "batchId": null, //批量导入的批次id
+            "createUid": "5bc725b6e4b07d20a861600f", //开单人
+            "source": 1, //订单来源,1手工录入,2标准导入,4接口导入
+            "state": 2000, //状态  0:"已撤销" 1000:"待处理" 2000:"已发布"
+            "parentOrderId": null, //父订单id
+            "splitOrderId": null, //拆分源订单
+            "planNumber": null, //任务计划的编号
+            "omsNumber": null, //受理单号
+            "packNumber": "P1901255BCE400F0001", //车次号
+            "waybillState": 2, //运单状态,state为2000时才会有值,1已下单,2已接单,3已装货,4已签收
+            "dispatchDriver": { //司机信息
+                "uid": "5c4a7f86e4b0f2d798da543e", //司机账号的id
+                "username": "司机姓名", //名字
+                "phoneNumber": "13872897189", //电话
+                "carNumber": "浙A92874", //车牌号
+                "carMode": 1, //车型
+                "carDetailMode": 0, //详细车型
+                "passType": 0, //通行证类型 0:未指定 1:邮政通 2:绿通 3:全市通 4:三环通 5:江南通 6:江北通
+                "passTypeValue": "" //通行证
+            },
+            "evaluate": null, //评价
+            "miles": 342, //预估里程
+            "openTime": null, //开单时间
+            "publishTime": 1548407457, //发布时间
+            "receiveTime": 1548407457, //接收时间
+            "shipmentTime": null, //装货时间
+            "signedTime": null, //签收时间
+            "receiptCallbackTime": null, //回单回收时间
+            "receiptSendOutTime": null, //回单发放时间
+            "evaluateTime": null, //评价时间
+            "receiptStatus": null, //回单状态  回单已回收,回单已发放
+            "receiptUploaded": null, //回单是否已上传
+            "settlementStatus": null, //运费状态 
+            "freightCollectStatus": null, //代收运费状态 0:未收取 1:已收取 2:已核销 3:部分收取 99:所有
+            "collectionAmountStatus": null, //代收货款状态 0:未收取 1:已收取 2:已核销 3:部分收取 99:所有
+            "orderSendType": 1, //订单指派方式 1:指派 2:抢单P
+            "orderPrintStatus": null, //订单打印状态 1:已打印
+            "tipsPrintStatus": null, //订单标签打印状态 1:已打印
+            "segmentNumber": null, //分段number
+            "segmentType": null, //分段类型 0:提货,5:提货到外转方,1:中转,2:直送,3:外转直送,4:外转中继
+            "segmentReceiveOrganizeidPath": null, //分段收货方组织机构
+            "freezeDeliveryTime": null, //继承提货时间
+            "freezeAppointArriveTime": null, //继承预约到达时间
+            "freezeStartAddress": null, //继承起始地
+            "freezeEndAddress": null, //继承目的地
+            "freezePaymentCollect": null, //继承代收货款
+            "abnormal": null, //异常标记,布尔值,为空则没有异常
+            "abnormal_dispose_status": null, //异常处理标记,布尔值,为空则没有异常
+            "deliveryAddress": null, //装货地址
+            "signAddress": null, //签收地址
+            "onlinePayState": null, //在线支付状态 1支付中,2支付成功
+            "onlinePayment": null, //在线支付金额
+            "transactionId": null, //交易流水号
+            "isDelete": null, //是否删除 1为删除
+            "created": 1548407393, //订单创建时间
+            "updated": 1548407458, //订单更新时间
+            "startAddressLng": null, //起点经度
+            "startAddressLat": null, //起点纬度
+            "endAddressLng": null, //终点经度
+            "endAddressLat": null, //终点纬度
+            "financeCollectFixedTime": null, //代收货款核销时间
+            "freightCollectFixedTime": null, //代收运费核销时间
+            "apportionFee": null, //车次分摊费用
+            "checkPickUpAlarm": null, //提货超时是否检查:1:检查过
+            "checkDeliverAlarm": null, //送货超时是否检查:1:检查过
+            "onlinePay": false, //是否在线支付
+            "cargoes": [
+                {
+                    "id": "5d2c3616b16e6300102d3b3e",
+                    "uid": "5d2bd68ae4b0dc3282ebe13e",//主账号id
+                    "ttmsOrderId": "5d2c3616b16e6300102d3ab8",//运单id
+                    "number": null, //货物号,即创建订单时的cargoNumber字段
+                    "name": "MacBook Pro", //货物名称
+                    "quantity": 8, //数量
+                    "weight": null, //质量
+                    "volume": null, //体积
+                    "value": 468.89, //货物价值
+                    "productModel": "", //备注
+                    "note1": "", //自定义备注1
+                    "note2": "", //自定义备注2
+                    "note3": "", //自定义备注3
+                    "note4": "", //自定义备注4
+                    "note5": "", //自定义备注5
+                    "note6": "", //自定义备注6
+                    "created": 1563178517 //创建时间
+                }
+            ]
         }
     ]
 }
@@ -334,6 +470,7 @@
 | `timeType` | 否 | `string` | 查询时间类型,created录入时间,deliveryed提货时间,appointArrived预约提货时间,signed签收时间 |
 | `startDate` | 否 | `string` | 起始时间,格式"yyyy-MM-dd HH:mm:ss" |
 | `endDate` | 否 | `string` | 结束时间,格式"yyyy-MM-dd HH:mm:ss" |
+| `orderNumber` | 否 | `string` | TMS运单号 |
 | `customerOrderNumber` | 否 | `string` | 客户单号 |
 | `packNumber` | 否 | `string` | 车次号 |
 | `consignerName` | 否 | `string` | 发货人姓名,模糊搜索 |
@@ -794,7 +931,6 @@
 | `volume` | 否 | `String` | 体积  |
 | `quantity` | 否 | `String` | 件数  |
 | `value` | 否 | `String` | 货值  |
-| `status` | 否 | `String` | 货物状态  |
 | `name` | 否 | `String` | 货物名称  |
 | `productModel` | 否 | `String` | 货物备注  |
 
@@ -836,7 +972,6 @@
 | `volume` | 否 | `String` | 体积  |
 | `quantity` | 否 | `String` | 件数  |
 | `value` | 否 | `String` | 货值  |
-| `status` | 否 | `String` | 货物状态  |
 | `name` | 否 | `String` | 货物名称  |
 | `productModel` | 否 | `String` | 货物备注  |
 
@@ -1316,7 +1451,7 @@
 
 **需要认证:** 是
 
-**调用频率限制:** 1秒最多一次,超过会提示操作频繁
+**调用频率限制:** 一小时内最多调用一万次,超过会提示操作频繁
 
 **请求参数:**
 
@@ -1658,7 +1793,6 @@ OrderEntity结构如下:
             orderNumber (string) //订单号 ,
             productModel (string) //货物备注 ,
             quantity (string) //件数 ,
-            status (string) //货物状态 ,
             value (string) //货值 ,
             volume (string) //体积 ,
             weight (string) //重量
@@ -1721,7 +1855,6 @@ CustomerOrderEntity结构如下:
             note6 (string) //自定义备注6 ,
             productModel (string) //货物备注 ,
             quantity (string) //件数 ,
-            status (string) //货物状态 ,
             value (string) //货值 ,
             volume (string) //体积 ,
             weight (string) //重量