123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333 |
- <!--#include file="inc/header.html"-->
- <script src="/src/echarts.min.js"></script>
- <!-- <script src="/src/shandong.js"></script> -->
- <div class="con-wrap map-area">
- <!-- <h1>山东省分公司</h1> -->
- <div class="con" id="mapcontainer">
- <div id="main-map"></div>
- <div id="mapLw-show"></div>
- <ul id="list-show"></ul>
- </div>
- </div>
- <script type="text/javascript">
- var chart;
- var city = {
- "济南市": {
- '历城区': 'jnbk',
- '莱芜市': 'lwfk',
- },
- "莱芜市": {
- "莱城区": 'lwfk',
- /*"钢城区": 'lwfk',*/
- },
- "青岛市": {
- '城阳区': 'qdbk',
- '平度市': 'pdfk',
- '莱西市': 'lxfk',
- },
- "淄博市": {
- '桓台县': 'zbbk',
- '高青县': 'gqfk',
- },
- "枣庄市": {
- '市中区': 'zzbk',
- '滕州市': 'zfk',
- '山亭区': 'stfk',
- '台儿庄区': 'tezfk',
- },
- "东营市": {
- '垦利县': 'dybk',
- '广饶县': 'grfk',
- },
- "烟台市": {
- '莱阳市': 'ytbk',
- '莱州市': 'lzfk',
- },
- "潍坊市": {
- '青州市': 'wfbk',
- '昌邑市': 'cyfk',
- '安丘市': 'wfgjls',
- },
- "济宁市": {
- '兖州区': 'jningbk',
- '金乡县': 'jxfk',
- '汶上县': 'syxgs',
- },
- "泰安市": {
- '泰山区': 'tabk',
- '岱岳区': 'zzlz',
- '肥城市': 'fcfk',
- '东平县': 'dpfk',
- '宁阳县': 'nyfk',
- },
- "威海市": {
- '文登区': 'whbk',
- '乳山市': 'rsfk',
- '荣成市': 'rcfk',
- },
- "日照市": {
- '岚山区': 'rzbk',
- '莒县': 'xfk',
- },
- "临沂市": {
- '兰山区': 'lybk',
- '临沭县': 'lfk',
- '蒙阴县': 'myfk',
- '沂水县': 'ysfk',
- '沂南县': 'ynfk',
- '平邑县': 'pyfk',
- '莒南县': 'nfk',
- '兰陵县': 'csfk',
- // '南桥收纳库': 'nqsnk',
- '郯城县': 'tcfk',
- },
- "德州市": {
- '德城区': 'dzbk',
- '武城县': 'wcfk',
- '禹城市': 'ycgfgs',
- '乐陵市': 'llfk',
- },
- "聊城市": {
- '东昌府区': 'lcbk',
- '阳谷县': 'ygyxgs',
- '冠县': 'gxfk',
- '莘县': 'sxyxgs',
- '高唐县': 'gtfk',
- },
- "滨州市": {
- '惠民县': 'bzbk',
- '阳信县': 'yxfk',
- },
- "菏泽市": {
- '曹县': 'hzbk',
- '东明县': 'dmfk',
- '巨野县': 'jyfk',
- '成武县': 'gyjscd',
- '单县': 'dxfk',
- // '黄岗收储点': 'igscd',
- '郓城县': 'ycfk',
- // '杨楼收储点': 'ylscd',
- // '古营集收储点': 'gyjscd',
- '牡丹区': 'hjscd',
- // '韩集收储点': 'hjscd',
- }
- };
- var city2 = {
- "jinan": "济南市",
- "qingdao": "青岛市",
- "zibo": "淄博市",
- "zaozhuang": "枣庄市",
- "dongying": "东营市",
- "yantai": "烟台市",
- "weifang": "潍坊市",
- "jining": "济宁市",
- "taian": "泰安市",
- "weihai": "威海市",
- "rizhao": "日照市",
- "linyi": "临沂市",
- "dezhou": "德州市",
- "liaocheng": "聊城市",
- "binzhou": "滨州市",
- "heze": "菏泽市"
- };
- var name = city2[window.location.hash.replace("#", "")],
- data = [];
- if(name == "济南市") {
- $.get('/src/map/莱芜市.json', function (json) {
- echarts.registerMap('莱芜市', json);
- $('#mapLw-show').show();
- lwChart = echarts.init(document.getElementById('mapLw-show'));
- lwChart.setOption({
- title: {
- text: '',
- subtext: '',
- left: 'center'
- },
- tooltip: {
- trigger: 'item',
- formatter: '{b}'
- },
- legend: {
- orient: 'vertical',
- top: 'bottom',
- left: 'right',
- itemHeight: 20,
- itemWidth: 20,
- shadowBlur: '10',
- selectedMode: 'single'
- },
- series: [{
- name: '莱芜市',
- map: '莱芜市',
- type: 'map',
- selectedMode: 'single',
- label: {
- normal: {
- show: true,
- textStyle: {
- color: '#1A9856'
- }
- },
- emphasis: {
- show: true,
- textStyle: {
- color: '#fff'
- }
- }
- },
- itemStyle: {
- normal: {
- areaColor: '#ccc',
- borderColor: '#333'
- },
- emphasis: {
- areaColor: '#007B3A',
- borderColor: '#666'
- }
- },
- data: [
- {name: '莱城区', value: Math.round(Math.random()*1000)},
- /*{name: '钢城区', value: Math.round(Math.random()*1000)},*/
- ]
- }]
- });
- lwChart.on('click',function(param) {
- if(param.name=='钢城区'){
- }else{
- window.location.href="/map/grain/lwfk.html";
- }
- })
- return;
- })
- } else {
- $('#mapLw-show').hide();
- }
- $.each(city[name], function(ind, ele){
- var obj = {};
- obj.name = ind;
- obj.value = Math.round(Math.random()*1000);
- data.push(obj);
- })
- $.get('/src/map/'+ name +'.json', function (json) {
- echarts.registerMap(name, json);
- var ename=name.substr(0, 2)+"地区";
- chart = echarts.init(document.getElementById('main-map'));
- chart.setOption({
- title: {
- text: ename,
- subtext: '',
- left: 'center'
- },
- legend: {
- orient: 'vertical',
- top: 'bottom',
- left: 'right',
- itemHeight: 20,
- itemWidth: 20,
- shadowBlur: '10',
- selectedMode: 'single'
- },
- tooltip: {
- trigger: 'item',
- formatter: '{b}'
- },
- series: [{
- name: name,
- map: name,
- type: 'map',
- selectedMode: 'single',
- // showLegendSymbol: true,
- label: {
- normal: {
- show: true,
- textStyle: {
- color: '#1A9856'
- }
- },
- emphasis: {
- show: true,
- textStyle: {
- color: '#fff'
- }
- }
- },
- itemStyle: {
- normal: {
- areaColor: '#ccc',
- borderColor: '#333'
- },
- emphasis: {
- areaColor: '#007B3A',
- borderColor: '#666'
- }
- },
- data: data
- }]
- });
- chart.on('click',function(param) {
- var html;
- if (param.name == '兰陵县') {
- html = "";
- html += '<li><a href="/map/grain/csfk.html">兰陵县分公司</a></li>';
- html += '<li><a href="/map/grain/nqsnk.html">南桥收纳库</a></li>';
- $('#list-show').empty().show().append($(html));
- return;
- } else if(param.name == '单县') {
- html = "";
- html += '<li><a href="/map/grain/dxfk.html">单县分公司</a></li>';
- html += '<li><a href="/map/grain/igscd.html">黄岗收储点</a></li>';
- $('#list-show').empty().show().append($(html));
- return;
- } else if(param.name == '东昌府区') {
- html = "";
- html += '<li><a href="/map/grain/lcbk.html">聊城直属库有限公司</a></li>';
- html += '<li><a href="/map/grain/lcwl.html">聊城物流</a></li>';
- $('#list-show').empty().show().append($(html));
- return;
- } else if(param.name == '莱州市') {
- html = "";
- html += '<li><a href="/map/grain/lzfk.html">莱州分公司</a></li>';
- html += '<li><a href="/map/grain/lzfiwl.html">丰和物流</a></li>';
- $('#list-show').empty().show().append($(html));
- return;
- } else if (param.name == '郓城县') {
- html = "";
- html += '<li><a href="/map/grain/ycfk.html">郓城县分公司</a></li>';
- html += '<li><a href="/map/grain/ylscd.html">杨楼收储点</a></li>';
- html += '<li><a href="/map/grain/gyjscd.html">古营集收储点</a></li>';
- $('#list-show').empty().show().append($(html));
- return;
- } else if (param.name == '牡丹区') {
- html = "";
- html += '<li><a href="/map/grain/hjscd.html">牡丹区分公司</a></li>';
- html += '<li><a href="/map/grain/hjscd.html">韩集收储点</a></li>';
- $('#list-show').empty().show().append($(html));
- return;
- } else {
- var hrefname = city[param.seriesName][param.name];
- if( hrefname ) {
- window.location.href="/map/grain/"+ hrefname +".html";
- $('#list-show').hide();
- } else {
- chart.dispatchAction({
- type: 'mapUnSelect',
- name: param.name
- })
- $('#list-show').hide();
- return;
- }
- }
- });
- })
- </script>
- <div class="bottom-wrap">© 2018 中储粮-单仓档案管理系统 版权所有</div>
- </body>
- </html>
|