Commit 9848af06 authored by mahui's avatar mahui

点聚合加载

parent a314a870
This source diff could not be displayed because it is too large. You can view the blob instead.
<template>
<div>
<div id="allMap"></div>
</div>
</template>
<style>
#allMap {
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
}
#allMap .anchorBL a {
display: none !important;
}
#allMap .BMap_bubble_content {
position: relative !important;
top: 10px !important;
height: 245px !important;
overflow-y: auto !important;
}
#allMap .BMap_bubble_content > p {
line-height: 1em !important;
}
</style>
<script>
export default ({
name: 'mark_map',
data() {
return {
value: '全区',
options: [
{label: '全区', value: '全区'},
{label: '锦城街道', value: '锦城街道'},
{label: '玲珑街道', value: '玲珑街道'},
{label: '锦南街道', value: '锦南街道'},
{label: '板桥镇', value: '板桥镇'},
{label: '锦北街道', value: '锦北街道'},
{label: '青山湖街道', value: '青山湖街道'},
{label: '高虹镇', value: '高虹镇'},
{label: '太湖源镇', value: '太湖源镇'},
{label: '天目山镇', value: '天目山镇'},
{label: '於潜镇', value: '於潜镇'},
{label: '潜川镇', value: '潜川镇'},
{label: '太阳镇', value: '太阳镇'},
{label: '湍口镇', value: '湍口镇'},
{label: '河桥镇', value: '河桥镇'},
{label: '昌化镇', value: '昌化镇'},
{label: '龙岗镇', value: '龙岗镇'},
{label: '岛石镇', value: '岛石镇'},
{label: '清凉峰镇', value: '清凉峰镇'}
],
map: undefined,
keywords: '',
all_data: [],
search_data:[
{
"name":"崇文路-岗阳街",
"company":"大华",
"type":"普通监控",
"longitude":"119.812681",
"latitude":"30.271191",
"pixel":" "
},
{
"name":"塘藤街-崇文路向南",
"company":"大华",
"type":"普通监控",
"longitude":"119.815601",
"latitude":"30.265061",
"pixel":" "
},
{
"name":"大园新城一期",
"company":"大华",
"type":"普通监控",
"longitude":"119.823291",
"latitude":"30.259081",
"pixel":" "
},
{
"name":"浒溪路中间路牌",
"company":"大华",
"type":"普通监控",
"longitude":"119.846971",
"latitude":"30.256651",
"pixel":" "
},
{
"name":"干校路向南空地",
"company":"大华",
"type":"普通监控",
"longitude":"119.795861",
"latitude":"30.317604",
"pixel":" "
},
{
"name":"崇文路-寺前路口",
"company":"大华",
"type":"普通监控",
"longitude":"119.847471",
"latitude":"30.260011",
"pixel":" "
},
{
"name":"阮家山路公交站",
"company":"大华",
"type":"普通监控",
"longitude":"119.815271",
"latitude":"30.296231",
"pixel":" "
},
{
"name":"恒伟科技",
"company":"大华",
"type":"普通监控",
"longitude":"119.824221",
"latitude":"30.267311",
"pixel":" "
},
{
"name":"华立科技工地",
"company":"大华",
"type":"普通监控",
"longitude":"119.772791",
"latitude":"30.309636",
"pixel":" "
},
{
"name":"鸡市线-大康路",
"company":"大华",
"type":"普通监控",
"longitude":"119.793811",
"latitude":"30.312911",
"pixel":" "
},
{
"name":"科技路-阮家山路",
"company":"大华",
"type":"普通监控",
"longitude":"119.817281",
"latitude":"30.295561",
"pixel":" "
},
{
"name":"科教路-麻岭路",
"company":"大华",
"type":"普通监控",
"longitude":"119.820831",
"latitude":"30.298071",
"pixel":" "
},
{
"name":"市地菜场门口",
"company":"大华",
"type":"普通监控",
"longitude":"119.803831",
"latitude":"30.286021",
"pixel":" "
},
{
"name":"崇文路-百家坞",
"company":"大华",
"type":"普通监控",
"longitude":"119.803831",
"latitude":"30.286021",
"pixel":" "
},
{
"name":"鸡市线-余杭岔口",
"company":"大华",
"type":"普通监控",
"longitude":"119.798183",
"latitude":"30.317378",
"pixel":" "
},
{
"name":"原青石水泥厂门口",
"company":"大华",
"type":"普通监控",
"longitude":"119.848111",
"latitude":"30.255681",
"pixel":" "
},
{
"name":"中电海康门口",
"company":"大华",
"type":"普通监控",
"longitude":"119.810211",
"latitude":"30.255681",
"pixel":" "
},
{
"name":"青山-东欣停车场",
"company":"大华",
"type":"普通监控",
"longitude":"119.852903",
"latitude":"30.260012",
"pixel":" "
},
{
"name":"青山湖街道-管委会大楼高空",
"company":"大华",
"type":"普通监控",
"longitude":"119.821189",
"latitude":"30.271761",
"pixel":" "
},
{
"name":"大园路-笑岭隧道南口",
"company":"大华",
"type":"球机",
"longitude":"119.798163",
"latitude":"30.294486",
"pixel":"200万像素"
},
{
"name":"胜联路-电子科技大学门口",
"company":"大华",
"type":"球机",
"longitude":"119.816793",
"latitude":"30.292355",
"pixel":"200万像素"
},
{
"name":"东航大桥-东航大桥北面",
"company":"大华",
"type":"球机",
"longitude":"119.845232",
"latitude":"30.263985",
"pixel":"200万像素"
},
{
"name":"岗阳街158号对面",
"company":"大华",
"type":"球机",
"longitude":"119.821284",
"latitude":"30.274031",
"pixel":"200万像素"
},
{
"name":"钱坞路与大园路路口向西",
"company":"大华",
"type":"球机",
"longitude":"119.818391",
"latitude":"30.279252",
"pixel":"200万像素"
},
{
"name":"励新路国一检测后门",
"company":"大华",
"type":"球机",
"longitude":"119.811707",
"latitude":"30.279037",
"pixel":"200万像素"
},
{
"name":"励新路巨化新材料后门",
"company":"大华",
"type":"球机",
"longitude":"119.812755",
"latitude":"30.277377",
"pixel":"200万像素"
},
{
"name":"励新路-聚贤街",
"company":"大华",
"type":"球机",
"longitude":"119.813353",
"latitude":"30.276399",
"pixel":"200万像素"
},
{
"name":"星港路-吉美瑞生门口",
"company":"大华",
"type":"球机",
"longitude":"119.817953",
"latitude":"30.274143",
"pixel":"200万像素"
},
{
"name":"大园路-市地街",
"company":"大华",
"type":"球机",
"longitude":"119.779137",
"latitude":"30.316288",
"pixel":"200万像素"
},
{
"name":"星港路-星港路628号",
"company":"大华",
"type":"球机",
"longitude":"119.817393",
"latitude":"30.275851",
"pixel":"200万像素"
},
{
"name":"大园路-聚贤街",
"company":"大华",
"type":"球机",
"longitude":"119.820361",
"latitude":"30.277558",
"pixel":"200万像素"
},
{
"name":"活斜线-青南村杨家3号",
"company":"大华",
"type":"球机",
"longitude":"119.835725",
"latitude":"30.228839",
"pixel":"200万像素"
},
{
"name":"天堂花园停车场",
"company":"大华",
"type":"球机",
"longitude":"119.828367",
"latitude":"30.237738",
"pixel":"200万像素"
},
{
"name":"胜联路-科大公园",
"company":"大华",
"type":"球机",
"longitude":"119.820382",
"latitude":"30.290274",
"pixel":"200万像素"
},
{
"name":"大园路-香港大学",
"company":"大华",
"type":"球机",
"longitude":"119.816059",
"latitude":"30.284915",
"pixel":"200万像素"
},
{
"name":"创业路-省科技厅",
"company":"大华",
"type":"球机",
"longitude":"119.823028",
"latitude":"30.271913",
"pixel":"200万像素"
},
{
"name":"相府路-王家山路向北",
"company":"大华",
"type":"球机",
"longitude":"119.857739",
"latitude":"30.270799",
"pixel":"200万像素"
},
{
"name":"科技大道-污水处理厂",
"company":"大华",
"type":"球机",
"longitude":"119.828928",
"latitude":"30.260114",
"pixel":"200万像素"
},
{
"name":"科技大道中三路路口",
"company":"大华",
"type":"球机",
"longitude":"119.834675",
"latitude":"30.259322",
"pixel":"200万像素"
},
{
"name":"大园路-福斯特研究所",
"company":"大华",
"type":"球机",
"longitude":"119.821002",
"latitude":"30.275892",
"pixel":"200万像素"
},
{
"name":"大园路-聚贤街交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.831379",
"latitude":"30.280651",
"pixel":"200万像素"
},
{
"name":"鹤山街-翠紫苑106号对面",
"company":"大华",
"type":"球机",
"longitude":"119.832461",
"latitude":"30.254368",
"pixel":"200万像素"
},
{
"name":"科技大道-浒溪路向西50米",
"company":"大华",
"type":"球机",
"longitude":"119.846239",
"latitude":"30.259607",
"pixel":"200万像素"
},
{
"name":"大园新城北区灵鹤路400号对面",
"company":"大华",
"type":"球机",
"longitude":"119.823231",
"latitude":"30.256389",
"pixel":"200万像素"
},
{
"name":"大园新城南区13号楼顶高空",
"company":"大华",
"type":"球机",
"longitude":"119.825724",
"latitude":"30.256696",
"pixel":"200万像素"
},
{
"name":"大园新城南区4号楼顶高空",
"company":"大华",
"type":"球机",
"longitude":"119.826078",
"latitude":"30.255333",
"pixel":"200万像素"
},
{
"name":"长西线-大园路",
"company":"大华",
"type":"球机",
"longitude":"119.779048",
"latitude":"30.321903",
"pixel":"200万像素"
},
{
"name":"大园路泉口街交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.782734",
"latitude":"30.309126",
"pixel":"200万像素"
},
{
"name":"大康路开源街交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.800133",
"latitude":"30.320378",
"pixel":"200万像素"
},
{
"name":"大康路茶园街交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.798819",
"latitude":"30.321385",
"pixel":"200万像素"
},
{
"name":"大康路市地街交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.785155",
"latitude":"30.320504",
"pixel":"200万像素"
},
{
"name":"市地街平校路交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.791376",
"latitude":"30.323369",
"pixel":"200万像素"
},
{
"name":"开源街平校路交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.792724",
"latitude":"30.320146",
"pixel":"200万像素"
},
{
"name":"开源街-桑园路",
"company":"大华",
"type":"球机",
"longitude":"119.801378",
"latitude":"30.321473",
"pixel":"200万像素"
},
{
"name":"市地公交站",
"company":"大华",
"type":"球机",
"longitude":"119.794308",
"latitude":"30.324763",
"pixel":"200万像素"
},
{
"name":"平校路茶园街交叉口",
"company":"大华",
"type":"球机",
"longitude":"119.791041",
"latitude":"30.321661",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街209号向西",
"company":"大华",
"type":"枪机",
"longitude":"119.814781",
"latitude":"30.247341",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街209号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.814781",
"latitude":"30.247351",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街2020号向西",
"company":"大华",
"type":"枪机",
"longitude":"119.815029",
"latitude":"30.247666",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街2020号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.815031",
"latitude":"30.247681",
"pixel":"200万像素"
},
{
"name":"天柱街-天柱街73号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.827391",
"latitude":"30.255731",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街9号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.823651",
"latitude":"30.249211",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街51号向西",
"company":"大华",
"type":"枪机",
"longitude":"119.821231",
"latitude":"30.248611",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街51号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.821231",
"latitude":"30.248621",
"pixel":"200万像素"
},
{
"name":"干校路-干校路36号向南",
"company":"大华",
"type":"枪机",
"longitude":"119.794841",
"latitude":"30.318591",
"pixel":"200万像素"
},
{
"name":"大康路-泉口街向北",
"company":"大华",
"type":"枪机",
"longitude":"119.791171",
"latitude":"30.315031",
"pixel":"200万像素"
},
{
"name":"市地街-通云路向北",
"company":"大华",
"type":"枪机",
"longitude":"119.783141",
"latitude":"30.319561",
"pixel":"200万像素"
},
{
"name":"市地街-通云路向南",
"company":"大华",
"type":"枪机",
"longitude":"119.783141",
"latitude":"30.319561",
"pixel":"200万像素"
},
{
"name":"大康路-长西线向北",
"company":"大华",
"type":"枪机",
"longitude":"119.784971",
"latitude":"30.321701",
"pixel":"200万像素"
},
{
"name":"大康路-长西线向南",
"company":"大华",
"type":"枪机",
"longitude":"119.784971",
"latitude":"30.321701",
"pixel":"200万像素"
},
{
"name":"相府路-王家山路向北",
"company":"大华",
"type":"枪机",
"longitude":"119.854621",
"latitude":"30.269781",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街169号向西",
"company":"大华",
"type":"枪机",
"longitude":"119.816561",
"latitude":"30.247631",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街169号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.816561",
"latitude":"30.247641",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街51号向西",
"company":"大华",
"type":"枪机",
"longitude":"119.821231",
"latitude":"30.248611",
"pixel":"200万像素"
},
{
"name":"鹤亭街-鹤亭街51号向东",
"company":"大华",
"type":"枪机",
"longitude":"119.821231",
"latitude":"30.248621",
"pixel":"200万像素"
},
{
"name":"鹤亭街-中国银行向西",
"company":"大华",
"type":"枪机",
"longitude":"119.816981",
"latitude":"30.247941",
"pixel":"200万像素"
},
{
"name":"鹤亭街-中国银行向东",
"company":"大华",
"type":"枪机",
"longitude":"119.816981",
"latitude":"30.247941",
"pixel":"200万像素"
},
{
"name":"天柱街-天柱街71号向西",
"company":"大华",
"type":"枪机",
"longitude":"119.828511",
"latitude":"30.256341",
"pixel":"200万像素"
},
{
"name":"活斜线-白纸槽5号向南",
"company":"大华",
"type":"枪机",
"longitude":"119.832401",
"latitude":"30.214521",
"pixel":"200万像素"
},
{
"name":"活斜线-青南村斜阳向东",
"company":"大华",
"type":"枪机",
"longitude":"119.833151",
"latitude":"30.223691",
"pixel":"200万像素"
},
{
"name":"活斜线-青南村桥头向南",
"company":"大华",
"type":"枪机",
"longitude":"119.837081",
"latitude":"30.235861",
"pixel":"200万像素"
},
{
"name":"青研线-天堂花园向北",
"company":"大华",
"type":"枪机",
"longitude":"119.837081",
"latitude":"30.237511",
"pixel":"200万像素"
},
{
"name":"胜联路-电子科技大学门口",
"company":"大华",
"type":"枪机",
"longitude":"119.816791",
"latitude":"30.292361",
"pixel":"200万像素"
},
{
"name":"大园路-香港大学",
"company":"大华",
"type":"枪机",
"longitude":"119.816061",
"latitude":"30.284921",
"pixel":"200万像素"
},
{
"name":"胜联路-科大公园",
"company":"大华",
"type":"枪机",
"longitude":"119.827382",
"latitude":"30.290274",
"pixel":"200万像素"
},
{
"name":"胜联路-科技大学向南",
"company":"大华",
"type":"枪机",
"longitude":"119.823081",
"latitude":"30.292071",
"pixel":"200万像素"
},
{
"name":"创业路-科创大厦向东",
"company":"大华",
"type":"枪机",
"longitude":"119.823551",
"latitude":"30.270301",
"pixel":"200万像素"
},
{
"name":"创业路-省科技厅",
"company":"大华",
"type":"枪机",
"longitude":"119.823031",
"latitude":"30.271911",
"pixel":"200万像素"
},
{
"name":"东航大桥-东面堤坝向东",
"company":"大华",
"type":"枪机",
"longitude":"119.845601",
"latitude":"30.263551",
"pixel":"200万像素"
},
{
"name":"相府路-杭叉门口",
"company":"大华",
"type":"枪机",
"longitude":"119.856881",
"latitude":"30.263771",
"pixel":"200万像素"
},
{
"name":"相府路-杭叉桥对面向南",
"company":"大华",
"type":"枪机",
"longitude":"119.856121",
"latitude":"30.263621",
"pixel":"200万像素"
},
{
"name":"市地街-通云路向北",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.783141",
"latitude":"30.319561",
"pixel":"300万像素"
},
{
"name":"市地街-通云路向南",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.783141",
"latitude":"30.319561",
"pixel":"300万像素"
},
{
"name":"大康路-长西线向北",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.784971",
"latitude":"30.321701",
"pixel":"300万像素"
},
{
"name":"大康路-长西线向南",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.784971",
"latitude":"30.321701",
"pixel":"300万像素"
},
{
"name":"大园路-泉口街向西",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.783811",
"latitude":"30.309381",
"pixel":"300万像素"
},
{
"name":"大园路-泉口街向东",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.783811",
"latitude":"30.309381",
"pixel":"300万像素"
},
{
"name":"滨河路-青鸿达轧钢厂门口向西",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.827751",
"latitude":"30.264121",
"pixel":"300万像素"
},
{
"name":"滨河路-青鸿达轧钢厂门口向东",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.827751",
"latitude":"30.264121",
"pixel":"300万像素"
},
{
"name":"102省道-鑫富药业对面向西1",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.859889",
"latitude":"30.255108",
"pixel":"300万像素"
},
{
"name":"102省道-鑫富药业对面向西",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.859889",
"latitude":"30.255108",
"pixel":"300万像素"
},
{
"name":"102省道-鑫富药业对面非机动车向西",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.859889",
"latitude":"30.255108",
"pixel":"300万像素"
},
{
"name":"102省道-青山高速出口向北",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.841733",
"latitude":"30.254889",
"pixel":"300万像素"
},
{
"name":"102省道-青山高速路口向东3",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.842546",
"latitude":"30.255776",
"pixel":"300万像素"
},
{
"name":"102省道-青山高速路口向东2",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.842546",
"latitude":"30.255775",
"pixel":"300万像素"
},
{
"name":"102省道-青山高速路口向东1",
"company":"大华",
"type":"抓拍一体机",
"longitude":"119.842546",
"latitude":"30.255774",
"pixel":"300万像素"
},
{
"name":"天柱街—青山镇政府",
"company":" ",
"type":"人脸识别",
"longitude":"119.8108805",
"latitude":"30.25067971",
"pixel":" "
},
{
"name":"天柱街—天柱街532号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8114879",
"latitude":"30.25095237",
"pixel":" "
},
{
"name":"天柱街—天柱街508号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8121622",
"latitude":"30.2511062",
"pixel":" "
},
{
"name":"天柱街—青中街西北角",
"company":" ",
"type":"人脸识别",
"longitude":"119.8129618",
"latitude":"30.25128986",
"pixel":" "
},
{
"name":"天柱街—天柱街305号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8137615",
"latitude":"30.25170789",
"pixel":" "
},
{
"name":"天柱街—天柱街352号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8146339",
"latitude":"30.25188975",
"pixel":" "
},
{
"name":"天柱街—天柱街310号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8154405",
"latitude":"30.2519885",
"pixel":" "
},
{
"name":"天柱街—天柱街278号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8160808",
"latitude":"30.25218062",
"pixel":" "
},
{
"name":"天柱街—天柱街260号",
"company":" ",
"type":"人脸识别",
"longitude":"119.8169746",
"latitude":"30.25260699",
"pixel":" "
},
{
"name":"天柱街—崇文路西北角",
"company":" ",
"type":"人脸识别",
"longitude":"119.8174078",
"latitude":"30.25272134",
"pixel":" "
},
{
"name":"天柱街—崇文路西南角",
"company":" ",
"type":"人脸识别",
"longitude":"119.8171269",
"latitude":"30.25247588",
"pixel":" "
},
{
"name":"天柱街—天柱街290号",
"company":" ",
"type":"人脸识别",
"longitude":"119.815909",
"latitude":"30.252267",
"pixel":" "
},
{
"name":"科技大道-星港路旭辉旭悦房产门口",
"company":" ",
"type":"人脸识别球机",
"longitude":"119.824154",
"latitude":"30.257174",
"pixel":" "
},
{
"name":"科技大道-星港路旭辉旭悦房产门口向北",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.824154",
"latitude":"30.257174",
"pixel":" "
},
{
"name":"青罗线-童村与锦北街道交界处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.802544",
"latitude":"30.278841",
"pixel":" "
},
{
"name":"青罗线-童村与锦北街道交界处向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.802544",
"latitude":"30.278841",
"pixel":" "
},
{
"name":"牧锦线-板桥交界处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.780142",
"latitude":"30.214736",
"pixel":" "
},
{
"name":"牧锦线-板桥交界处向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.780142",
"latitude":"30.214736",
"pixel":" "
},
{
"name":"牧家桥-青牧线6公里处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.780361",
"latitude":"30.223909",
"pixel":" "
},
{
"name":"牧家桥-青牧线6公里处向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.780361",
"latitude":"30.223909",
"pixel":" "
},
{
"name":"329国道-汪家埠公交站向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.869039",
"latitude":"30.251882",
"pixel":" "
},
{
"name":"329国道-汪家埠公交站向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.869039",
"latitude":"30.251882",
"pixel":" "
},
{
"name":"329国道-排山隧道口青山交界处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.795874",
"latitude":"30.225671",
"pixel":" "
},
{
"name":"329国道-排山隧道口青山交界处向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.795874",
"latitude":"30.225671",
"pixel":" "
},
{
"name":"科技大道-临余桥交界处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.865873",
"latitude":"30.257794",
"pixel":" "
},
{
"name":"科技大道-临余桥交界处向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.865873",
"latitude":"30.257794",
"pixel":" "
},
{
"name":"科技大道-锦北街道街道交界处锦福家园向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.808884",
"latitude":"30.25951",
"pixel":" "
},
{
"name":"科技大道-锦北街道街道交界处锦福家园向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.808884",
"latitude":"30.25951",
"pixel":" "
},
{
"name":"胜联路-电子科技大学与余杭交界处向北",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.830757",
"latitude":"30.292202",
"pixel":" "
},
{
"name":"胜联路-电子科技大学与余杭交界处向南",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.830757",
"latitude":"30.292202",
"pixel":" "
},
{
"name":"255县道-岗阳街与余杭交界处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.828369",
"latitude":"30.272543",
"pixel":" "
},
{
"name":"255县道-岗阳街与余杭交界处向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.828369",
"latitude":"30.272543",
"pixel":" "
},
{
"name":"杭叉东面杨梅湾-余杭交界处向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.864695",
"latitude":"30.261076",
"pixel":" "
},
{
"name":"杭叉东面杨梅湾-余杭交界处向北",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.864695",
"latitude":"30.261076",
"pixel":" "
},
{
"name":"青山水库大坝-保安学校交界处向北",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.804201",
"latitude":"30.247906",
"pixel":" "
},
{
"name":"青山水库大坝-保安学校交界处向南",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.804201",
"latitude":"30.247906",
"pixel":" "
},
{
"name":"青山湖路-水库大坝绿道向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.804481",
"latitude":"30.241627",
"pixel":" "
},
{
"name":"青山湖路-水库大坝绿道向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.804471",
"latitude":"30.241697",
"pixel":" "
},
{
"name":"天柱街-青山二小南门向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.826753",
"latitude":"30.25137",
"pixel":" "
},
{
"name":"天柱街-青山二小南门向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.826753",
"latitude":"30.25137",
"pixel":" "
},
{
"name":"蒋墅街-青山二小北门向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.825746",
"latitude":"30.253331",
"pixel":" "
},
{
"name":"蒋墅街-青山二小北门向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.825746",
"latitude":"30.253331",
"pixel":" "
},
{
"name":"青山政府西门向北",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.9100394",
"latitude":"30.2512939",
"pixel":" "
},
{
"name":"青山公园公厕后向东",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.814822",
"latitude":"30.24701785",
"pixel":" "
},
{
"name":"青山公园公厕后向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.814822",
"latitude":"30.24701785",
"pixel":" "
},
{
"name":"塘塍街-青山湖科技城育才小学南门向南",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.813838",
"latitude":"30.265906",
"pixel":" "
},
{
"name":"塘塍街-青山湖科技城育才小学南门口向西",
"company":" ",
"type":"人脸识别枪机",
"longitude":"119.813841",
"latitude":"30.265922",
"pixel":" "
}
]
}
},
mounted() {
this.$nextTick(() => {
this.clearOverlays();
})
},
methods: {
clearOverlays() {
// 百度地图API功能
this.map = new BMap.Map("allMap");
let coordinate = new BMap.Point(119.798500, 30.300125); // 创建标注
this.map.centerAndZoom(coordinate, 13);
this.map.addControl(new BMap.NavigationControl()); // 添加平移缩放控件
this.map.addControl(new BMap.ScaleControl()); // 添加比例尺控件
this.map.addControl(new BMap.OverviewMapControl()); //添加缩略地图控件
this.map.enableScrollWheelZoom();
setTimeout(() => {
this.getBoundary(this.map);
}, 2000);
},
mapShow(coordinate, item) {
let self = this;
let opts = {
position: coordinate, // 指定文本标注所在的地理位置
offset: new BMap.Size(5, 0) //设置文本偏移量
};
let str = `<p style="font-weight: 700">${item.name}</p>`;
str += `<p>摄像头类型:${item.type}</p>`;
str += `<p>设备厂商:${item.company}</p>`;
str += `<p>产品参数:${item.pixel}</p>`;
let url = "static/blue.png";
url = `static/${item.type=='人脸识别枪机'||item.type=='人脸识别球机'?'人脸识别':item.type.trim()}.png`;
let label = new BMap.Label(str, opts); // 创建文本标注对象
label.setStyle({
color: "#444",
fontSize: "12px",
padding: '5px',
borderColor: '#aaa',
borderRadius: '5px',
opacity: 0,
fontFamily: "微软雅黑"
});
this.map.addOverlay(label);
let myIcon = new BMap.Icon(url, new BMap.Size(40, 81),{
// 指定定位位置。
// 当标注显示在地图上时,其所指向的地理位置距离图标左上
// 角各偏移10像素和25像素。您可以看到在本例中该位置即是
// 图标中央下端的尖角位置。
anchor: new BMap.Size(20, 81),
// 设置图片偏移。
// 当您需要从一幅较大的图片中截取某部分作为标注图标时,您
// 需要指定大图的偏移位置,此做法与css sprites技术类似。
// imageOffset: new BMap.Size(0, 0 - 81) // 设置图片偏移
});
let marker = new BMap.Marker(coordinate, {icon: myIcon});
this.map.addOverlay(marker); // 将标注添加到地图中
marker.addEventListener("click", function () {
self.$emit('town_accept', item);
});
marker.addEventListener("mouseover", function (item) {
label.setStyle({
opacity: 1,
});
// self.map.openInfoWindow(infoWindow, coordinate); //开启信息窗口
});
marker.addEventListener("mouseout", function () {
label.setStyle({
opacity: 0,
});
// self.map.openInfoWindow(infoWindow, coordinate); //开启信息窗口
});
},
getBoundary(map) {
let self = this;
let bdary = new BMap.Boundary();
bdary.get('临安区', function (rs) {       //获取行政区域       
const count = rs.boundaries.length;
if (count === 0) {
return;
}
const EN_JW = '180, 90;';
const NW_JW = '-180, 90;';
const WS_JW = '-180, -90;';
const SE_JW = '180, -90;';
// 东南西北四个角添加一个覆盖物
const ply1 = new BMap.Polygon(SE_JW + SE_JW + WS_JW + NW_JW + EN_JW + SE_JW + rs.boundaries[0],
{strokeColor: 'none', fillColor: '#efefef', fillOpacity: 1, strokeOpacity: 1});
map.addOverlay(ply1);
// 绘制‘临安区’整体的外轮廓
for (let i = 0; i < count; i++) {
const ply = new BMap.Polygon(rs.boundaries[i], {
strokeWeight: 2,
strokeColor: '#3396fb',
fillColor: 'transparent',
fillOpacity: 0
});
map.addOverlay(ply);
}
let marker;
let position = '';
for (let item of self.search_data) {
position = self.bd_encrypt(item.longitude, item.latitude);
marker = new BMap.Point(position.split(',')[0], position.split(',')[1]);
self.mapShow(marker, item);
// if(Array.isArray(item.data)){
// for(let j of item.data){
// for(let i=0;i<j.num;i++){
//
// }
// }
// }
}
});
},
bd_encrypt(gg_lng, gg_lat) {
let coordtransform=require('coordtransform');
//wgs84转国测局坐标
let wgs84togcj02=coordtransform.wgs84togcj02(gg_lng, gg_lat);
//国测局坐标转百度经纬度坐标
let gcj02tobd09=coordtransform.gcj02tobd09(wgs84togcj02[0], wgs84togcj02[1]);
// var X_PI = Math.PI * 3000.0 / 180.0;
// var x = gg_lng, y = gg_lat;
// var z = Math.sqrt(x * x + y * y) + 0.00002 * Math.sin(y * X_PI);
// var theta = Math.atan2(y, x) + 0.000003 * Math.cos(x * X_PI);
// var bd_lng = z * Math.cos(theta) + 0.0065;
// var bd_lat = z * Math.sin(theta) + 0.006;
return gcj02tobd09[0] + ',' + gcj02tobd09[1];
}
}
});
</script>
This source diff could not be displayed because it is too large. You can view the blob instead.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment