|
@@ -192,21 +192,20 @@ export default {
|
|
|
carrierName: null,
|
|
|
option: {
|
|
|
// 表格请求数据的地址
|
|
|
- requestUrl: "/api/v1/ams/getSaleOrderInfoes?apiId=408",
|
|
|
+ requestUrl: "",
|
|
|
selectionType: "select",
|
|
|
comparison: "saleNumber",
|
|
|
columnIndexs: [0, 1, 2, 3, 4, 9, 10, 11, 12, 13, 14, 15, 16, 17]
|
|
|
},
|
|
|
option2: {
|
|
|
// 表格请求数据的地址
|
|
|
- requestUrl: "/api/v1/ams/getSaleOrderReportedes?apiId=408",
|
|
|
+ requestUrl: "",
|
|
|
comparison: "saleNumber",
|
|
|
- columnIndexs: [0, 1, 2, 3, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16]
|
|
|
+ columnIndexs: [0, 1, 2, 3, 8, 9, 10, 11, 12, 13, 14, 15, 16]
|
|
|
},
|
|
|
option4: {
|
|
|
// 表格请求数据的地址
|
|
|
- requestUrl:
|
|
|
- "/api/v1/ams/getSaleOrderListBySaleCompanyes?apiId=409&shipperId=1&saleType=1",
|
|
|
+ requestUrl: "",
|
|
|
comparison: "saleNumber",
|
|
|
columnIndexs: [
|
|
|
0,
|
|
@@ -231,7 +230,7 @@ export default {
|
|
|
},
|
|
|
option5: {
|
|
|
// 表格请求数据的地址
|
|
|
- requestUrl: "/api/v1/ams/getSteelOrderDeletedList?apiId=409",
|
|
|
+ requestUrl: "",
|
|
|
comparison: "saleNumber",
|
|
|
columnIndexs: [
|
|
|
0,
|
|
@@ -262,39 +261,62 @@ export default {
|
|
|
if (getCookie("orgCode") == "shouhuokehu") {
|
|
|
this.option.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderInfoes?apiId=408&consigneeSsoId=" +
|
|
|
- getCookie("userId");
|
|
|
+ getCookie("userId") +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option2.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderReportedes?apiId=408&consigneeSsoId=" +
|
|
|
- getCookie("userId");
|
|
|
+ getCookie("userId") +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option4.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderListBySaleCompanyes?apiId=409&shipperId=1&saleType=1&consigneeSsoId=" +
|
|
|
getCookie("userId");
|
|
|
this.option5.requestUrl =
|
|
|
"/api/v1/ams/getSteelOrderDeletedList?apiId=409&consigneeSsoId=" +
|
|
|
- getCookie("userId");
|
|
|
+ getCookie("userId") +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
} else if (getCookie("orgCode") == "xiaoshouyewuyuan") {
|
|
|
this.option.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderInfoes?apiId=408&saler=" +
|
|
|
- getCookie("loginName");
|
|
|
+ getCookie("loginName") +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option2.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderReportedes?apiId=408&saler=" +
|
|
|
- getCookie("loginName");
|
|
|
+ getCookie("loginName") +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option4.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderListBySaleCompanyes?apiId=409&shipperId=1&saleType=1&saler=" +
|
|
|
- getCookie("loginName");
|
|
|
+ getCookie("loginName") +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option5.requestUrl =
|
|
|
"/api/v1/ams/getSteelOrderDeletedList?apiId=409&saler=" +
|
|
|
getCookie("loginName");
|
|
|
} else {
|
|
|
this.option.requestUrl =
|
|
|
- "/api/v1/ams/getSaleOrderInfoes?apiId=408&consigneeSsoId=" + null;
|
|
|
+ "/api/v1/ams/getSaleOrderInfoes?apiId=408&consigneeSsoId=" +
|
|
|
+ null +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option2.requestUrl =
|
|
|
- "/api/v1/ams/getSaleOrderReportedes?apiId=408&consigneeSsoId=" + null;
|
|
|
+ "/api/v1/ams/getSaleOrderReportedes?apiId=408&consigneeSsoId=" +
|
|
|
+ null +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option4.requestUrl =
|
|
|
"/api/v1/ams/getSaleOrderListBySaleCompanyes?apiId=409&shipperId=1&saleType=1&consigneeSsoId=" +
|
|
|
- null;
|
|
|
+ null +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
this.option5.requestUrl =
|
|
|
- "/api/v1/ams/getSteelOrderDeletedList?apiId=409&consigneeSsoId=" + null;
|
|
|
+ "/api/v1/ams/getSteelOrderDeletedList?apiId=409&consigneeSsoId=" +
|
|
|
+ null +
|
|
|
+ "&i=" +
|
|
|
+ new Date();
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
@@ -443,15 +465,27 @@ export default {
|
|
|
this.$message.error("请先选择需要批量上传的销售订单");
|
|
|
return;
|
|
|
}
|
|
|
+ const loading = this.$loading({
|
|
|
+ lock: true,
|
|
|
+ text: "正在努力上传",
|
|
|
+ spinner: "el-icon-loading",
|
|
|
+ background: "rgba(0, 0, 0, 0.7)"
|
|
|
+ });
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/uploadSaleOrderList", this.batchReportList)
|
|
|
.then(res => {
|
|
|
if (res.data.code == "200") {
|
|
|
this.$message.success("上传成功");
|
|
|
this.getRequestUrl();
|
|
|
+ loading.close();
|
|
|
} else {
|
|
|
this.$message.error("上传失败");
|
|
|
+ loading.close();
|
|
|
}
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ this.$message.error("上传失败");
|
|
|
+ loading.close();
|
|
|
});
|
|
|
},
|
|
|
selectionChange(selection) {
|
|
@@ -564,16 +598,27 @@ export default {
|
|
|
center: true
|
|
|
})
|
|
|
.then(() => {
|
|
|
+ const loading = this.$loading({
|
|
|
+ lock: true,
|
|
|
+ text: "正在努力上传",
|
|
|
+ spinner: "el-icon-loading",
|
|
|
+ background: "rgba(0, 0, 0, 0.7)"
|
|
|
+ });
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/uploadSaleOrder?saleOrderId=" + saleOrderId)
|
|
|
.then(res => {
|
|
|
if (res.data.code == "200") {
|
|
|
this.$message.success("上传成功!");
|
|
|
this.getRequestUrl();
|
|
|
+ loading.close();
|
|
|
} else {
|
|
|
this.$message.success("上传失败!");
|
|
|
this.getRequestUrl();
|
|
|
+ loading.close();
|
|
|
}
|
|
|
+ })
|
|
|
+ .catch(() => {
|
|
|
+ loading.close();
|
|
|
});
|
|
|
})
|
|
|
.catch(() => {
|