dianlixunjian
徐景良 2024-07-27 17:33:52 +08:00
parent 42ad993a04
commit c21fe7a3fd
4 changed files with 7 additions and 4 deletions

View File

@ -80,7 +80,7 @@
// //
function handlerChangePolygonType(data) { function handlerChangePolygonType(data) {
MapboxComponent.value.handlerChangeCounty(currentCounty.value, data); MapboxComponent.value.handlerLoadPolygon(currentCounty.value['code'], data);
} }
</script> </script>

View File

@ -165,7 +165,7 @@ function handlerLoadPolygon(code="",filter=""){
}) })
map.on("click","historyLayerFill",(e)=>{ map.on("click","historyLayerFill",(e)=>{
console.log('eee123',e.features[0].properties)
}) })
if(map.getLayer('heatLayer')){ if(map.getLayer('heatLayer')){
@ -176,8 +176,8 @@ function handlerLoadPolygon(code="",filter=""){
} }
// //
const currentCode = ref("")
async function handlerDealPoint(code=""){ async function handlerDealPoint(code=""){
let sql_filter; let sql_filter;
if(code){ if(code){
sql_filter = "\"countyid\"=\'"+code+"\'"; sql_filter = "\"countyid\"=\'"+code+"\'";
@ -195,7 +195,7 @@ async function handlerDealPoint(code=""){
let feature = { let feature = {
geometry:geometry, geometry:geometry,
properties:{ properties:{
mag:parseFloat((Math.random()*5).toFixed(2)) mag:1
} }
} }
heatdata.features.push(feature); heatdata.features.push(feature);
@ -396,6 +396,7 @@ onMounted(()=>{
defineExpose({ defineExpose({
handlerChangeCounty, // handlerChangeCounty, //
handlerChangeLayerVisible, // handlerChangeLayerVisible, //
handlerLoadPolygon,
}); });
</script> </script>

View File

@ -103,6 +103,7 @@
item.isClick = false; item.isClick = false;
}); });
list.value = data; list.value = data;
} }
onMounted(() => { onMounted(() => {
getOptions(); getOptions();

View File

@ -74,6 +74,7 @@
font-weight: 400; font-weight: 400;
font-size: 13px; font-size: 13px;
color: #7ebbff; color: #7ebbff;
cursor:pointer;
} }
} }
} }