From 8ca3c7fe1f0476a3e2ea10cf4a7fe7c448e5581d Mon Sep 17 00:00:00 2001 From: hanbaoshan <hanbaoshan@aiotlink.com> Date: 星期四, 03 十二月 2020 15:57:25 +0800 Subject: [PATCH] 数据栈目录树作响应式高度 --- src/components/canvas/Dialog.vue | 15 ++++++++------- 1 files changed, 8 insertions(+), 7 deletions(-) diff --git a/src/components/canvas/Dialog.vue b/src/components/canvas/Dialog.vue index 8245db6..05286c6 100644 --- a/src/components/canvas/Dialog.vue +++ b/src/components/canvas/Dialog.vue @@ -97,11 +97,7 @@ width="960" height="540" :style=" - `position:static;background:url(${ - snapshot_url - ? `/httpImage/${snapshot_url}` - : backImg - }) 0% 0%/960px 540px no-repeat;` + `position:static;background:url(${snapshot_url}) 0% 0%/960px 540px no-repeat;` " ></canvas> <p @@ -222,7 +218,8 @@ cancel() { this.changeType('0') this.undisabled() - this.delCursor = {} + //this.delCursor = {} + this.delCursor = { type: -1, index: -1, remarksName: "", id: "" }; this.canvasHistory.length = 0; this.step = -1; this.canvasData = JSON.parse(JSON.stringify(this.canvasDataToChild)); @@ -540,6 +537,7 @@ _this.type = "0"; _this.delCursor.type = "2"; _this.delCursor.index = i; + debugger _this.delCursor.remarksName = v.name; _this.delCursor.id = v.id; // console.log("褰撳墠閫変腑鍏冪礌锛�",_this.delCursor) @@ -1273,7 +1271,10 @@ this.lineIndex = this.canvasData.line.length; this.rectIndex = this.canvasData.rect.length; this.arrowIndex = this.canvasData.arrow.length; - this.polygonIndex = this.canvasData.polygon.length; + //鎺掗櫎this.canvasData.polygon鍏ㄩ儴鍖哄煙(鍏ㄩ儴鍖哄煙鐨刬d灏辨槸鎽勫儚鏈虹殑id) + + let filterPolygonArr = this.canvasData.polygon.filter(item=>item.id != this.TreeDataPool.selectedNode.id) + this.polygonIndex = filterPolygonArr.length; }, // 鐢熸垚uuid getUuid() { -- Gitblit v1.8.0