|
@@ -15,13 +15,16 @@
|
|
|
<el-button type="primary" @click="batchReport">
|
|
|
<i class="upload2"></i>批量上传
|
|
|
</el-button>
|
|
|
+ <el-button type="primary" @click="exportData()"
|
|
|
+ ><i class="el-icon-download"></i>导出(Excel)</el-button
|
|
|
+ >
|
|
|
</div>
|
|
|
<el-tabs v-model="activeName" @tab-click="handleClick">
|
|
|
<!-- 未上报 -->
|
|
|
<el-tab-pane label="未上报" name="first">
|
|
|
<mergeRowTable
|
|
|
v-bind.sync="option"
|
|
|
- ref="table3"
|
|
|
+ ref="excelDom"
|
|
|
@selection-change="selectionChange"
|
|
|
>
|
|
|
<el-table-column
|
|
@@ -73,6 +76,7 @@ export default {
|
|
|
return {
|
|
|
batchReportList: [],
|
|
|
activeName: "first",
|
|
|
+ tableTitle: "未上传销售订单报表",
|
|
|
drawer: false,
|
|
|
input: "",
|
|
|
index: "",
|
|
@@ -82,19 +86,26 @@ export default {
|
|
|
// 表格请求数据的地址
|
|
|
requestUrl: "/api/v1/ams/getSaleOrderInfoes?apiId=408",
|
|
|
selectionType: "select",
|
|
|
+<<<<<<< HEAD
|
|
|
comparison: "saleNumber",
|
|
|
columnIndexs: [0, 1, 2, 3, 4, 8, 9, 10, 11, 12, 13, 14, 15]
|
|
|
+=======
|
|
|
+>>>>>>> f2150ab3172b86585a09574acc2db8baa1c3db03
|
|
|
},
|
|
|
option2: {
|
|
|
// 表格请求数据的地址
|
|
|
requestUrl: "/api/v1/ams/getSaleOrderReportedes?apiId=408",
|
|
|
+<<<<<<< HEAD
|
|
|
comparison: "saleNumber",
|
|
|
columnIndexs: [0, 1, 2, 3, 7, 8, 9, 10, 11, 12, 13, 14, 15]
|
|
|
+=======
|
|
|
+>>>>>>> f2150ab3172b86585a09574acc2db8baa1c3db03
|
|
|
},
|
|
|
option4: {
|
|
|
// 表格请求数据的地址
|
|
|
requestUrl:
|
|
|
"/api/v1/ams/getSaleOrderListBySaleCompanyes?apiId=409&shipperId=1&saleType=1",
|
|
|
+<<<<<<< HEAD
|
|
|
comparison: "saleNumber",
|
|
|
columnIndexs: [
|
|
|
0,
|
|
@@ -115,6 +126,8 @@ export default {
|
|
|
18,
|
|
|
20
|
|
|
]
|
|
|
+=======
|
|
|
+>>>>>>> f2150ab3172b86585a09574acc2db8baa1c3db03
|
|
|
},
|
|
|
mapList: [],
|
|
|
mapItemList: [],
|
|
@@ -138,23 +151,23 @@ export default {
|
|
|
{
|
|
|
prop: "materialName",
|
|
|
label: "物资名称",
|
|
|
- width: 150
|
|
|
+ width: 150,
|
|
|
},
|
|
|
{
|
|
|
prop: "specificationModel",
|
|
|
label: "规格型号",
|
|
|
- width: 150
|
|
|
+ width: 150,
|
|
|
},
|
|
|
{
|
|
|
prop: "materialNumber",
|
|
|
label: "物资件数",
|
|
|
- width: 100
|
|
|
+ width: 100,
|
|
|
},
|
|
|
{
|
|
|
prop: "materialWeight",
|
|
|
label: "物资重量",
|
|
|
- width: 100
|
|
|
- }
|
|
|
+ width: 100,
|
|
|
+ },
|
|
|
],
|
|
|
//(销售公司已审批)
|
|
|
tableData: [],
|
|
@@ -163,7 +176,7 @@ export default {
|
|
|
//(已上报)
|
|
|
tableData2: [],
|
|
|
//(未上报)
|
|
|
- tableData3: []
|
|
|
+ tableData3: [],
|
|
|
};
|
|
|
},
|
|
|
created() {
|
|
@@ -230,7 +243,7 @@ export default {
|
|
|
}
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/uploadSaleOrderList", this.batchReportList)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
if (res.data.code == "200") {
|
|
|
this.$message.success("上传成功");
|
|
|
this.getRequestUrl();
|
|
@@ -335,7 +348,7 @@ export default {
|
|
|
// 根据销售订单id查询物资信息
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/getSaleMaterialList?saleOrderId=" + row.saleOrderId)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
this.tableData = res.data.data;
|
|
|
});
|
|
|
},
|
|
@@ -366,7 +379,7 @@ export default {
|
|
|
// 根据销售订单id查询物资信息
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/getSaleMaterialList?saleOrderId=" + row.saleOrderId)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
this.tableData1 = res.data.data;
|
|
|
});
|
|
|
},
|
|
@@ -397,7 +410,7 @@ export default {
|
|
|
// 根据销售订单id查询物资信息
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/getSaleMaterialList?saleOrderId=" + row.saleOrderId)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
this.tableData2 = res.data.data;
|
|
|
});
|
|
|
},
|
|
@@ -409,12 +422,12 @@ export default {
|
|
|
this.oldRowCount3 += 1;
|
|
|
}
|
|
|
// 切换当前详情表
|
|
|
- this.$refs.table3.toggleRowExpansion(row);
|
|
|
+ this.$refs.excelDom.toggleRowExpansion(row);
|
|
|
// 打开前关闭上一个详情表
|
|
|
if (this.oldRow3 != "") {
|
|
|
if (this.oldRow3 != row) {
|
|
|
if (this.oldRowCount3 % 2 === 1) {
|
|
|
- this.$refs.table3.toggleRowExpansion(this.oldRow3);
|
|
|
+ this.$refs.excelDom.toggleRowExpansion(this.oldRow3);
|
|
|
} else {
|
|
|
this.oldRowCount3 = 1;
|
|
|
}
|
|
@@ -428,7 +441,7 @@ export default {
|
|
|
// 根据销售订单id查询物资信息
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/getSaleMaterialList?saleOrderId=" + row.saleOrderId)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
this.tableData3 = res.data.data;
|
|
|
});
|
|
|
},
|
|
@@ -439,12 +452,12 @@ export default {
|
|
|
confirmButtonText: "确定",
|
|
|
cancelButtonText: "取消",
|
|
|
type: "warning",
|
|
|
- center: true
|
|
|
+ center: true,
|
|
|
})
|
|
|
.then(() => {
|
|
|
this.axios
|
|
|
.post("/api/v1/ams/uploadSaleOrder?saleOrderId=" + saleOrderId)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
if (res.data.code == "200") {
|
|
|
this.$message.success("上传成功!");
|
|
|
this.getRequestUrl();
|
|
@@ -457,7 +470,7 @@ export default {
|
|
|
.catch(() => {
|
|
|
this.$message({
|
|
|
type: "info",
|
|
|
- message: "取消上传!"
|
|
|
+ message: "取消上传!",
|
|
|
});
|
|
|
});
|
|
|
},
|
|
@@ -468,7 +481,7 @@ export default {
|
|
|
confirmButtonText: "确定",
|
|
|
cancelButtonText: "取消",
|
|
|
type: "warning",
|
|
|
- center: true
|
|
|
+ center: true,
|
|
|
})
|
|
|
.then(() => {
|
|
|
this.axios
|
|
@@ -476,7 +489,7 @@ export default {
|
|
|
"/api/v1/ams/deleteAmsSaleOrderBySaleOrderId?saleOrderId=" +
|
|
|
saleOrderId
|
|
|
)
|
|
|
- .then(res => {
|
|
|
+ .then((res) => {
|
|
|
if (res.data.code == "200") {
|
|
|
this.$message.success("删除成功");
|
|
|
this.getRequestUrl();
|
|
@@ -489,11 +502,11 @@ export default {
|
|
|
.catch(() => {
|
|
|
this.$message({
|
|
|
type: "info",
|
|
|
- message: "取消删除!"
|
|
|
+ message: "取消删除!",
|
|
|
});
|
|
|
});
|
|
|
- }
|
|
|
- }
|
|
|
+ },
|
|
|
+ },
|
|
|
};
|
|
|
</script>
|
|
|
<style lang="scss" scoped>
|