2
13693261870
2022-09-16 653761a31dfeb50dd3d007e892d69c90bf0cdafc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:layout="http://www.w3.org/1999/xhtml"
      xmlns:th="http://www.thymeleaf.org"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta name="viewport" content="width=device-width">
    <title>海岛统计</title>
    <script src="/js/PingTaiMenHuFile/GongNengQuHua/jquery-1.8.3.min.js" type="text/javascript"></script>
    <script th:src="@{${pubzyWebRoot} + 'echarts/echarts.min-3.0.js'}" type="text/javascript"></script>
    <style>
        body {
            margin: 0px;
        }
        .title {
            font-size: 14px !important;
        }
 
        #MainDiv {
            float: left;
            font-size: 12pt;
            width: 100%;
            text-align: center;
            height: 921px;
            margin-top: 12px;
        }
    </style>
<body>
<div>
    <div id="MainDiv" style="">
        <div id="LDTZmain" class="main" style="width: 100%; height: 100%; -webkit-tap-highlight-color: transparent; user-select: none; background-color: rgba(0, 0, 0, 0); cursor: default;" _echarts_instance_="1545882117588"><div style="position: relative; overflow: hidden; width: 1920px; height: 921px;"><div data-zr-dom-id="bg" class="zr-element" style="position: absolute; left: 0px; top: 0px; width: 1920px; height: 921px; user-select: none;"></div><canvas width="1920" height="921" data-zr-dom-id="0" class="zr-element" style="position: absolute; left: 0px; top: 0px; width: 1920px; height: 921px; user-select: none; -webkit-tap-highlight-color: rgba(0, 0, 0, 0);"></canvas><canvas width="1920" height="921" data-zr-dom-id="1" class="zr-element" style="position: absolute; left: 0px; top: 0px; width: 1920px; height: 921px; user-select: none; -webkit-tap-highlight-color: rgba(0, 0, 0, 0);"></canvas><canvas width="1920" height="921" data-zr-dom-id="_zrender_hover_" class="zr-element" style="position: absolute; left: 0px; top: 0px; width: 1920px; height: 921px; user-select: none; -webkit-tap-highlight-color: rgba(0, 0, 0, 0);"></canvas><div class="echarts-tooltip zr-element" style="position: absolute; display: block; border-style: solid; white-space: nowrap; transition: left 0.4s, top 0.4s; background-color: rgba(50, 50, 50, 0.498039); border-width: 0px; border-color: rgb(51, 51, 51); border-radius: 4px; color: rgb(255, 255, 255); font-family: 微软雅黑, Arial, Verdana, sans-serif; padding: 5px; left: 1501px; top: 613px;">广东省<br>确权面积(万公顷) : 10.37<br>投资额(亿元) : 6,568.19<br>预计拉动区域经济产值(亿元) : 7,674.669188</div></div></div>
    </div>
</div>
 
 
<script type="text/javascript" th:inline="javascript">
    jQuery(document).ready(function () {
        $("#MainDiv").css("height", window.innerHeight - 12);
        loadEChart();
    });
 
    function loadEChart() {
        var myChart = echarts.init(document.getElementById('LDTZmain'), 'macarons');
        var labelFromatter = {
            normal: {
                label: {
                    formatter: function (params) {
                        return params.name + ' ' + params.percent + '%'
                    },
                    textStyle: {
                        baseline: 'top'
                    }
                }
            },
        }
 
        //海岛基本情况
        var option = {
            color:["#FF6666","#0189FF"],
            title: {
                text: '海岛统计-基本数量统计',
                x: 28,
                y: 14,
                textStyle:{
                    fontSize:20,
                    fontWeight:"bold",
                    color: "#4676FE"
                }
            },
            tooltip: {
                trigger: 'axis',
                axisPointer: {            // 坐标轴指示器,坐标轴触发有效
                    type: 'shadow'        // 默认为直线,可选为:'line' | 'shadow'
                }
            },
            legend: {
                data: ['有居民(个)', '无居民(个)'],
                x: 'left',
                // y: 45,
                // x: 15,
                padding: [63,0,0,33],
                show: true
            },
            toolbox: {
                show: false,
                feature: {
                    mark: { show: true },
                    dataView: { show: true, readOnly: false },
                    magicType: { show: true, type: ['line', 'bar'] },
                    restore: { show: true },
                    saveAsImage: { show: true }
                }
            },
            calculable: true,
            xAxis: [
                {
                    type: 'value',
                    axisLine:{
                        lineStyle:{
                            color:'#A9A9A9',
                        }
                    }
                }
            ],
            grid: {
                x: 60,
                x2: 35,
                y2: 50,
                y:115
            },
            yAxis: [
                {
                    type: 'category',
                    data: ['辽宁', '河北', '天津', '山东', '江苏', '上海', '浙江', '福建', '广东', '广西', '海南'],
                    axisLine:{
                        lineStyle:{
                            color:'#A9A9A9',
                        }
                    }
                }
            ],
            series: [
                {
                    name: '有居民(个)',
                    type: 'bar',
                    stack: '总量',
                    itemStyle: { normal: { label: { show: true, position: 'insideRight' } } },
                    data: []
 
                },
                {
                    name: '无居民(个)',
                    type: 'bar',
                    data: [],
                    stack: '总量',
                    itemStyle: { normal: { label: { show: true, position: 'insideRight' } } },
                }
            ]
        };
        option.series[0].data = [44,0,0,32,4,3,222,100,57,14,13];
        option.series[1].data = [589,13,1,542,11,23,4131,2273,1906,629,713];
        myChart.setOption(option);
    }
</script></body></html>