From 0af309bd27ded80b2e0266566d18b46e376b24fd Mon Sep 17 00:00:00 2001 From: chenjinsong <523037378@qq.com> Date: Thu, 1 Sep 2022 11:05:29 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E5=AE=9E=E4=BD=93?= =?UTF-8?q?=E5=88=97=E8=A1=A8=E5=B1=95=E5=BC=80=E5=90=8E=E7=82=B9=E5=87=BB?= =?UTF-8?q?=E5=A4=96=E9=83=A8=E6=97=A0=E6=B3=95=E6=94=B6=E5=9B=9E=E7=9A=84?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/detections/DetectionList.vue | 6 +++++- src/views/entityExplorer/entityList/EntityList.vue | 6 +++++- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/views/detections/DetectionList.vue b/src/views/detections/DetectionList.vue index 30da9f47..c6508b83 100644 --- a/src/views/detections/DetectionList.vue +++ b/src/views/detections/DetectionList.vue @@ -66,7 +66,11 @@ export default { }, collapse () { this.isCollapse = true - this.$refs[`detectionRow${this.collapseIndex}`].collapse() + if (this.$refs[`detectionRow${this.collapseIndex}`] && this.$refs[`detectionRow${this.collapseIndex}`].collapse) { + this.$refs[`detectionRow${this.collapseIndex}`].collapse() + } else { + this.$refs[`detectionRow${this.collapseIndex}`][0].collapse() + } }, handleScroll (e) { if (e.target.className === 'cn-detection__shadow') { diff --git a/src/views/entityExplorer/entityList/EntityList.vue b/src/views/entityExplorer/entityList/EntityList.vue index b149a9a6..4232e3d2 100644 --- a/src/views/entityExplorer/entityList/EntityList.vue +++ b/src/views/entityExplorer/entityList/EntityList.vue @@ -95,7 +95,11 @@ export default { }, collapse () { this.isCollapse = true - this.$refs[`entityRow${this.collapseIndex}`].collapse() + if (this.$refs[`entityRow${this.collapseIndex}`] && this.$refs[`entityRow${this.collapseIndex}`].collapse) { + this.$refs[`entityRow${this.collapseIndex}`].collapse() + } else { + this.$refs[`entityRow${this.collapseIndex}`][0].collapse() + } }, pageNo (val) { this.$emit('pageNo', val)