|
@@ -6,7 +6,24 @@
|
|
|
<span>海域使用权出让</span>
|
|
|
</div>
|
|
|
<div class="content">
|
|
|
+ <div class="icon_info">
|
|
|
|
|
|
+ </div>
|
|
|
+ <div class="info_left">
|
|
|
+
|
|
|
+ </div>
|
|
|
+ <div class="info_main">
|
|
|
+
|
|
|
+ </div>
|
|
|
+ <div class="text">
|
|
|
+ <span>收储项目</span>
|
|
|
+ <span class="count1">33</span>
|
|
|
+ <span class="unit">个</span>
|
|
|
+
|
|
|
+ <span>收储总面积</span>
|
|
|
+ <span class="count2">213124.45</span>
|
|
|
+ <span class="unit">公顷</span>
|
|
|
+ </div>
|
|
|
</div>
|
|
|
<div id="hysyEchart">
|
|
|
|
|
@@ -39,184 +56,250 @@ export default {
|
|
|
|
|
|
var myChart = window.echarts.init(dom);
|
|
|
|
|
|
+ // 柱状图的宽度,y是x的一半
|
|
|
+ const offsetX = 10
|
|
|
+ const offsetY = 5
|
|
|
+ let colorList = ["RGBA(30, 111, 181, 0.8)", "RGBA(149, 101, 24, 0.8)", "RGBA(29, 128, 64, 0.8)", "RGBA(133, 48, 52, 0.8)", "RGBA(121, 62, 147, 0.8)"]
|
|
|
+
|
|
|
+ // 绘制左侧面
|
|
|
+ const CubeLeft = echarts.graphic.extendShape({
|
|
|
+ shape: {
|
|
|
+ x: 0,
|
|
|
+ y: 0
|
|
|
+ },
|
|
|
+ buildPath: function (ctx, shape) {
|
|
|
+ // 会canvas的应该都能看得懂,shape是从custom传入的
|
|
|
+ const xAxisPoint = shape.xAxisPoint
|
|
|
+ const c0 = [shape.x, shape.y]
|
|
|
+ const c1 = [shape.x - offsetX, shape.y - offsetY]
|
|
|
+ const c2 = [xAxisPoint[0] - offsetX, xAxisPoint[1] - offsetY]
|
|
|
+ const c3 = [xAxisPoint[0], xAxisPoint[1]]
|
|
|
+ ctx
|
|
|
+ .moveTo(c0[0], c0[1])
|
|
|
+ .lineTo(c1[0], c1[1])
|
|
|
+ .lineTo(c2[0], c2[1])
|
|
|
+ .lineTo(c3[0], c3[1])
|
|
|
+ .closePath()
|
|
|
+ }
|
|
|
+ })
|
|
|
+ // 绘制右侧面
|
|
|
+ const CubeRight = echarts.graphic.extendShape({
|
|
|
+ shape: {
|
|
|
+ x: 0,
|
|
|
+ y: 0
|
|
|
+ },
|
|
|
+ buildPath: function (ctx, shape) {
|
|
|
+ const xAxisPoint = shape.xAxisPoint
|
|
|
+ const c1 = [shape.x, shape.y]
|
|
|
+ const c2 = [xAxisPoint[0], xAxisPoint[1]]
|
|
|
+ const c3 = [xAxisPoint[0] + offsetX, xAxisPoint[1] - offsetY]
|
|
|
+ const c4 = [shape.x + offsetX, shape.y - offsetY]
|
|
|
+ ctx
|
|
|
+ .moveTo(c1[0], c1[1])
|
|
|
+ .lineTo(c2[0], c2[1])
|
|
|
+ .lineTo(c3[0], c3[1])
|
|
|
+ .lineTo(c4[0], c4[1])
|
|
|
+ .closePath()
|
|
|
+ }
|
|
|
+ })
|
|
|
+ // 绘制顶面
|
|
|
+ const CubeTop = echarts.graphic.extendShape({
|
|
|
+ shape: {
|
|
|
+ x: 0,
|
|
|
+ y: 0
|
|
|
+ },
|
|
|
+ buildPath: function (ctx, shape) {
|
|
|
+ const c1 = [shape.x, shape.y]
|
|
|
+ const c2 = [shape.x + offsetX, shape.y - offsetY] // 右点
|
|
|
+ const c3 = [shape.x, shape.y - offsetX]
|
|
|
+ const c4 = [shape.x - offsetX, shape.y - offsetY]
|
|
|
+ ctx
|
|
|
+ .moveTo(c1[0], c1[1])
|
|
|
+ .lineTo(c2[0], c2[1])
|
|
|
+ .lineTo(c3[0], c3[1])
|
|
|
+ .lineTo(c4[0], c4[1])
|
|
|
+ .closePath()
|
|
|
+ }
|
|
|
+ })
|
|
|
+ // // 绘制底面
|
|
|
+ const CubeBottom = echarts.graphic.extendShape({
|
|
|
+ shape: {
|
|
|
+ x: 10,
|
|
|
+ y: 10
|
|
|
+ },
|
|
|
+ buildPath: function (ctx, shape) {
|
|
|
+ const xAxisPoint = shape.xAxisPoint
|
|
|
+ const c1 = [xAxisPoint[0] - offsetX, xAxisPoint[1] - offsetY]
|
|
|
+ const c2 = [xAxisPoint[0], xAxisPoint[1]] // 右点
|
|
|
+ const c3 = [xAxisPoint[0] + offsetX, xAxisPoint[1] - offsetY]
|
|
|
+ const c4 = [xAxisPoint[0], xAxisPoint[1] - offsetX]
|
|
|
+ ctx
|
|
|
+ .moveTo(c1[0], c1[1])
|
|
|
+ .lineTo(c2[0], c2[1])
|
|
|
+ .lineTo(c3[0], c3[1])
|
|
|
+ .lineTo(c4[0], c4[1])
|
|
|
+ .closePath()
|
|
|
+ }
|
|
|
+ })
|
|
|
+
|
|
|
+ // 注册图形
|
|
|
+ echarts.graphic.registerShape('CubeLeft', CubeLeft)
|
|
|
+ echarts.graphic.registerShape('CubeRight', CubeRight)
|
|
|
+ echarts.graphic.registerShape('CubeTop', CubeTop)
|
|
|
+ echarts.graphic.registerShape('CubeBottom', CubeBottom)
|
|
|
+ const dataX = ["渔业用海", "工业用海", "造地工程", "旅游娱乐", "交通运输"]
|
|
|
+ const barData = [45, 33, 11, 20, 3]
|
|
|
let option = {
|
|
|
- grid: {
|
|
|
- top: "65px",
|
|
|
- bottom: "50px",
|
|
|
- left: "45px",
|
|
|
- right: "20px",
|
|
|
+ //你的代码
|
|
|
+ backgroundColor: 'rgba(0,0,0,0)',
|
|
|
+ legend: {
|
|
|
+ show: false,
|
|
|
+ right: 30,
|
|
|
+ top: 10,
|
|
|
+ itemGap: 30,
|
|
|
+ itemWidth: 20,
|
|
|
+ itemHeight: 10,
|
|
|
+ data: ['时长', '百分比'],
|
|
|
+ textStyle: {
|
|
|
+ fontSize: 18,
|
|
|
+ color: '#ffffff'
|
|
|
+ }
|
|
|
},
|
|
|
- title: { //配置标题组件
|
|
|
- text: "", //设置主标题
|
|
|
- textStyle: { //设置主标题文字样式
|
|
|
- color: 'green',
|
|
|
+ color: ['#097dc0', '#26D6D7'],
|
|
|
+ tooltip: {
|
|
|
+ show: false,
|
|
|
+ trigger: 'axis',
|
|
|
+ textStyle: {
|
|
|
+ fontSize: 18 // 字体大小
|
|
|
},
|
|
|
- left: 20, //设置适当调整工具框的left位置
|
|
|
- top: 3 //设置适当调整工具框的top位置
|
|
|
- },
|
|
|
- tooltip: { //配置提示框组件
|
|
|
- trigger: 'axis', //当鼠标滑过轴线时触发显示于详情
|
|
|
axisPointer: {
|
|
|
- type: 'cross',//line(直线) || shadow(阴影) || cross(十字准星) || none
|
|
|
- label: {
|
|
|
- show: true // 鼠标移入X轴文字效果 true || false
|
|
|
- }
|
|
|
+ type: 'shadow'
|
|
|
}
|
|
|
},
|
|
|
- legend: { //配置图例组件
|
|
|
- data: ['渔业用海', '工业用海', '造地工程', '旅游娱乐', '交通运输'],
|
|
|
- left: 100, //设置适当调整工具框的left位置
|
|
|
- bottom: "200px", //设置适当调整工具框的top位置
|
|
|
- textStyle: {
|
|
|
+ grid: {
|
|
|
+ top: '30%',
|
|
|
+ // left: '3%',
|
|
|
+ right: '3%',
|
|
|
+ bottom: '5%',
|
|
|
+ containLabel: true
|
|
|
+ },
|
|
|
+ xAxis: {
|
|
|
+ type: 'category',
|
|
|
+ data: dataX,
|
|
|
+ axisTick:{
|
|
|
+ show: false,
|
|
|
+ },
|
|
|
+ axisLine: {
|
|
|
+ show: true,
|
|
|
+
|
|
|
+ lineStyle: {
|
|
|
+ width: 1,
|
|
|
+ color: 'rgba(239, 247, 253, .7)'
|
|
|
+ }
|
|
|
+ },
|
|
|
+ axisLabel: {
|
|
|
fontSize: 12,
|
|
|
color: '#fff',
|
|
|
- padding: [5, 0, 0, 2],
|
|
|
- rich: {
|
|
|
- a: {
|
|
|
- verticalAlign: 'middle',
|
|
|
- },
|
|
|
- },
|
|
|
},
|
|
|
- icon: 'rect',
|
|
|
- itemHeight: 14,
|
|
|
- itemWidth: 14,
|
|
|
},
|
|
|
- xAxis: [ //配置X轴坐标系
|
|
|
+ yAxis: [
|
|
|
{
|
|
|
- //type: 'category',
|
|
|
- boundaryGap: false,
|
|
|
- data: ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10", "11", "12"],
|
|
|
- axisLabel: {
|
|
|
- color: "#fff",
|
|
|
- fontSize: 12
|
|
|
- },
|
|
|
- }
|
|
|
- ],
|
|
|
- yAxis: [ //配置Y轴坐标系
|
|
|
- {
|
|
|
- name: "面积/公顷",
|
|
|
+ type: 'value',
|
|
|
+ name: '面积/公顷',
|
|
|
+ nameGap: 30,
|
|
|
nameTextStyle: {
|
|
|
- color: "#fff",
|
|
|
- fontSize: 12,
|
|
|
- padding: [0, 0, 4, 0], //name文字位置 对应 上右下左
|
|
|
- },
|
|
|
- axisLabel: {
|
|
|
- color: "#fff",
|
|
|
+ color: '#ffffff',
|
|
|
+ fontWeight: 100,
|
|
|
fontSize: 12
|
|
|
},
|
|
|
- type: "value",
|
|
|
- }
|
|
|
- ],
|
|
|
- series: [ //配置数据系列。注意:将所有areaStyle去掉,则变成堆积折线图
|
|
|
- {
|
|
|
- name: '渔业用海',
|
|
|
- type: 'line', //设置指定显示为折线
|
|
|
- stack: '总量', //smooth:true,
|
|
|
- color: 'rgb(0,0,0)',
|
|
|
- symbol: "none",
|
|
|
- lineStyle: {
|
|
|
- normal: {
|
|
|
- color: "rgba(65, 139, 212, 1)" // 线条颜色
|
|
|
- }
|
|
|
- },
|
|
|
- itemStyle: {
|
|
|
- normal: {
|
|
|
- areaStyle: {
|
|
|
- //type: 'default',
|
|
|
- color: 'rgba(65, 139, 212, 1)'
|
|
|
- }
|
|
|
+ axisLine: {
|
|
|
+ show: false,
|
|
|
+ lineStyle: {
|
|
|
+ width: 1,
|
|
|
+ color: 'rgba(239, 247, 253, .1)'
|
|
|
}
|
|
|
},
|
|
|
- data: [434, 345, 456, 222, 333, 444, 432]
|
|
|
- },
|
|
|
- {
|
|
|
- name: '工业用海',
|
|
|
- type: 'line', //设置指定显示为折线
|
|
|
- stack: '总量', //设置堆积
|
|
|
- color: 'blue',
|
|
|
- symbol: "none",
|
|
|
- lineStyle: {
|
|
|
- normal: {
|
|
|
- color: "rgba(255, 176, 57, 1)" // 线条颜色
|
|
|
+ splitLine: {
|
|
|
+ show: true,
|
|
|
+ lineStyle: {
|
|
|
+ color: 'rgba(239, 247, 253, .1)'
|
|
|
}
|
|
|
},
|
|
|
- itemStyle: {
|
|
|
- normal: {
|
|
|
- areaStyle: {
|
|
|
- //type: 'default',
|
|
|
- color: 'rgba(255, 176, 57, 1)'
|
|
|
- }
|
|
|
- }
|
|
|
+ axisTick: {
|
|
|
+ show: false
|
|
|
},
|
|
|
- data: [420, 282, 391, 344, 390, 530, 410]
|
|
|
- },
|
|
|
- {
|
|
|
- name: '造地工程',
|
|
|
- type: 'line', //设置指定显示为折线
|
|
|
- stack: '总量', //设置堆积
|
|
|
- color: 'red',
|
|
|
- symbol: "none",
|
|
|
- lineStyle: {
|
|
|
- normal: {
|
|
|
- color: "rgba(92, 185, 129, 1)" // 线条颜色
|
|
|
- }
|
|
|
- },
|
|
|
- itemStyle: {
|
|
|
- normal: {
|
|
|
- areaStyle: {
|
|
|
- //type: 'default',
|
|
|
- color: 'rgba(92, 185, 129, 1)'
|
|
|
- }
|
|
|
- }
|
|
|
+ axisLabel: {
|
|
|
+ fontSize: 12,
|
|
|
+ color: '#E7FCFF'
|
|
|
},
|
|
|
- data: [350, 332, 331, 334, 390, 320, 340]
|
|
|
+ min: 0,
|
|
|
+ // max: Math.ceil(Math.max.apply(null, dataX) / 5) * 5,
|
|
|
+ // interval: Math.ceil(Math.max.apply(null, dataX) / 5)
|
|
|
},
|
|
|
+ ],
|
|
|
+ series: [
|
|
|
{
|
|
|
- name: '旅游娱乐',
|
|
|
- type: 'line', //设置指定显示为折线
|
|
|
- stack: '总量', //设置堆积
|
|
|
- color: 'green',
|
|
|
+ name: '时长',
|
|
|
+ type: 'custom',
|
|
|
+ renderItem: (params, api) => {
|
|
|
+ const location = api.coord([api.value(0), api.value(1)])
|
|
|
+ return {
|
|
|
+ type: 'group',
|
|
|
+ x: 0,
|
|
|
+ children: [
|
|
|
+ {
|
|
|
+ type: 'CubeLeft',
|
|
|
+ shape: {
|
|
|
+ api,
|
|
|
+ xValue: api.value(0),
|
|
|
+ yValue: api.value(1),
|
|
|
+ x: location[0],
|
|
|
+ y: location[1],
|
|
|
+ xAxisPoint: api.coord([api.value(0), 0])
|
|
|
+ },
|
|
|
+ style: {
|
|
|
+ fill: colorList[params.dataIndex % colorList.length]
|
|
|
|
|
|
- symbol: "none",
|
|
|
- lineStyle: {
|
|
|
- normal: {
|
|
|
- color: "rgba(255, 98, 96, 1)" // 线条颜色
|
|
|
- }
|
|
|
- },
|
|
|
- itemStyle: {
|
|
|
- normal: {
|
|
|
- areaStyle: {
|
|
|
- //type: 'default',
|
|
|
- color: 'rgba(255, 98, 96, 1)'
|
|
|
- }
|
|
|
- }
|
|
|
- },
|
|
|
- data: [420, 222, 333, 442, 230, 430, 430]
|
|
|
- },
|
|
|
- {
|
|
|
- name: '交通运输',
|
|
|
- type: 'line', //设置指定显示为折线
|
|
|
- stack: '总量', //设置堆积
|
|
|
- color: '#FA8072',
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'CubeRight',
|
|
|
+ shape: {
|
|
|
+ api,
|
|
|
+ xValue: api.value(0),
|
|
|
+ yValue: api.value(1),
|
|
|
+ x: location[0],
|
|
|
+ y: location[1],
|
|
|
+ xAxisPoint: api.coord([api.value(0), 0])
|
|
|
+ },
|
|
|
+ style: {
|
|
|
+ fill: colorList[params.dataIndex % colorList.length],
|
|
|
|
|
|
- symbol: "none",
|
|
|
- lineStyle: {
|
|
|
- normal: {
|
|
|
- color: "rgba(137, 81, 157, 1))" // 线条颜色
|
|
|
- }
|
|
|
- },
|
|
|
- itemStyle: {//设置item的样式
|
|
|
- normal: {//常规状态
|
|
|
- areaStyle: { //区域样式,仅在折线图中有效
|
|
|
- //type: 'default',
|
|
|
- color: 'rgba(137, 81, 157, 1)'
|
|
|
- }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'CubeTop',
|
|
|
+ shape: {
|
|
|
+ api,
|
|
|
+ xValue: api.value(0),
|
|
|
+ yValue: api.value(1),
|
|
|
+ x: location[0],
|
|
|
+ y: location[1],
|
|
|
+ xAxisPoint: api.coord([api.value(0), 0])
|
|
|
+ },
|
|
|
+ style: {
|
|
|
+ fill: colorList[params.dataIndex % colorList.length],
|
|
|
+
|
|
|
+ }
|
|
|
+ }
|
|
|
+ ]
|
|
|
}
|
|
|
},
|
|
|
- data: [330, 442, 432, 555, 456, 666, 877, 634, 534, 55, 111]
|
|
|
- }
|
|
|
+ data: barData
|
|
|
+ },
|
|
|
]
|
|
|
- };
|
|
|
+ }
|
|
|
+
|
|
|
myChart.setOption(option);
|
|
|
},
|
|
|
},
|
|
@@ -282,15 +365,78 @@ export default {
|
|
|
background: no-repeat;
|
|
|
width: 100%;
|
|
|
height: 44px;
|
|
|
- border: 1px solid red;
|
|
|
- // background-image: url("/static/images/overview/info.jpg");
|
|
|
+ position: relative;
|
|
|
+ // background-image: url("/static/images/overview/info_all.png");
|
|
|
+ // background-size: 98% 87%;
|
|
|
+
|
|
|
+ .text {
|
|
|
+ position: relative;
|
|
|
+ left: 3.5rem;
|
|
|
+ top: 0.5rem;
|
|
|
+ font-size: 15px;
|
|
|
+ font-weight: 600;
|
|
|
+
|
|
|
+ .unit {
|
|
|
+ margin-right: 3rem;
|
|
|
+ }
|
|
|
+
|
|
|
+ .count1 {
|
|
|
+ color: RGBA(250, 160, 18, 1);
|
|
|
+ }
|
|
|
+
|
|
|
+ .count2 {
|
|
|
+ color: RGBA(100, 218, 255, 1);
|
|
|
+ }
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+.icon_info {
|
|
|
+ background: no-repeat;
|
|
|
+
|
|
|
+ // background-image: url("/static/images/overview/icon_info.png");
|
|
|
+ background-image: url("/static/images/overview/icon信息.png");
|
|
|
+
|
|
|
+ display: inline-block;
|
|
|
+ width: 2rem;
|
|
|
+ height: 3rem;
|
|
|
+ position: absolute;
|
|
|
+ left: 1.23rem;
|
|
|
+ top: 0.5rem;
|
|
|
+}
|
|
|
+
|
|
|
+.info_left {
|
|
|
+ background: no-repeat;
|
|
|
+
|
|
|
+ background-image: url("/static/images/overview/info_left.png");
|
|
|
+ // background-image: url("/static/images/overview/左侧主信息.png");
|
|
|
+
|
|
|
+ display: inline-block;
|
|
|
+ width: 10rem;
|
|
|
+ height: 2.5rem;
|
|
|
+ background-size: 100%;
|
|
|
+ position: absolute;
|
|
|
+ left: 2rem;
|
|
|
+}
|
|
|
+
|
|
|
+.info_main {
|
|
|
+ background: no-repeat;
|
|
|
+
|
|
|
+ background-image: url("/static/images/overview/info_main.png");
|
|
|
+ // background-image: url("/static/images/overview/右侧附属信息.png");
|
|
|
+
|
|
|
+ display: inline-block;
|
|
|
+ width: 13rem;
|
|
|
+ height: 2.5rem;
|
|
|
+ background-size: 100%;
|
|
|
+ position: absolute;
|
|
|
+ left: 12rem;
|
|
|
}
|
|
|
|
|
|
#hysyEchart {
|
|
|
- left: 1rem;
|
|
|
- top: 1rem;
|
|
|
- width: 32rem;
|
|
|
- height: 14rem;
|
|
|
+ left: -2rem;
|
|
|
+ top: 0.5rem;
|
|
|
+ width: 28rem;
|
|
|
+ height: 11.5rem;
|
|
|
}
|
|
|
|
|
|
.box {
|