From 0db73aba5f089d6c95edb027ab27030105b04d2e Mon Sep 17 00:00:00 2001 From: joylink_cuiweidong <364937672@qq.com> Date: Tue, 20 Aug 2019 13:21:38 +0800 Subject: [PATCH] =?UTF-8?q?=E5=89=A7=E6=9C=AC=E7=BC=96=E5=88=B6=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E7=BB=93=E6=9E=84=E8=B0=83=E6=95=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/display/scriptRecord/addAction.vue | 97 +++++++----- src/views/display/scriptRecord/getAction.vue | 51 +++++-- src/views/display/tipScriptRecord.vue | 151 ++++++++----------- 3 files changed, 156 insertions(+), 143 deletions(-) diff --git a/src/views/display/scriptRecord/addAction.vue b/src/views/display/scriptRecord/addAction.vue index 2079ded0f..0c48d20d0 100644 --- a/src/views/display/scriptRecord/addAction.vue +++ b/src/views/display/scriptRecord/addAction.vue @@ -1,43 +1,47 @@ diff --git a/src/views/display/scriptRecord/getAction.vue b/src/views/display/scriptRecord/getAction.vue index 6eaf8aa73..250173c47 100644 --- a/src/views/display/scriptRecord/getAction.vue +++ b/src/views/display/scriptRecord/getAction.vue @@ -1,14 +1,14 @@ @@ -137,10 +137,14 @@ }, create(){ this.reloadTable(); + this.$nextTick(function(){ + debugger; + var div = this.$refs['elActionScrollbar'].$refs['wrap']; + div.scrollTop=this.$refs['elActionScrollbar'].wrap.scrollHeight; + }); + }, modifyAction(row){ - // var div = this.$refs['elActionScrollbar'].$refs['wrap']; - // div.scrollTop=this.$refs['elActionScrollbar'].wrap.scrollHeight; this.operateType="modify"; this.buttonName="修改动作" this.$refs.addBehavior.doShow(row); @@ -154,6 +158,10 @@ diff --git a/src/views/display/tipScriptRecord.vue b/src/views/display/tipScriptRecord.vue index 1db46d317..60210617f 100644 --- a/src/views/display/tipScriptRecord.vue +++ b/src/views/display/tipScriptRecord.vue @@ -1,32 +1,18 @@ @@ -64,7 +50,7 @@ }, mounted(){ this.initAutoSaveScript(); - this.shrink(); + // this.shrink(); }, beforeDestroy() { this.clearAutoSave(); @@ -122,12 +108,23 @@ }); }, saveScenesStage() { + + let data=Vue.prototype.$jlmap.$options; + let group=this.$route.query.group; + let dataZoom={scale:data.scaleRate,x:data.offsetX,y:data.offsetY}; saveScriptScenes(this.group).then(resp => { + updateMapLocation(group,dataZoom).then(response=>{ + // this.$message.success('更新定位成功'); + this.$message.success('保存背景成功'); + }).catch(error => { + this.$messageBox(`更新定位失败: ${error.message}`); + }); // this.isSaveStage = false; - this.$message.success('保存背景成功'); + // this.$message.success('保存背景成功'); }).catch(error => { this.$messageBox('保存背景失败!'); }) + }, saveScenesData() { this.isSavingScript=true; @@ -168,14 +165,7 @@ }, saveMaplocation() { - let data=Vue.prototype.$jlmap.$options; - let group=this.$route.query.group; - let dataZoom={scale:data.scaleRate,x:data.offsetX,y:data.offsetY}; - updateMapLocation(group,dataZoom).then(response=>{ - this.$message.success('更新定位成功'); - }).catch(error => { - this.$messageBox(`更新定位失败: ${error.message}`); - }); + } } } @@ -183,12 +173,14 @@