From d9a80689015d208665ac6162dbdc8bfd0713c702 Mon Sep 17 00:00:00 2001 From: lilu Date: Mon, 27 Mar 2023 09:17:45 +0800 Subject: [PATCH] =?UTF-8?q?=E5=88=86=E5=8D=95=E5=88=A0=E9=99=A4=20+=20?= =?UTF-8?q?=E5=85=B3=E9=97=AD=E6=8F=90=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/MultiTab/MultiTab.vue | 2 +- src/views/main/BookingLedger/detail/index.vue | 15 ++++++++++++--- .../BookingLedger/detail/modules/rightContent.vue | 2 +- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/src/components/MultiTab/MultiTab.vue b/src/components/MultiTab/MultiTab.vue index f7215d8..0452561 100644 --- a/src/components/MultiTab/MultiTab.vue +++ b/src/components/MultiTab/MultiTab.vue @@ -182,7 +182,7 @@ export default { }, watch: { $route: function(newVal) { - console.log(newVal, newVal.query.noOpenTab, this.fullPathList) + // console.log(newVal, newVal.query.noOpenTab, this.fullPathList) if (!newVal.query.noOpenTab) { this.activeKey = newVal.fullPath if (this.fullPathList.indexOf(newVal.fullPath) < 0) { diff --git a/src/views/main/BookingLedger/detail/index.vue b/src/views/main/BookingLedger/detail/index.vue index b616079..a7306ab 100644 --- a/src/views/main/BookingLedger/detail/index.vue +++ b/src/views/main/BookingLedger/detail/index.vue @@ -586,6 +586,7 @@ export default { } }, 200) setTimeout(() => { + // console.log('== 1. 设置主单保存数据 - false ==') this.checkSaveFun({ type: 'details', hasChange: false }) this.inChildLoading = false }, 500) @@ -619,6 +620,7 @@ export default { } }, 200) setTimeout(() => { + // console.log('== 2. 设置主单保存数据 - false ==') this.checkSaveFun({ type: 'details', hasChange: false }) this.inChildLoading = false }, 500) @@ -650,6 +652,7 @@ export default { this.bookingDetails.mblno = '' } setTimeout(() => { + // console.log('== 3. 设置主单保存数据 - false ==') this.checkSaveFun({ type: 'details', hasChange: false }) this.inChildLoading = false }, 500) @@ -663,6 +666,7 @@ export default { this.$forceUpdate() this.init() setTimeout(() => { + // console.log('== 4. 设置主单保存数据 - false ==') this.checkSaveFun({ type: 'details', hasChange: false }) this.inChildLoading = false }, 500) @@ -854,10 +858,11 @@ export default { const $BookingEDIExt = { ...JSON.parse(JSON.stringify(bookingEDIExt)), ...res.data.bookingEDIExt } this.$set(this, 'bookingDetails', { ...this.bookingDetails, ...res.data, ...{ bookingEDIExt: $BookingEDIExt } }) setTimeout(() => { + // console.log('== 5. 设置主单保存数据 - false ==') this.checkSaveFun({ type: 'details', hasChange: false }) this.inChildLoading = false this.$message.success({ content: '加载完成' }) - }, 500) + }, 1200) this.$forceUpdate() }, @@ -884,6 +889,7 @@ export default { changeDetailFun(data) { const { detail, type } = data if (this.ifCompare(this.bookingDetails, detail) && !this.inChildLoading) { + // console.log('== 6. 设置主单有保存数据 - true ==') this.checkSaveFun({ type: 'details', hasChange: true }) } this.bookingDetails = detail @@ -1249,8 +1255,10 @@ export default { if (arr.includes(true)) { this.$set(this.bookingDetails, 'hbList', data) this.checkSaveFun({ type: 'hbList', hasChange: true }) + // console.log('== 分单有修改 ==') } else { this.checkSaveFun({ type: 'hbList', hasChange: false }) + // console.log('== 分单无修改 ==') } }, checkSaveFun(data) { @@ -1266,6 +1274,7 @@ export default { } // const key = this.id const key = this.$route.fullPath + // console.log('== 设置主单保存数据 ==', key, $data) this.$set(lastPages, key, $data) this.setNeedSavePages(lastPages) }, @@ -1380,10 +1389,10 @@ export default { } }, sedOrderRemoveFun(sedData) { - console.log('== 父组件收到子单删除数据 ==', sedData, this.bookingDetails.hbList) + // console.log('== 父组件收到子单删除数据 ==', sedData, this.bookingDetails.hbList) this.$set(this.bookingDetails, 'hbList', sedData) if (sedData.length === 0) { - console.log('== 子单删除完毕 ==') + // console.log('== 子单删除完毕 ==') this.Showtabs = false this.tabActiveKey = '1' } diff --git a/src/views/main/BookingLedger/detail/modules/rightContent.vue b/src/views/main/BookingLedger/detail/modules/rightContent.vue index af829e1..23d6bd4 100644 --- a/src/views/main/BookingLedger/detail/modules/rightContent.vue +++ b/src/views/main/BookingLedger/detail/modules/rightContent.vue @@ -333,7 +333,7 @@ export default { }, computed: { locaService() { - if (!this.details) { + if (!this.details || Object.keys(this.details).length === 0) { return [] } return this.details.item.map((item, index) => {