diff --git a/manager/src/views/sys/setting-manage/setting/LOGISTICS_SETTING.vue b/manager/src/views/sys/setting-manage/setting/LOGISTICS_SETTING.vue index fda005fe..98a154a8 100644 --- a/manager/src/views/sys/setting-manage/setting/LOGISTICS_SETTING.vue +++ b/manager/src/views/sys/setting-manage/setting/LOGISTICS_SETTING.vue @@ -5,21 +5,40 @@ 快递鸟 快递100 + 顺丰 - + - + - + - + +
+ + + + + + + + + + + + + + + + +
@@ -36,12 +55,13 @@ export default { formValidate: { // 表单数据 type: "", kdniaoEbusinessID: "", - kdniaoAppKey: "" , - kuaidi100Customer: "" , - kuaidi100Key: "" ,}, + kdniaoAppKey: "", + kuaidi100Customer: "", + kuaidi100Key: "", + }, }; }, - props: ["res",'type'], + props: ["res", 'type'], created() { this.init(); }, @@ -49,7 +69,7 @@ export default { // 验证 submit(name) { let that = this; - if( handleSubmit(that, name )){ + if (handleSubmit(that, name)) { this.setupSetting() } }, @@ -83,15 +103,17 @@ export default { +} diff --git a/seller/src/api/logistics.js b/seller/src/api/logistics.js index a74a861a..c0d7da8b 100644 --- a/seller/src/api/logistics.js +++ b/seller/src/api/logistics.js @@ -4,6 +4,7 @@ import { postRequest, putRequest, deleteRequest, + getRequestHasHeader, importRequest, getRequestWithNoToken } from "@/libs/axios"; @@ -35,4 +36,13 @@ export const getCheckedOn = params =>{ return getRequest(`/other/logistics/getCheckedFaceSheet`,params); } +//获取物流设置 +export const getLogisticsSetting = () =>{ + return getRequest(`/other/logistics/setting`); +} + +export const getShunFengFaceSheet = (url,headers) =>{ + return getRequestHasHeader(`${url}`,null,headers); +} + diff --git a/seller/src/api/order.js b/seller/src/api/order.js index ff709b67..0b20ac0f 100644 --- a/seller/src/api/order.js +++ b/seller/src/api/order.js @@ -81,6 +81,11 @@ export const orderDelivery = (sn, params) => { return postRequest(`/order/order/${sn}/delivery`, params); }; +// 订单发货 +export const orderShunFengDelivery = (sn) => { + return postRequest(`/order/order/${sn}/shunfeng/delivery`); +}; + // 获取商家选中的物流公司 export const getLogisticsChecked = () => { return getRequest(`/other/logistics/getChecked`); diff --git a/seller/src/libs/axios.js b/seller/src/libs/axios.js index 7642288c..031a79db 100644 --- a/seller/src/libs/axios.js +++ b/seller/src/libs/axios.js @@ -188,6 +188,38 @@ export const getRequest = (url, params, resBlob) => { return service(data); }; +export const getRequestHasHeader = (url, params, headers) => { + let accessToken = getStore("accessToken"); + let data = { + method: "get", + url: `${url}`, + params: params, + transformRequest: headers + ? undefined + : [ + function(data) { + let ret = ""; + for (let it in data) { + ret += + encodeURIComponent(it) + + "=" + + encodeURIComponent(data[it]) + + "&"; + } + ret = ret.substring(0, ret.length - 1); + return ret; + } + ], + headers: { + "Content-Type": "application/x-www-form-urlencoded", + accessToken: accessToken, + ...headers + }, + responseType: "blob" + }; + return service(data); +}; + export const postRequest = (url, params, headers) => { let accessToken = getStore("accessToken"); return service({ diff --git a/seller/src/views/order/order/orderDetail.vue b/seller/src/views/order/order/orderDetail.vue index cef64414..ddc012bb 100644 --- a/seller/src/views/order/order/orderDetail.vue +++ b/seller/src/views/order/order/orderDetail.vue @@ -2,179 +2,154 @@