Toggle navigation
By
b***m
2019-08-25 18:01:59
脚本
16
21
作品使用的第三方脚本
数据管理
上传数据
支持小于 5M 任意格式(csv, xlsx, json, xml, ...)的数据文件
上传后可以通过生成的文件链接异步获取托管的数据。
历史数据
0 条
无历史数据
代码修改记录
信息提示
保存作品
对当前截图不满意?你还可以
上传本地截图
重新截图
作品名称
作品描述
标签
geo
grid
legend
markLine
markPoint
bar
effectScatter
line
lines
map
timeline
title
toolbox
tooltip
visualMap
作品默认版本
最新
16
15
14
13
12
11
10
9
8
7
6
5
4
3
2
1
20:11:45
图表已生成
整理代码
刷新
代码
var option = { backgroundColor: '#043065', tooltip: { trigger: 'axis', textStyle: { align: 'left', color: '#5cc1ff', // color: '#fff', fontSize: '16' }, backgroundColor: 'rgba(15, 52, 135, 0.5)', borderWidth: '1', borderColor: '#5cc1ff', extraCssText: 'box-shadow: 0 0 10px rgba(255, 255, 255, 0.7);', formatter: function(params) { return params[0].name + "
" + "
苹果批发价格涨跌幅:
" + "
" + params[0].value + "%
"; } }, label: { normal: { textStyle: { color: "#cccccc" } }, emphasis: { textStyle: { color: "#cccccc" } } }, grid: {//设置图表靠边位置 left: '10%', right: '10%', bottom: '10%', top: '50', containLabel: true }, yAxis: { type: 'category', axisLine: { show:false, lineStyle: { color: '#8ac7ff' } }, axisTick: { show: false, interval: 0, alignWithLabel: true }, axisLabel: { interval: 0, rotate: '0', textStyle: { fontSize: 10, color: '#cee8ff' } }, data: ['功能点10', '功能点9', "功能点8", '功能点7', "功能点6",'功能点5', '功能点4', "功能点3", '功能点2', "功能点1"], splitLine: { show: false//, "机构6", "机构7", "机构8", "机构9", "机构10" } }, xAxis: { type: 'value', name: '', splitLine: { show: false, lineStyle: { color: ['rgba(138, 199, 255, .2)'] } }, axisTick: { show: false }, axisLabel: { show: false }, axisLine: { show:false, lineStyle: { color: '#01c2db' } } }, series: [{ name: '数量', type: 'bar', stack: '总量', barWidth: 10, label: { normal: { show: true, color:'#fff', position: 'right', formatter: "{c}" } }, itemStyle: { normal: { barBorderWidth: '0', barBorderRadius: [10, 10, 10, 10], barBorderColor: 'rgb(0,255,132)', color: new echarts.graphic.LinearGradient(0, 0, 1, 0, [{ offset: 0, color: 'rgba(0,255,132, .4)'// rgba(255,255,132, .4),rgba(0,0,255, .4) }, { offset: 1, color: 'rgb(0,255,132)' //#0000F,F#ffbd19 }]) }, emphasis: { barBorderWidth: '1', barBorderColor: 'rgb(0,255,132)' // color: 'rgba(26,177,98,.8)' } }, // 顺序 从下向上 传入 data: [370, 450, 550, 700,790,1250, 1278,1600, 1820,2335]//,1250, 1278,1600, 1820,2335 }] }; // rank1.setOption(rankOption1); // rank2.setOption(rankOption2); // // echarts 图表初始化完成,无关后台数据交互 // function rankInit(upData, DownData) { // rank1.setOption({ // yAxis: { // data: ['宁夏', '四川', "内蒙古", '新疆', "江苏", "山西", "陜西", "河南", "河北", "山东"], // }, // series: [{ // // 顺序 从下向上 传入 // data: upData // }] // }); // rank2.setOption({ // yAxis: { // data: ['西藏', '黑龙江', "河北", '陜西', "山东", "武汉", "天津", "内蒙", "河南", "云南"], // }, // series: [{ // // 顺序 从下向上 传入 // data: DownData // }] // }); // } // // 页面初始化 // rankInit(fakeData(10, 100), fakeData(10, 100));