From 117dc4cec546f830bc941ea314dcbdb9b370b211 Mon Sep 17 00:00:00 2001
From: liuyg <376836862@qq.com>
Date: Tue, 25 Jan 2022 14:43:11 +0800
Subject: [PATCH] 冲突
---
src/components/map/components/campusBuildingSearch.vue | 53 ++++++++++++++++++++++++++++++++++++-----------------
1 files changed, 36 insertions(+), 17 deletions(-)
diff --git a/src/components/map/components/campusBuildingSearch.vue b/src/components/map/components/campusBuildingSearch.vue
index 6c2dc17..a934afd 100644
--- a/src/components/map/components/campusBuildingSearch.vue
+++ b/src/components/map/components/campusBuildingSearch.vue
@@ -12,7 +12,8 @@
<el-button @click="navigationShow"
class="deblurring"
icon="el-icon-my-path"></el-button>
- <el-button class="deblurring"
+ <el-button @click="fuzzyQuery"
+ class="deblurring"
type="primary"
icon="el-icon-my-search"></el-button>
</el-button-group>
@@ -22,7 +23,7 @@
<li v-for="(item, index) in searchValList"
:key="index"
@click="loadPopup(item)">
- {{item.name}}
+ {{item.mechanismname}}
</li>
</ul>
</div>
@@ -140,6 +141,26 @@
}
},
+ fuzzyQuery () {
+ if (this.searchInput == '') {
+ this.searchValList = []
+ this.searchValShow = false
+
+ this.$message({
+ message: '请输入关键字',
+ type: 'warning'
+ })
+ return
+ }
+ getSearchList({ mechanismName: this.searchInput }).then(res => {
+ if (res.data.data.length > 0) {
+ this.$store.commit('SET_SEARCHPOPUPFLAG', true)
+ this.$store.commit('SET_SEARCHPOPUPLIST', res.data.data)
+ this.searchValShow = false
+ }
+ })
+ },
+
openModelPopup (param) {
var list = []
if (this.$route.path.indexOf('/service') != -1) {
@@ -230,22 +251,20 @@
this.$store.commit('CLEAR_ALL', null)
- var result = param.list
-
- var imgArr = result.tpurl.split(',')
+ var imgArr = param.tpurl.split(',')
this.$store.commit('SET_POPUPBGURL', imgArr[0])
- this.$store.commit('SET_POPUPQRURL', result.codeurl)
- this.$store.commit('SET_POINTPOSITION', [Number(result.jd), Number(result.wd), Number(result.gd), Number(result.heading), Number(result.pitch), Number(result.roll)])
- this.$store.commit('SET_STATENAME', result.mechanismname)
- this.$store.commit('SET_SITENAME', result.address)
- this.$store.commit('SET_TELEPHONE', result.telephone)
- this.$store.commit('SET_INTRODUCETEXT', result.introduce)
- if (result.panoramaurl != '') {
- this.$store.commit('SET_PANORAMAURL', result.panoramaurl)
+ this.$store.commit('SET_POPUPQRURL', param.codeurl)
+ this.$store.commit('SET_POINTPOSITION', [Number(param.jd), Number(param.wd), Number(param.gd), Number(param.heading), Number(param.pitch), Number(param.roll)])
+ this.$store.commit('SET_STATENAME', param.mechanismname)
+ this.$store.commit('SET_SITENAME', param.address)
+ this.$store.commit('SET_TELEPHONE', param.telephone)
+ this.$store.commit('SET_INTRODUCETEXT', param.introduce)
+ if (param.panoramaurl != '') {
+ this.$store.commit('SET_PANORAMAURL', param.panoramaurl)
}
- if (result.videourl && result.videourl != '') {
- this.$store.commit('SET_MONITORURL', result.videourl)
+ if (param.videourl && param.videourl != '') {
+ this.$store.commit('SET_MONITORURL', param.videourl)
}
this.$store.commit('SET_POPUPIMGATLAS', imgArr)
if (param.jx != undefined && param.jx != '') {
@@ -262,9 +281,9 @@
this.$store.commit('SET_LIVELIST', [])
}
- this.newPopup(result)
+ this.newPopup(param)
this.viewer.flyToPosition(
- new this.DC.Position(Number(result.jd), Number(result.wd), 300, Number(result.heading), Number(result.pitch), Number(result.roll)),
+ new this.DC.Position(Number(param.jd), Number(param.wd), 300, Number(param.heading), Number(param.pitch), Number(param.roll)),
() => {
},
--
Gitblit v1.9.3