| extends ../layouts/basic |
| |
| block extra_head |
| title 地图下载 - Apache ECharts |
| link(rel='stylesheet', type='text/css', href='#{cdnPayRoot}/#{ecWWWLang}/vendors/prettify/prettify.css?_v_=#{cdnPayVersion}') |
| |
| block content |
| nav(class='navbar navbar-default navbar-fixed-top') |
| include ../components/nav |
| |
| .page-main |
| .page-info |
| h1 地图下载 |
| p (暂不提供地图下载) |
| p.page-info-echarts Apache ECharts<sup>TM</sup> |
| //- p ECharts 提供世界、中国、各省地图,数据来自第三方 |
| |
| .page-content(style='text-align: left; min-height: 300px; margin-top: 30px;', class='container') |
| p ECharts 之前提供下载的矢量地图数据来自第三方,由于部分数据不符合国家《测绘法》规定,目前暂时停止下载服务。 |
| p 建议大家使用以百度地图为底图的形式,参考<a href="#{host}/examples/zh/editor.html?c=map-polygon">例子</a>。 |
| |
| //- .page-content#map-download |
| //- #maps |
| //- #map-list.container |
| //- .row |
| //- .col-md-5.col-md-offset-1.col-xs-6 |
| //- h3 中国地图 |
| //- span China |
| //- a(href="asset/map/json/china.json" download="china.json" target="_blank") |
| //- img(src="asset/map/thumb/china.png" alt="") |
| //- .links |
| //- a(href="asset/map/js/china.js" download="china.js" target="_blank") JS |
| //- a(href="asset/map/json/china.json" download="china.json" target="_blank") JSON |
| //- .col-md-5.col-xs-6 |
| //- h3 世界地图 |
| //- span world |
| //- a(href="asset/map/json/world.json" download="world.json" target="_blank") |
| //- img(src="asset/map/thumb/world.png" alt="") |
| //- .links |
| //- a(href="asset/map/js/world.js" download="world.js" target="_blank") JS |
| //- a(href="asset/map/json/world.json" download="world.json" target="_blank") JSON |
| |
| //- .row |
| //- .col-md-11.col-md-offset-1 |
| //- h3 各省地图 |
| //- span province |
| //- .row |
| //- each provinceName, idx in province |
| //- if idx % 5 === 0 |
| //- .col-md-2.col-md-offset-1.col-sm-3.col-xs-4.province |
| //- a(href="asset/map/json/province/#{provincePinyin[idx]}.json" download="#{provincePinyin[idx]}.json" target="_blank") |
| //- img(src="asset/map/thumb/#{provincePinyin[idx]}.png" alt="") |
| //- h5 #{provinceName} |
| //- div.links |
| //- a(href="asset/map/js/province/#{provincePinyin[idx]}.js" download="#{provincePinyin[idx]}.js" target="_blank") JS |
| //- a(href="asset/map/json/province/#{provincePinyin[idx]}.json" download="#{provincePinyin[idx]}.json" target="_blank") JSON |
| //- else |
| //- .col-md-2.col-sm-3.col-xs-4.province |
| //- a(href="asset/map/json/province/#{provincePinyin[idx]}.json" download="#{provincePinyin[idx]}.json" target="_blank") |
| //- img(src="asset/map/thumb/#{provincePinyin[idx]}.png" alt="") |
| //- h5 #{provinceName} |
| //- div.links |
| //- a(href="asset/map/js/province/#{provincePinyin[idx]}.js" download="#{provincePinyin[idx]}.js" target="_blank") JS |
| //- a(href="asset/map/json/province/#{provincePinyin[idx]}.json" download="#{provincePinyin[idx]}.json" target="_blank") JSON |
| |
| //- section.section-bg |
| //- a.btn.btn-main.btn-thirdary.more-btn(href='https://ecomfe.github.io/echarts-map-tool/') 地图定制 |
| //- p 可在线选择生成省、市、县各级地图 |
| |
| //- .container |
| //- #map-example |
| //- h4 JavaScript 引入示例 |
| //- pre(class="html"). |
| //- <script src="echarts.js"></script> |
| //- <script src="map/js/china.js"></script> |
| //- <script> |
| //- var chart = echarts.init(document.getElementById('main')); |
| //- chart.setOption({ |
| //- series: [{ |
| //- type: 'map', |
| //- map: 'china' |
| //- }] |
| //- }); |
| //- </script> |
| |
| //- h4 JSON 引入示例 |
| //- pre(class="js"). |
| //- $.get('map/json/china.json', function (chinaJson) { |
| //- echarts.registerMap('china', chinaJson); |
| //- var chart = echarts.init(document.getElementById('main')); |
| //- chart.setOption({ |
| //- series: [{ |
| //- type: 'map', |
| //- map: 'china' |
| //- }] |
| //- }); |
| //- }); |
| |
| include ../components/footer |
| |
| block extra_js |
| script(src="#{cdnThirdParty.prettifyJS}") |
| script(src="#{cdnThirdParty.prettifyCSSHandlerJS}") |
| script. |
| document.getElementById('nav-download').className = 'active'; |
| $('pre').addClass('prettyprint'); |
| prettyPrint(); |