var titleText;if (window.FR) { titleText = window.FR && window.FR.remoteEvaluate("$zd");}; /*try{var nf = FR.remoteEvaluate('$nf');}catch(err){}//试用于决策报表控件*/var TABLE_DATA = getData('data1');var seriesNames = ; // 获取系列名var columnValues = TABLE_DATA.slice(1);var categoryNames = columnValues.map(function(value){return value;}); // 获取分类名var data = columnValues.map(function(value){return value;}); // 获取分类名var max = data.reduce((total,value,index,array)=>total>value?total:value);for (var i = 0,dataShadow = ; i < columnValues.length; i++) { dataShadow.push(0.5);}; //将最大值存入空数组形成阴影option = { grid: { //图表位置 left:'5%', top:'10%', width:"92%", // 宽度 height:"83%"// 高度 }, /* legend: { // icon: "emptyCircle", itemGap: 20, x:'right', y:'top', data:, icon: "image:///webroot/help/picture/store/icon-压力.png" },{ name: seriesNames, icon: "image:///webroot/help/picture/store/icon-流量.png" }], padding:, textStyle:{ color: '#90D3FF', fontSize: '28', fontFamily: 'regular' } },*/ tooltip: { //提示框 trigger: 'axis', extraCssText: 'background: rgba(1,22,46,0.8);box-shadow: inset 0px 0px 40px rgba(7, 48, 89, 0.8);border-radius: 0px 0px 0px 0px;border: 2px solid #073059;', //边框阴影 axisPointer: { //指示线为线 type: 'line', lineStyle: { type: 'dashed', width: 1, //设置线宽度 color: 'rgba(10, 167, 255, 0.2)' } }, icon: "emptyCircle", formatter: function(params) { var pc = ; var aa=; var tip = '  '+params.name; return tip += '  '+params.marker+'  '+params.seriesName + ": " + params.value + '  Mpa'+'  '+params.marker+'  '+params.seriesName + ": " + params.value + '  Mpa'; }, textStyle:{ /* rich: { a: {height: 28}, b: {height: 28}, c: {height: 28} },*/ color: 'rgba(255, 255, 255, 1)', fontSize: '11', lineheight:'11', fontFamily: 'Arial' } }, dataset: {source: TABLE_DATA}, xAxis: { type: 'category', axisLine: {"show":false},//轴线 axisTick:{"show":false }, //刻度线 data: categoryNames, axisLabel: { //轴标签 show: true, // interval:0, //标签强制全部显示不重叠则设置为0 rotate:0, //标签倾斜 formatter:function(value){ return `${value.slice(11,16)}`; //截取前5位 }, textStyle: { color: 'rgba(167, 227, 255, 0.3)', fontSize:'11', fontFamily: 'Arial' } } }, yAxis: { name:'(Mpa)', //轴标题 nameTextStyle: { //标题字体样式 color: 'rgba(167, 227, 255, 0.3)', fontSize:'11', fontFamily: 'Arial', padding: }, splitLine: { show: true, lineStyle: { type: 'dashed', width: 1, //设置线宽度 color: 'rgba(10, 167, 255, 0.2)' } }, //网格线 axisLine: {show:false}, axisTick: {show:false}, axisLabel: { show: true, formatter:function(value){ return `${value.toFixed(2)}`; }, textStyle: { color: 'rgba(167, 227, 255, 0.3)', fontSize:'11', fontFamily: 'Arial' } } }, // 声明多个 bar 系列,默认情况下,每个系列会自动对应到 dataset 的每一列。 series: , type: 'bar', stack: 'Ad', //yAxisIndex: 0, //选用哪个Y轴 barWidth: 5, //柱子宽度 // barGap: '0%', //两个柱子间距 itemStyle: { barBorderRadius: 1, //柱子圆角 color: 'transparent' } },{ name:seriesNames, type: 'bar', stack: 'Ad', //yAxisIndex: 0, //选用哪个Y轴 barWidth: 5, //柱子宽度 // barGap: '0%', //两个柱子间距 itemStyle: { barBorderRadius: 10, //柱子圆角 color: new echarts.graphic.LinearGradient( 0, 0, 0, 1, ) } }]};