Merge remote-tracking branch 'origin/master'

This commit is contained in:
liuwu 2024-03-04 14:51:04 +08:00
commit a76d95e089
2 changed files with 151 additions and 61 deletions

View File

@ -338,9 +338,7 @@
}
.center_footer_content{
width: 100%;
height: 24vh;
overflow: hidden;
position: relative;
height: 25vh;
}
.item_inline{
margin: 0;

View File

@ -93,14 +93,14 @@
</div>
<div class="main_footer">
<div class="main_footer_center">
<div class="center_footer_item">
<div class="center_footer_item" style="width: 35%">
<div class="echarts_title">
<span></span>
<span>部门完成情况</span>
</div>
<div class="echarts_footer_wrap" id="bottom_left_echarts"></div>
</div>
<div class="center_footer_item">
<div class="center_footer_item" style="width: 65%">
<div class="echarts_title">
<span></span>
<span>资源交易数据统计</span>
@ -113,8 +113,11 @@
<span class="trade_all_num">全年累计交易数0</span>
<span class="trade_all_money" style="margin-left: 20px">全年累计交易额0万元</span>
</div>
<div class="center_footer_content" style="height: 30vh" id="center_footer_two">
<div style="margin: 1% 0;color: #fff;font-size: 12px;width: 100%;text-align: center">
<span class="trade_all_num">历年累计交易数0</span>
<span class="trade_all_money" style="margin-left: 20px">历年累计交易额0万元</span>
</div>
<div class="center_footer_content" id="center_footer_chart"></div>
</div>
</div>
</div>
@ -775,65 +778,154 @@
data: item.array
})
})
let chart = echarts.init(document.getElementById('center_footer_two'));
let option = {
tooltip: {
trigger: 'item',
formatter:function(params){
let _retTips = params.marker+' '+params.seriesName+'<br/>交易额:'+params.value.toFixed(4)+'万元<br/>';
_allNumData.forEach(item => {
if(item.name === params.seriesName){
Object.keys(item.obj1).forEach(key => {
if(params.name === String(key)){
_retTips+='交易数:'+item.obj1[key]
}
})
}
})
return _retTips;
}
},
legend: {
type:'scroll',
bottom:'bottom',
textStyle: {
color: "#ffffff"
},
pageIconColor:'#fff',
pageIconInactiveColor:'#fff',
pageTextStyle:{
color: "#ffffff"
}
},
grid: {
top: "5%",
left: '5%',
right: '5%',
bottom: '15%',
containLabel: true
},
xAxis: {
type: 'value',
boundaryGap: [0, 0.01],
axisLabel:{
color:'#fff'
}
},
yAxis: {
type: 'category',
data: _yData,
axisLabel:{
color:'#fff'
}
},
series: _sData
};
// 使用刚指定的配置项和数据显示图表。
chart.setOption(option);
//加载饼状图
loadCirCleData('center_footer_chart')
}
})
}
//加载饼状图
function loadCirCleData(dom){
let chart = echarts.init(document.getElementById(dom));
let option = {
title:[
{
subtext: '当月累计交易',
left: '24.5%',
top: '75%',
textAlign: 'center',
subtextStyle:{
color:'#fff'
}
},
{
subtext: '当年累计交易',
left: '49.5%',
top: '75%',
textAlign: 'center',
subtextStyle:{
color:'#fff'
}
},
{
subtext: '历年累计交易',
left: '74.5%',
top: '75%',
textAlign: 'center',
subtextStyle:{
color:'#fff'
}
},
],
tooltip: {
trigger: 'item'
},
legend: {
top: '5%',
left: 'center',
textStyle: {
color: "#ffffff"
},
},
dataset: [
{
source: [
['', 'Sales', 'Price', 'Year'],
['工程招投标', 235, 5, 2011],
['政府采购', 341, 25, 2011],
['产权交易', 122, 29, 2011],
['工程招投标', 255, 7, 2012],
['政府采购', 241, 27, 2012],
['产权交易', 102, 34, 2012],
['工程招投标', 395, 4, 2013],
['政府采购', 281, 31, 2013],
['产权交易', 92, 39, 2013],
]
},
{
transform: {
type: 'filter',
config: { dimension: 'Year', value: 2011 }
}
},
{
transform: {
type: 'filter',
config: { dimension: 'Year', value: 2012 }
}
},
{
transform: {
type: 'filter',
config: { dimension: 'Year', value: 2013 }
}
}
],
series: [
{
type: 'pie',
name:'2022',
radius: 50,
center: ['50%', '25%'],
datasetIndex: 1,
labelLine: {
show: false
},
label: {
show: false,
},
},
{
type: 'pie',
radius: 50,
center: ['50%', '50%'],
datasetIndex: 2,
labelLine: {
show: false
},
label: {
show: false,
},
},
{
type: 'pie',
radius: 50,
center: ['50%', '75%'],
datasetIndex: 3,
labelLine: {
show: false
},
label: {
show: false,
},
}
],
// Optional. Only for responsive layout:
media: [
{
option: {
series: [
{ center: ['25%', '50%'] },
{ center: ['50%', '50%'] },
{ center: ['75%', '50%'] }
]
}
},
{
option: {
series: [
{ center: ['50%', '25%'] },
{ center: ['50%', '50%'] },
{ center: ['50%', '75%'] }
]
}
}
]
};
// 使用刚指定的配置项和数据显示图表。
chart.setOption(option);
}
//文字上下滚动
function autoScroll(obj){
$(obj).find(".item_inline:first").animate({