Showing
3 changed files
with
61 additions
and
54 deletions
| ... | @@ -228,9 +228,9 @@ | ... | @@ -228,9 +228,9 @@ |
| 228 | </div> | 228 | </div> |
| 229 | </TablePopover> | 229 | </TablePopover> |
| 230 | </template> | 230 | </template> |
| 231 | - <template v-slot:billNo="scope"> | 231 | + <template v-slot:logisticsNo="scope"> |
| 232 | <el-button type="text" @click="view(scope.row)"> | 232 | <el-button type="text" @click="view(scope.row)"> |
| 233 | - {{ scope.row.billNo }} | 233 | + {{ scope.row.logisticsNo }} |
| 234 | </el-button> | 234 | </el-button> |
| 235 | </template> | 235 | </template> |
| 236 | </Table> | 236 | </Table> |
| ... | @@ -276,15 +276,15 @@ export default { | ... | @@ -276,15 +276,15 @@ export default { |
| 276 | slot: true, | 276 | slot: true, |
| 277 | }, | 277 | }, |
| 278 | { | 278 | { |
| 279 | - name: "提运单号", | 279 | + name: "物流运单编号", |
| 280 | - value: "billNo", | 280 | + value: "logisticsNo", |
| 281 | width: "", | 281 | width: "", |
| 282 | align: "left", | 282 | align: "left", |
| 283 | slot: true, | 283 | slot: true, |
| 284 | }, | 284 | }, |
| 285 | { | 285 | { |
| 286 | - name: "物流运单编号", | 286 | + name: "提运单号", |
| 287 | - value: "logisticsNo", | 287 | + value: "billNo", |
| 288 | width: "", | 288 | width: "", |
| 289 | align: "left", | 289 | align: "left", |
| 290 | }, | 290 | }, | ... | ... |
| ... | @@ -8,7 +8,8 @@ | ... | @@ -8,7 +8,8 @@ |
| 8 | :close-on-click-modal="false" | 8 | :close-on-click-modal="false" |
| 9 | > | 9 | > |
| 10 | <div> | 10 | <div> |
| 11 | - <el-form class="fedexFormStyle" | 11 | + <el-form |
| 12 | + class="fedexFormStyle" | ||
| 12 | ref="selectTemplateForm" | 13 | ref="selectTemplateForm" |
| 13 | :model="selectTemplateFormData" | 14 | :model="selectTemplateFormData" |
| 14 | :rules="selectTemplateFormRules" | 15 | :rules="selectTemplateFormRules" |
| ... | @@ -37,69 +38,71 @@ | ... | @@ -37,69 +38,71 @@ |
| 37 | class="entrySaveButton entrySaveButton-background revokeSubmitBtn" | 38 | class="entrySaveButton entrySaveButton-background revokeSubmitBtn" |
| 38 | type="primary" | 39 | type="primary" |
| 39 | @click="startDownload" | 40 | @click="startDownload" |
| 40 | - >确定</el-button> | 41 | + >确定</el-button |
| 41 | - <el-button | 42 | + > |
| 42 | - class="entrySaveButton" | 43 | + <el-button class="entrySaveButton" @click="cancelDownload" |
| 43 | - @click="cancelDownload" | 44 | + >关闭</el-button |
| 44 | - >关闭</el-button> | 45 | + > |
| 45 | </div> | 46 | </div> |
| 46 | </el-dialog> | 47 | </el-dialog> |
| 47 | - </template> | 48 | +</template> |
| 48 | 49 | ||
| 49 | - <script> | 50 | +<script> |
| 50 | - export default { | 51 | +export default { |
| 51 | props: { | 52 | props: { |
| 52 | showDialog: { | 53 | showDialog: { |
| 53 | type: Boolean, | 54 | type: Boolean, |
| 54 | default: false, | 55 | default: false, |
| 55 | - } | 56 | + }, |
| 56 | }, | 57 | }, |
| 57 | data() { | 58 | data() { |
| 58 | return { | 59 | return { |
| 59 | - datasExportVisible:false, | 60 | + datasExportVisible: false, |
| 60 | - selectTemplateFormData:{ | 61 | + selectTemplateFormData: { |
| 61 | - dataSource:'' | 62 | + dataSource: "", |
| 62 | }, | 63 | }, |
| 63 | selectTemplateFormRules: { | 64 | selectTemplateFormRules: { |
| 64 | dataSource: [ | 65 | dataSource: [ |
| 65 | - { required: true, message: '请选择模板类型', trigger: 'change' } | 66 | + { required: true, message: "请选择模板类型", trigger: "change" }, |
| 66 | ], | 67 | ], |
| 67 | - } | 68 | + }, |
| 68 | }; | 69 | }; |
| 69 | }, | 70 | }, |
| 70 | watch: { | 71 | watch: { |
| 71 | showDialog(val) { | 72 | showDialog(val) { |
| 72 | if (val) { | 73 | if (val) { |
| 73 | - this.datasExportVisible = val | 74 | + this.datasExportVisible = val; |
| 74 | - this.selectTemplateFormData.dataSource="" | 75 | + this.selectTemplateFormData.dataSource = ""; |
| 75 | } | 76 | } |
| 76 | }, | 77 | }, |
| 77 | }, | 78 | }, |
| 78 | - created() { | 79 | + created() {}, |
| 79 | - }, | ||
| 80 | methods: { | 80 | methods: { |
| 81 | - startDownload(){ | 81 | + startDownload() { |
| 82 | this.$refs.selectTemplateForm.validate((valid) => { | 82 | this.$refs.selectTemplateForm.validate((valid) => { |
| 83 | if (valid) { | 83 | if (valid) { |
| 84 | - this.$emit('startDatasExport', this.selectTemplateFormData.dataSource) | 84 | + this.$emit( |
| 85 | + "startDatasExport", | ||
| 86 | + this.selectTemplateFormData.dataSource | ||
| 87 | + ); | ||
| 85 | } else { | 88 | } else { |
| 86 | return false; | 89 | return false; |
| 87 | } | 90 | } |
| 88 | }); | 91 | }); |
| 89 | }, | 92 | }, |
| 90 | 93 | ||
| 91 | - cancelDownload(){ | 94 | + cancelDownload() { |
| 92 | - this.datasExportVisible = false | 95 | + this.datasExportVisible = false; |
| 93 | - this.selectTemplateFormData.dataSource="" | 96 | + this.selectTemplateFormData.dataSource = ""; |
| 94 | - this.$emit('cancelDatasExport') | 97 | + this.$emit("cancelDatasExport"); |
| 95 | - } | ||
| 96 | }, | 98 | }, |
| 97 | - }; | 99 | + }, |
| 98 | - </script> | 100 | +}; |
| 101 | +</script> | ||
| 99 | 102 | ||
| 100 | - <style lang="scss" scoped> | 103 | +<style lang="scss" scoped> |
| 101 | - @import "@/assets/styles/variables.scss"; | 104 | +@import "@/assets/styles/variables.scss"; |
| 102 | - .modelItem { | 105 | +.modelItem { |
| 103 | width: 100%; | 106 | width: 100%; |
| 104 | .modelItem-title { | 107 | .modelItem-title { |
| 105 | display: flex; | 108 | display: flex; |
| ... | @@ -109,12 +112,11 @@ | ... | @@ -109,12 +112,11 @@ |
| 109 | font-weight: 600; | 112 | font-weight: 600; |
| 110 | color: #333; | 113 | color: #333; |
| 111 | } | 114 | } |
| 112 | - } | 115 | +} |
| 113 | - .revokeOperation{ | 116 | +.revokeOperation { |
| 114 | - margin-bottom:25px; | 117 | + margin-bottom: 25px; |
| 115 | - .revokeSubmitBtn{ | 118 | + .revokeSubmitBtn { |
| 116 | margin-right: 30px; | 119 | margin-right: 30px; |
| 117 | } | 120 | } |
| 118 | - } | ||
| 119 | - </style> | ||
| 120 | - | ||
| ... | \ No newline at end of file | ... | \ No newline at end of file |
| 121 | +} | ||
| 122 | +</style> | ... | ... |
| ... | @@ -1057,22 +1057,23 @@ export default { | ... | @@ -1057,22 +1057,23 @@ export default { |
| 1057 | 1057 | ||
| 1058 | datasDownload(dataSource) { | 1058 | datasDownload(dataSource) { |
| 1059 | let obj = { | 1059 | let obj = { |
| 1060 | - billNo: this.sreachFormData.billNo, | 1060 | + // billNo: this.sreachFormData.billNo, |
| 1061 | declareId: [], | 1061 | declareId: [], |
| 1062 | - logisticsNo: this.sreachFormData.logisticsNo, | 1062 | + // logisticsNo: this.sreachFormData.logisticsNo, |
| 1063 | - orderNo: this.sreachFormData.orderNo, | 1063 | + // orderNo: this.sreachFormData.orderNo, |
| 1064 | - receiptStatus: this.sreachFormData.receiptStatus, | 1064 | + // receiptStatus: this.sreachFormData.receiptStatus, |
| 1065 | - dataSource, | 1065 | + dataSourceTemplate: dataSource, |
| 1066 | + ...this.sreachFormData, | ||
| 1066 | }; | 1067 | }; |
| 1068 | + console.log("obj===", obj, dataSource); | ||
| 1069 | + | ||
| 1067 | obj.startCreateTime = ""; | 1070 | obj.startCreateTime = ""; |
| 1068 | obj.endCreateTime = ""; | 1071 | obj.endCreateTime = ""; |
| 1069 | if (this.sreachFormData.createTime.length > 0) { | 1072 | if (this.sreachFormData.createTime.length > 0) { |
| 1070 | - obj.startCreateTime = this.sreachFormData.createTime[0]; | 1073 | + obj.startCreateTime = obj.createTime[0]; |
| 1071 | - obj.endCreateTime = this.sreachFormData.createTime[1]; | 1074 | + obj.endCreateTime = obj.createTime[1]; |
| 1072 | } | 1075 | } |
| 1073 | - this.selected.forEach((item) => { | 1076 | + obj.declareId = this.selected.map((item) => item.declareId); |
| 1074 | - obj.declareId.push(item.declareId); | ||
| 1075 | - }); | ||
| 1076 | exportDeclareData(obj) | 1077 | exportDeclareData(obj) |
| 1077 | .then((res) => { | 1078 | .then((res) => { |
| 1078 | // if (res.code === "200") { | 1079 | // if (res.code === "200") { |
| ... | @@ -1094,6 +1095,10 @@ export default { | ... | @@ -1094,6 +1095,10 @@ export default { |
| 1094 | }, | 1095 | }, |
| 1095 | //导出 | 1096 | //导出 |
| 1096 | downloadData() { | 1097 | downloadData() { |
| 1098 | + if (!this.selected.length) { | ||
| 1099 | + this.alertWarningMsg("请选择数据!"); | ||
| 1100 | + return; | ||
| 1101 | + } | ||
| 1097 | this.loadings.exportDeclareLoading = true; | 1102 | this.loadings.exportDeclareLoading = true; |
| 1098 | this.$store | 1103 | this.$store |
| 1099 | .dispatch("GetInfo") | 1104 | .dispatch("GetInfo") | ... | ... |
-
Please register or login to post a comment