| | |
| | | }; |
| | | const option = {...defaultOption, ...data}; |
| | | return { |
| | | color: ['#5470c6', '#91cc75', '#fac858', '#73c0de', '#3ba272', '#fc8452', '#9a60b4', '#ea7ccc'], |
| | | title: { |
| | | text: '' |
| | | }, |
| | |
| | | }, |
| | | legend: { |
| | | data: [] |
| | | }, |
| | | toolbox: { |
| | | show: false, |
| | | feature: { |
| | | saveAsImage: { |
| | | title: "保存为图片" |
| | | } |
| | | } |
| | | }, |
| | | grid: option.grid, |
| | | xAxis: { |
| | |
| | | if(isNaN(min)) { |
| | | return 0; |
| | | }else { |
| | | return (min * option.minRatio).toHold(3); |
| | | return option.minRatio === 1?min:(min * option.minRatio).toHold(3); |
| | | } |
| | | }, |
| | | max(data) { |
| | |
| | | if(isNaN(max)) { |
| | | return 1; |
| | | }else { |
| | | return (max * option.maxRatio).toHold(3); |
| | | return option.maxRatio ===1?max:(max * option.maxRatio).toHold(3); |
| | | } |
| | | }, |
| | | axisLabel: { |