//基础功能 // 按钮 function bindPOI(val) { let show; map.control.geocoder.show = val if (val){ show = 1 }else{ show = 0; } let data = "sousuo="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } // 视角复位 function bindView(val) { let show; map.control.homeButton.show = val if (val){ show = 1 }else{ show = 0; } let data = "shijiao="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } // 全屏切换 function bindFullScreen(val) { let show; map.control.fullscreenButton.show = val if (val){ show = 1 }else{ show = 0; } let data = "quanping="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } // 帮助按钮 function bindHelpButton(val) { let show; map.control.navigationHelpButton.show = val if (val){ show = 1 }else{ show = 0; } let data = "bangzhu="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } //缩放 function bindZoom(val) { let show; map.control.zoom.show = val if (val){ show = 1 }else{ show = 0; } let data = "suofang="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } // 面板: // 信息状态栏 function bindLocation(val) { let show; map.control.locationBar.show = val if (val){ show = 1 }else{ show = 0; } let data = "weizhi="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } // 时钟 function bindClock(val) { // map.control.clockAnimate.show = val notify.warning("维护中") } // 时间刻度线 function bindTimeLine(val) { // map.control.timeline.show = val notify.warning("维护中") } // 导航球 function bindNav(val) { let show; map.control.compass.show = val if (val){ show = 1 }else{ show = 0; } let data = "daohang="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } // 比例尺 function bindLegend(val) { let show; map.control.distanceLegend.show = val if (val){ show = 1 }else{ show = 0; } let data = "rule="+show $.post("/hxzkuwb/UpdateHomeSettingShow",data,function (data){ if (data == 1){ notify.success("设置成功") }else{ notify.error("设置失败") } }) } //夜间模式 function bindNight(val) { let show; let maskDiv = document.getElementById("maskDiv") let menu = document.getElementById("Menu"); let bootom = document.getElementById("MenuBootom") let gongjulan = document.getElementsByClassName("YeJian") let gongjulanzi = document.getElementsByClassName("GongJuLanZi") let acd = document.getElementById("acd") let refer = document.getElementById("refer") //刷新 let close = document.getElementById("close") //关闭 let context1 = document.getElementById("context1") //文字 let send = document.getElementById("send")//发送 let borderWhites = document.getElementsByClassName("borderWhites") let whites = document.getElementsByClassName("whites") map.control.distanceLegend.show = val if (val) { show = 1 //替换夜间模式 maskDiv.style.backgroundImage = 'radial-gradient(rgba(139, 138, 138, 0.219) 50%, rgba(1, 1, 1, 0.8) 80%, rgba(17, 16, 16, 0.9) 90%)'; menu.style.backgroundImage = "url('icon/top.png')"; bootom.style.backgroundImage="url('icon/bootom.png')"; for (let i = 0 ; i