|
@@ -1,6 +1,10 @@
|
|
|
<template>
|
|
|
<div class="app-container">
|
|
|
<div class="scoped-bg">
|
|
|
+ </div>
|
|
|
+ <div v-if="$route.query.id === '95542fdc-b542-4582-9be2-9ab8005728d3' || $route.query.id === '95542ff1-8176-4267-8344-2aa7f1034ac5'" class="scoped-tab">
|
|
|
+ <div @click="linkChange('95542fdc-b542-4582-9be2-9ab8005728d3')" :class="$route.query.id === '95542fdc-b542-4582-9be2-9ab8005728d3' ? 'op cur' : 'op'">小学</div>
|
|
|
+ <div @click="linkChange('95542ff1-8176-4267-8344-2aa7f1034ac5')" :class="$route.query.id === '95542ff1-8176-4267-8344-2aa7f1034ac5' ? 'op cur' : 'op'">初中</div>
|
|
|
</div>
|
|
|
<!-- https://img2.honglounews.com/20220111024440-5626.png -->
|
|
|
<div v-show="isDeal" :class="isDbShow ? 'scoped-deal-box' : 'scoped-deal-box t2'">
|
|
@@ -150,6 +154,8 @@ export default {
|
|
|
return {
|
|
|
estateList: [],
|
|
|
schoolList: [],
|
|
|
+ medium_school_list: [],
|
|
|
+ small_school_list: [],
|
|
|
areaList: [],
|
|
|
isDbShow: true,
|
|
|
isMapSetShow: false,
|
|
@@ -469,11 +475,29 @@ export default {
|
|
|
item.position = [item.longitude, item.latitude]
|
|
|
})
|
|
|
this.estateList = [...estateList]
|
|
|
- let schoolList = res.school_list || []
|
|
|
- schoolList.map(item => {
|
|
|
- item.position = [item.longitude, item.latitude]
|
|
|
- })
|
|
|
- this.schoolList = [...schoolList]
|
|
|
+
|
|
|
+ const query = this.$route.query
|
|
|
+ if (query.id === '95542fdc-b542-4582-9be2-9ab8005728d3') {
|
|
|
+ let small_school_list = res.small_school_list || []
|
|
|
+ small_school_list.map(item => {
|
|
|
+ item.position = [item.longitude, item.latitude]
|
|
|
+ })
|
|
|
+ this.schoolList = [...small_school_list]
|
|
|
+ } else if (query.id === '95542ff1-8176-4267-8344-2aa7f1034ac5') {
|
|
|
+ let medium_school_list = res.medium_school_list || []
|
|
|
+ medium_school_list.map(item => {
|
|
|
+ item.position = [item.longitude, item.latitude]
|
|
|
+ })
|
|
|
+ this.schoolList = [...medium_school_list]
|
|
|
+ } else {
|
|
|
+ let schoolList = res.school_list || []
|
|
|
+ schoolList.map(item => {
|
|
|
+ item.position = [item.longitude, item.latitude]
|
|
|
+ })
|
|
|
+ this.schoolList = [...schoolList]
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
let areaList = res.area_total || []
|
|
|
areaList.map(item => {
|
|
|
let lnglatArr = arrToObj(this.dictData.map_area_lnglat)[item.area_type].split(',')
|
|
@@ -485,6 +509,15 @@ export default {
|
|
|
},
|
|
|
mounted() {},
|
|
|
methods: {
|
|
|
+ linkChange (str) {
|
|
|
+ const query = this.$route.query
|
|
|
+ if (query.e) {
|
|
|
+ this.$router.push(`/map/dtl?e=${query.e}&id=${str}`)
|
|
|
+ } else {
|
|
|
+ this.$router.push(`/map/dtl?id=${str}`)
|
|
|
+ }
|
|
|
+ this.$router.go(0)
|
|
|
+ },
|
|
|
setShowChange () {
|
|
|
this.isMapSetShow = !this.isMapSetShow
|
|
|
},
|
|
@@ -942,4 +975,31 @@ export default {
|
|
|
bottom: 0;
|
|
|
}
|
|
|
|
|
|
+
|
|
|
+.scoped-tab {
|
|
|
+ position: fixed;
|
|
|
+ right: 0;
|
|
|
+ top: 50%;
|
|
|
+ background: #fff;
|
|
|
+ z-index: 9999999;
|
|
|
+ cursor: pointer;
|
|
|
+ padding: 10px;
|
|
|
+ border-radius: 20px 0 0 20px;
|
|
|
+ box-shadow: 0 0 10px #ccc;
|
|
|
+ .op {
|
|
|
+ color: #313131;
|
|
|
+ height: 30px;
|
|
|
+ line-height: 30px;
|
|
|
+ padding: 0 2px;
|
|
|
+ font-size: 14px;
|
|
|
+ &:last-child {
|
|
|
+ border-top: 1px solid #dcdcdc;
|
|
|
+ }
|
|
|
+ &.cur {
|
|
|
+ color: #409eff;
|
|
|
+ font-weight: bold;
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
</style>
|