From b7d2f7946221657cdc47c0c64fb551c7614f8693 Mon Sep 17 00:00:00 2001 From: ival <610568032@qq.com> Date: Thu, 8 Apr 2021 08:55:36 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/iscs_new/iscsDraw/index.vue | 22 +++++++++++++++++++--- 1 file changed, 19 insertions(+), 3 deletions(-) diff --git a/src/views/iscs_new/iscsDraw/index.vue b/src/views/iscs_new/iscsDraw/index.vue index 674e41902..e8e94ad8c 100644 --- a/src/views/iscs_new/iscsDraw/index.vue +++ b/src/views/iscs_new/iscsDraw/index.vue @@ -22,7 +22,8 @@
添加 - 删除 + 修改 + 删除 取消
@@ -131,8 +132,23 @@ export default { } }); }, - deleteDevice(){ - + onModify() { + let that=this; + that.$refs['dataform'+that.enabledTab][0].$refs['form'].validate((valid) => { + if (valid) { + let model = that.$refs['dataform'+that.enabledTab][0].formModel; + this.$refs.iscsCanvas.doAction([{model, action: {shapeType: shapeType.Element, order: orders.UPDATE}}]); + } + }); + }, + onDelete(){ + let that=this; + that.$refs['dataform'+that.enabledTab][0].$refs['form'].validate((valid) => { + if (valid) { + let model = that.$refs['dataform'+that.enabledTab][0].formModel; + this.$refs.iscsCanvas.doAction([{model, action: {shapeType: shapeType.Element, order: orders.DELETE}}]); + } + }); }, initPage(){