配送商为达达;调用接口为 预下单:https://developers.weixin.qq.com/miniprogram/dev/OpenApiDoc/immediate-delivery/deliver-by-business/preAddOrder.html
同一个shop_order_id ,两次调用 前后间隔 约30 秒
---------------------以下分别为两次调用的参数,和微信返回的 数据;
第一次调用:
postData={"shopid":"dada4d4dcf85f6db450","shop_order_id":"9877828-5-230110104135704893-270-","shop_no":"451593-5846799","delivery_id":"DADA","openid":"oywPK5JTHTyLFXSp8GmQS7Ye8dFw","sender":{"name":"tycho","city":"广州市","address":"海珠区","address_detail":"广州凡科互联网科技股份有限公司","phone":"12312312312","lng":113.257655,"lat":23.095473},"receiver":{"name":"tycho","city":"广东省广州市","address":"海珠区","address_detail":"工业大道北67号凤凰创意产业园5号楼首层广州凡科互联网科技股份有限公司","phone":"12312312312","lng":113.25762,"lat":23.09555},"cargo":{"goods_value":1.0,"goods_height":0.0,"goods_length":0.0,"goods_width":0.0,"goods_weight":2.0,"cargo_first_class":"美食夜宵","cargo_second_class":"香锅/烤鱼","goods_detail":{"goods":[{"good_count":1,"good_name":"测试单门店创建之后是否同步到停用门店","good_price":0.0}]}},"order_info":{"tips":0,"declared_value":0.0},"shop":{"wxa_path":"pages/order/orderDetail","img_url":"https://mmbiz.qpic.cn/mmbiz_png/xxxxxxxxx/0?wx_fmt=png","goods_name":"测试单门店创建之后是否同步到停用门店","goods_count":1},"delivery_sign":"def6fdbb0ca8170db2fb5cd7212ea2d3d7765a2b"};
第一次调用之后,微信返回值: 配送费是8.5元;
res={"resultcode":0,"resultmsg":"","fee":8.5,"deliverfee":8.5,"tips":0,"insurancefee":0,"distance":11,"delivery_token":"Dadacbf51e9dcb83471f95f6691e1185156d","dispatch_duration":120}}
第二次调用: 寄出地址发生变化, 从广州市 的地址变成 北京的地址; 位置变化很大
postData={"shopid":"dada4d4dcf85f6db450","shop_order_id":"9877828-5-230110104135704893-271-","shop_no":"451593-5846799","delivery_id":"DADA","openid":"oywPK5JTHTyLFXSp8GmQS7Ye8dFw","sender":{"name":"tycho","city":"北京市","address":"朝阳区","address_detail":"朝阳区崔各庄乡","phone":"12312312312","lng":116.51380565158411,"lat":40.02830680500291},"receiver":{"name":"tycho","city":"广东省广州市","address":"海珠区","address_detail":"工业大道北67号凤凰创意产业园5号楼首层广州凡科互联网科技股份有限公司","phone":"12312312312","lng":113.25762,"lat":23.09555},"cargo":{"goods_value":1.0,"goods_height":0.0,"goods_length":0.0,"goods_width":0.0,"goods_weight":2.0,"cargo_first_class":"美食夜宵","cargo_second_class":"香锅/烤鱼","goods_detail":{"goods":[{"good_count":1,"good_name":"测试单门店创建之后是否同步到停用门店","good_price":0.0}]}},"order_info":{"tips":0,"declared_value":0.0},"shop":{"wxa_path":"pages/order/orderDetail","img_url":"https://mmbiz.qpic.cn/mmbiz_png/xxxxxxxxx/0?wx_fmt=png","goods_name":"测试单门店创建之后是否同步到停用门店","goods_count":1},"delivery_sign":"0dd5e78263fd5b4f6f087234c05ff906217b6f7e"};
第二次调用返回结果:配送费还是8.5元;
res={"resultcode":0,"resultmsg":"","fee":8.5,"deliverfee":8.5,"tips":0,"insurancefee":0,"distance":11,"delivery_token":"Dada3d2c1b7efd2046b782fbb9e717705ec4","dispatch_duration":120}
两次 调用,寄出地址位置相隔很远,相差很大,收货地址不变,配送费居然都没有变化;
shop_order_id是唯一标识ID,每次下单请使用不同的shop_order_id。
“shop_order_id”:”9877828-5-230110104135704893-270-“
“shop_order_id”:”9877828-5-230110104135704893-271-“
是不是 美团配送、达达 这两个配送商,在 preAddOrder预下单的时候,
1、如果传了参数 shop_no 的话,寄出地址就不会 用sender 参数做为寄出地址,而是用配送商 后台 对应的 shop_no 所设置的地址 ; 对吧?
2、如果不传参数 shop_no 的话,寄出地址 就使用 sender 参数做为寄出地址; 对吧?