Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -112,6 +112,8 @@ export default {
|
|||||||
confirmTypeSelect(val) {
|
confirmTypeSelect(val) {
|
||||||
this.status = val?.[0].value
|
this.status = val?.[0].value
|
||||||
this.$nextTick(()=>{
|
this.$nextTick(()=>{
|
||||||
|
this.current = 1,
|
||||||
|
this.list = []
|
||||||
this.getList()
|
this.getList()
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
@@ -153,7 +155,6 @@ export default {
|
|||||||
this.typelist = this.$dict.getDict('fpPrtpStatus').filter((e) => e.dictValue != 5)
|
this.typelist = this.$dict.getDict('fpPrtpStatus').filter((e) => e.dictValue != 5)
|
||||||
this.typelist.unshift({ dictName: '全部类型', dictValue: ''})
|
this.typelist.unshift({ dictName: '全部类型', dictValue: ''})
|
||||||
}
|
}
|
||||||
|
|
||||||
this.status = ''
|
this.status = ''
|
||||||
this.getListInit()
|
this.getListInit()
|
||||||
|
|
||||||
|
|||||||
@@ -32,8 +32,7 @@
|
|||||||
polygons: [],
|
polygons: [],
|
||||||
labels: [],
|
labels: [],
|
||||||
businessName: '',
|
businessName: '',
|
||||||
ops: {
|
ops: {},
|
||||||
},
|
|
||||||
markers: [],
|
markers: [],
|
||||||
isShow: false,
|
isShow: false,
|
||||||
MarkerCluster: null,
|
MarkerCluster: null,
|
||||||
@@ -59,12 +58,15 @@
|
|||||||
|
|
||||||
this.businessName = item.businessName
|
this.businessName = item.businessName
|
||||||
this.isShow = false
|
this.isShow = false
|
||||||
this.map.easeTo({
|
this.map.setCenter(new this.lib.LatLng(item.lat, item.lng))
|
||||||
center: new this.lib.LatLng(item.lat, item.lng),
|
this.map.setZoom(22)
|
||||||
zoom: 17
|
|
||||||
}, {
|
setTimeout(() => {
|
||||||
duration: 2000
|
document.querySelectorAll('.marker').forEach(e => {
|
||||||
})
|
e.classList.remove('marker-active')
|
||||||
|
})
|
||||||
|
document.querySelector(`.marker-${item.id}`).classList.add('marker-active')
|
||||||
|
}, 400)
|
||||||
},
|
},
|
||||||
|
|
||||||
getList (isSearch) {
|
getList (isSearch) {
|
||||||
@@ -115,6 +117,7 @@
|
|||||||
onInit(options) {
|
onInit(options) {
|
||||||
this.content = options.content;
|
this.content = options.content;
|
||||||
this.position = options.position;
|
this.position = options.position;
|
||||||
|
this.markersId = options.markersId
|
||||||
this.customClass = options.customClass
|
this.customClass = options.customClass
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -126,6 +129,9 @@
|
|||||||
createDOM() {
|
createDOM() {
|
||||||
let dom = document.createElement('div');
|
let dom = document.createElement('div');
|
||||||
dom.classList.add(this.customClass || 'marker');
|
dom.classList.add(this.customClass || 'marker');
|
||||||
|
if (this.markersId) {
|
||||||
|
dom.classList.add(this.markersId);
|
||||||
|
}
|
||||||
dom.innerText = this.content;
|
dom.innerText = this.content;
|
||||||
|
|
||||||
// 监听点击事件,实现zoomOnClick
|
// 监听点击事件,实现zoomOnClick
|
||||||
@@ -155,8 +161,6 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// this.config.latlng && map.setCenter(this.config.latlng)
|
|
||||||
|
|
||||||
this.MarkerCluster = new TMap.MarkerCluster({
|
this.MarkerCluster = new TMap.MarkerCluster({
|
||||||
map, gridSize: 60,
|
map, gridSize: 60,
|
||||||
enableDefaultStyle: false, // 关闭默认样式
|
enableDefaultStyle: false, // 关闭默认样式
|
||||||
@@ -166,7 +170,8 @@
|
|||||||
content: `${e.name}`,
|
content: `${e.name}`,
|
||||||
properties: {...e}
|
properties: {...e}
|
||||||
})) || [],
|
})) || [],
|
||||||
zoomOnClick: true
|
zoomOnClick: true,
|
||||||
|
maxZoom: 18
|
||||||
})
|
})
|
||||||
this.setCenter(points.map(e => {
|
this.setCenter(points.map(e => {
|
||||||
return new TMap.LatLng(e.lat, e.lng)
|
return new TMap.LatLng(e.lat, e.lng)
|
||||||
@@ -198,7 +203,7 @@
|
|||||||
} else {
|
} else {
|
||||||
//点标记样式
|
//点标记样式
|
||||||
let {content, id} = item.geometries?.[0] || {},
|
let {content, id} = item.geometries?.[0] || {},
|
||||||
overlay = new ClusterBubble({map, position: item.center, content})
|
overlay = new ClusterBubble({map, position: item.center, content, markersId: `marker-${id}`})
|
||||||
overlay.on('click', () => {
|
overlay.on('click', () => {
|
||||||
uni.navigateTo({
|
uni.navigateTo({
|
||||||
url: `../AppMerchantManage/detail?id=${id}`
|
url: `../AppMerchantManage/detail?id=${id}`
|
||||||
@@ -363,12 +368,14 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
::v-deep.marker {
|
::v-deep.marker {
|
||||||
|
position: relative;
|
||||||
color: #fff;
|
color: #fff;
|
||||||
background: #558BFE;
|
background: #558BFE;
|
||||||
padding: 0 32px;
|
padding: 0 32px;
|
||||||
width: fit-content;
|
width: fit-content;
|
||||||
height: 56px;
|
height: 56px;
|
||||||
border-radius: 52px;
|
border-radius: 52px;
|
||||||
|
z-index: 1;
|
||||||
transform: translate(-50%, -50%);
|
transform: translate(-50%, -50%);
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
@@ -385,6 +392,24 @@
|
|||||||
border: 12px solid transparent;
|
border: 12px solid transparent;
|
||||||
border-top-color: #558BFE;
|
border-top-color: #558BFE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
&.marker-active {
|
||||||
|
z-index: 11;
|
||||||
|
background: red;
|
||||||
|
|
||||||
|
&:before {
|
||||||
|
content: " ";
|
||||||
|
display: block;
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
left: 50%;
|
||||||
|
width: 0;
|
||||||
|
height: 0;
|
||||||
|
transform: translate(-50%, 100%);
|
||||||
|
border: 12px solid transparent;
|
||||||
|
border-top-color: red;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
* {
|
* {
|
||||||
|
|||||||
Reference in New Issue
Block a user