From b7c1ad10e9ea6d05206dceea59131297ad34a804 Mon Sep 17 00:00:00 2001 From: wuteng <419274783@qq.com> Date: Tue, 9 Sep 2025 17:51:28 +0800 Subject: [PATCH] =?UTF-8?q?oms=E5=B7=B2=E6=8E=A5=E5=8D=95=E7=A6=81?= =?UTF-8?q?=E7=94=A8=E4=BF=AE=E6=94=B9,=E5=88=87=E6=8D=A2=E8=BF=90?= =?UTF-8?q?=E5=8D=95=E4=BF=AE=E6=94=B9=E6=95=B0=E6=8D=AE=E5=88=B7=E6=96=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/oms/emisWaybill/OrderRecord.vue | 17 ++++++++++++++++- src/views/oms/emisWaybill/SendOrderbillList.vue | 10 +++++++++- 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/src/views/oms/emisWaybill/OrderRecord.vue b/src/views/oms/emisWaybill/OrderRecord.vue index 4348baa..f69b9aa 100644 --- a/src/views/oms/emisWaybill/OrderRecord.vue +++ b/src/views/oms/emisWaybill/OrderRecord.vue @@ -939,6 +939,7 @@ data() { return time.getTime() < Date.now()-1 * 24 * 3600 * 1000 } }, + lastBillCode: '', // 手动缓存上一次的billCode // 表单校验 rules: { // billCode: [ @@ -1090,7 +1091,21 @@ watch: { deep: true }, }, +activated(){ + this.billCode = this.$route.query.billCode || ''; + // 先判断是否是修改操作 再判断新旧值是否一致 + if(this.$route.query.action=="modify" && this.billCode!=this.lastBillCode && this.lastBillCode){ + const title = '修改:'+this.billCode; + const route = Object.assign({}, this.$route, { title: `${title}` }) + this.$store.dispatch('tagsView/updateVisitedView', route) + this.initData(); + } +}, +deactivated(){ + this.lastBillCode = this.billCode; +}, created() { + this.billCode = this.$route.query.billCode || ''; if(this.$route.query.action=="copyOrder"){ this.action=this.$route.query.action; this.billCode=this.$route.query.billCode; @@ -1098,7 +1113,7 @@ created() { const title = '再来一单'; const route = Object.assign({}, this.$route, { title: `${title}` }) this.$store.dispatch('tagsView/updateVisitedView', route) - + this.initData(); } else if(this.$route.query.action=="modify"){ diff --git a/src/views/oms/emisWaybill/SendOrderbillList.vue b/src/views/oms/emisWaybill/SendOrderbillList.vue index defc963..3820697 100644 --- a/src/views/oms/emisWaybill/SendOrderbillList.vue +++ b/src/views/oms/emisWaybill/SendOrderbillList.vue @@ -239,7 +239,7 @@ plain size="mini" icon="el-icon-edit" - :disabled="single" + :disabled="selectedOrderStatus==1 || single" @click="handleUpdate" >修改 @@ -652,6 +652,8 @@ export default { loading: true, // 选中数组 ids: [], + //选中订单状态 + selectedOrderStatus:null, // 非单个禁用 single: true, // 非多个禁用 @@ -1109,6 +1111,12 @@ export default { this.ids = selection.map(item => item.id) this.single = selection.length!==1 this.multiple = !selection.length + if(!this.single){ + // 选中订单状态 + this.selectedOrderStatus=this.selectionList[0].orderStatus; + }else{ + this.selectedOrderStatus=null; + } }, // 排序 查询字段是表格中字段名字 动态取值排序顺序 handleSortChange(column) {