From aef35e340899f9ccce19ea1f11137dc976aaf1f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E6=9B=B9=E8=BE=89?= <814457906@qq.com> Date: Sun, 29 Jan 2023 15:38:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/system/OperateGoodsInfo/indexjs.js | 12 ------------ src/views/system/goodsCategory/index.vue | 16 +--------------- 2 files changed, 1 insertion(+), 27 deletions(-) diff --git a/src/views/system/OperateGoodsInfo/indexjs.js b/src/views/system/OperateGoodsInfo/indexjs.js index c911fe5..1a33542 100644 --- a/src/views/system/OperateGoodsInfo/indexjs.js +++ b/src/views/system/OperateGoodsInfo/indexjs.js @@ -257,10 +257,6 @@ export default { attributeDetailsSort: null, }, ], }, ]; - // 清空选中的节点 - this.$refs.cascader.$refs.panel.clearCheckedNodes(); - // 设置为空可以让节点不高亮显示 - this.$refs.cascader.$refs.panel.activePath = []; ++this.isResouceShow }, //页面所属护理站 @@ -421,10 +417,6 @@ export default { } this.$modal.msgSuccess("修改成功"); ++this.isResouceShow - // 清空选中的节点 - this.$refs.cascader.$refs.panel.clearCheckedNodes(); - // 设置为空可以让节点不高亮显示 - this.$refs.cascader.$refs.panel.activePath = []; this.open = false; this.getList(); }); @@ -437,10 +429,6 @@ export default { this.$modal.msgSuccess("新增成功"); this.StationName = "请选择所属护理站"; ++this.isResouceShow - // 清空选中的节点 - this.$refs.cascader.$refs.panel.clearCheckedNodes(); - // 设置为空可以让节点不高亮显示 - this.$refs.cascader.$refs.panel.activePath = []; this.open = false; this.getList(); }); diff --git a/src/views/system/goodsCategory/index.vue b/src/views/system/goodsCategory/index.vue index bc0cecf..672fbab 100644 --- a/src/views/system/goodsCategory/index.vue +++ b/src/views/system/goodsCategory/index.vue @@ -428,12 +428,6 @@ export default { // 取消按钮 cancel() { ++this.isResouceShow; - if (this.form.parentId) { - // 清空选中的节点 - this.$refs.cascader.$refs.panel.clearCheckedNodes(); - // 设置为空可以让节点不高亮显示 - this.$refs.cascader.$refs.panel.activePath = []; - } var obj = { pictureUrlList: [] }; if (this.imgone != this.form.goodsCategoryPicture) { obj.pictureUrlList.push(this.form.goodsCategoryPicture); @@ -521,22 +515,14 @@ export default { updatePicture(obj).then((res) => {}); } this.$modal.msgSuccess("修改成功"); - // 清空选中的节点 - this.$refs.cascader.$refs.panel.clearCheckedNodes(); - // 设置为空可以让节点不高亮显示 - this.$refs.cascader.$refs.panel.activePath = []; ++this.isResouceShow; this.open = false; this.getList(); this.info(); - }); + }); } else { addGoodsCategory(this.form).then((response) => { this.$modal.msgSuccess("新增成功"); - // 清空选中的节点 - this.$refs.cascader.$refs.panel.clearCheckedNodes(); - // 设置为空可以让节点不高亮显示 - this.$refs.cascader.$refs.panel.activePath = []; ++this.isResouceShow; this.open = false; this.getList();