Compare commits

..

No commits in common. "b11a1fb79d6c20c5c0eab171c3beb81db466c03f" and "3c28d9cb54004de4ffa72bbaa16515967ce27e05" have entirely different histories.

1 changed files with 28 additions and 37 deletions

View File

@ -905,24 +905,24 @@ const yaosuTotal = ref([
const yaosuList = ref([]); const yaosuList = ref([]);
// //
const yaosuIcon = ref({ const yaosuIcon = ref({
// : { 摄像头: {
// sj: [], sj: [],
// }, },
// : { 体育场所: {
// sj: [], sj: [],
// }, },
// : { 幼儿园: {
// sj: [], sj: [],
// }, },
// : { sj: [] }, 小学: { sj: [] },
// : { sj: [] }, 初中: { sj: [] },
// : { sj: [] }, 高中: { sj: [] },
// : { sj: [] }, 医院: { sj: [] },
// : { sj: [] }, 南孔书院: { sj: [] },
// : { sj: [] }, 养老机构: { sj: [] },
// : { sj: [] }, 汽车充电桩: { sj: [] },
// : { sj: [] }, 卫生服务中心: { sj: [] },
// AED: { sj: [] }, AED: { sj: [] },
}); });
// //
const ylCount = reactive([ const ylCount = reactive([
@ -1076,7 +1076,7 @@ const pagination = reactive({
//------------------------------------------------ //------------------------------------------------
// //
const initMap = () => { const initMap = () => {
map = new BMapGL.Map("map", { minZoom: 8, maxZoom: 20 }); map = new BMapGL.Map("map", { minZoom: 8, maxZoom: 19 });
map.setMapType(BMAP_SATELLITE_MAP); map.setMapType(BMAP_SATELLITE_MAP);
map.enableScrollWheelZoom(true); map.enableScrollWheelZoom(true);
goMapCenter([119.178783, 29.034583], 11); goMapCenter([119.178783, 29.034583], 11);
@ -1094,6 +1094,8 @@ const getXzsj = async () => {
.get("/api/ggfwyth/regionalDivision/getManagerTownDetails") .get("/api/ggfwyth/regionalDivision/getManagerTownDetails")
.then((res) => { .then((res) => {
if (res.code == 200) { if (res.code == 200) {
console.log(JSON.parse(res.data));
mapTown = JSON.parse(res.data); mapTown = JSON.parse(res.data);
} }
}); });
@ -2678,30 +2680,21 @@ const changeys = (name) => {
tooltip = item.tooltip; tooltip = item.tooltip;
} }
}); });
if ( if (name == "摄像头" || name == "AED" || name=='幼儿园' || name=='小学'|| name=='初中' || name=='高中'|| name=='医院') {
name == "摄像头" ||
name == "AED" ||
name == "幼儿园" ||
name == "小学" ||
name == "初中" ||
name == "高中" ||
name == "医院"
) {
getZyys(url, name, img, img_map, tooltip); getZyys(url, name, img, img_map, tooltip);
} }
if (name == "养老机构") { if (name == "养老机构") {
getZyys2(name, img, img_map, tooltip); getZyys2(name, img, img_map, tooltip);
} }
} }
}; };
//线 //线
const getZyys = (url, name, img, img_map, tooltip) => { const getZyys = (url, name, img, img_map, tooltip) => {
http.get(url).then((res) => { http.get(url).then((res) => {
if (res.code == 200) { if (res.code == 200) {
yaosuIcon.value[name] = {}; yaosuIcon.value[name].sj = res.data;
yaosuIcon.value[name]["sj"] = []; yaosuIcon.value[name].sj.forEach((item, index) => {
yaosuIcon.value[name]["sj"] = res.data;
yaosuIcon.value[name]["sj"].forEach((item, index) => {
item.img = img; item.img = img;
item.img_map = img_map; item.img_map = img_map;
item.overlay = null; item.overlay = null;
@ -2734,10 +2727,8 @@ const getZyys = (url, name, img, img_map, tooltip) => {
// //
const getZyys2 = (name, img, img_map, tooltip) => { const getZyys2 = (name, img, img_map, tooltip) => {
if (name == "养老机构") { if (name == "养老机构") {
yaosuIcon.value[name] = {}; yaosuIcon.value[name].sj = ylCount;
yaosuIcon.value[name]["sj"] = []; yaosuIcon.value[name].sj.forEach((item, index) => {
yaosuIcon.value[name]["sj"] = ylCount;
yaosuIcon.value[name]["sj"].forEach((item, index) => {
item.img = img; item.img = img;
item.img_map = img_map; item.img_map = img_map;
item.overlay = null; item.overlay = null;