From f3a3778452db22d9c308a0176829103596eae6d0 Mon Sep 17 00:00:00 2001 From: fengerli <528575642@qq.com> Date: Wed, 16 Jul 2025 09:42:51 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=9F=E8=83=BD=E7=BB=86=E8=8A=82=E8=B0=83?= =?UTF-8?q?=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/common/index/index.vue | 16 ++++++++++++---- pages/common/operatingInstruct/index.vue | 2 +- pages/common/operationVideo/index.vue | 15 ++++++++++++--- pages/common/productDes/index.vue | 2 +- 4 files changed, 26 insertions(+), 9 deletions(-) diff --git a/pages/common/index/index.vue b/pages/common/index/index.vue index fcc25ea..2632008 100644 --- a/pages/common/index/index.vue +++ b/pages/common/index/index.vue @@ -61,7 +61,7 @@ - + @@ -77,12 +77,13 @@ - + 设备名称 - + @@ -166,8 +167,10 @@ closePopup(type) { if (type === 'delete') { this.deleteShow = false; + uni.showTabBar(); // 显示TabBar } else if (type === 'rename') { this.RenameModel = false; + uni.showTabBar(); // 显示TabBar } }, // tab导航切换栏 @@ -265,10 +268,11 @@ }, // 右滑点击事件处理 handleSwipeClick(e, item, index) { + const { content } = e - console.log(e, 'eeeee'); + console.log(item, 'eeeee'); switch (e.content.text) { case '删除': this.handleDeleteDevice(item, index) @@ -301,6 +305,8 @@ this.onIntall(); }, 500); this.deleteShow = false + // 关闭所有滑动项 + this.$refs.swipeAction.closeAll(); } else { uni.showToast({ title: res.msg, @@ -334,6 +340,8 @@ }, 500); this.RenameModel = false this.deviceName = '' + // 关闭所有滑动项 + this.$refs.swipeAction.closeAll(); } else { uni.showToast({ title: res.msg, diff --git a/pages/common/operatingInstruct/index.vue b/pages/common/operatingInstruct/index.vue index 4900466..6d35941 100644 --- a/pages/common/operatingInstruct/index.vue +++ b/pages/common/operatingInstruct/index.vue @@ -139,7 +139,7 @@ // 获取图片列表 callOtherApi() { let data = { - deviceId: this.deviceID, + businessId: this.deviceID, fileType: '1' //文件类型(1:操作说明,2:产品参数) } fileInfo(data).then((res) => { diff --git a/pages/common/operationVideo/index.vue b/pages/common/operationVideo/index.vue index aaa2779..0c8453f 100644 --- a/pages/common/operationVideo/index.vue +++ b/pages/common/operationVideo/index.vue @@ -4,7 +4,7 @@ - + @@ -86,8 +86,8 @@ // 如果是确认删除操作 if (content.text === '确认删除') { let ids = item.id - let data ={ - ids:item.id + let data = { + ids: item.id } deleteOperationVideo(ids).then((res) => { if (res.code == 200) { @@ -96,6 +96,8 @@ icon: 'success' }); this.getData() + // 关闭所有滑动项 + this.$refs.swipeAction.closeAll(); } else { uni.showToast({ title: res.msg, @@ -164,6 +166,13 @@ }, onShow() { this.getData() + // 关闭所有滑动项 + // 使用$nextTick确保组件已渲染 + this.$nextTick(() => { + if (this.$refs.swipeAction) { + this.$refs.swipeAction.closeAll(); + } + }); }, onLoad(options) { this.deviceID = options.id diff --git a/pages/common/productDes/index.vue b/pages/common/productDes/index.vue index 09ade6a..e1befda 100644 --- a/pages/common/productDes/index.vue +++ b/pages/common/productDes/index.vue @@ -139,7 +139,7 @@ // 获取图片列表 callOtherApi() { let data = { - deviceId: this.deviceID, + businessId: this.deviceID, fileType: '2' //文件类型(1:操作说明,2:产品参数) } fileInfo(data).then((res) => {