修改饼图颜色

This commit is contained in:
熊丽君
2021-12-09 10:27:09 +08:00
parent cb3aedd130
commit 61cdce82f1
3 changed files with 28 additions and 1 deletions

View File

@ -34,6 +34,7 @@ import rocketTit from '../components/rocketTit/index.vue'
import container2 from './components/container2/index.vue'
import bigScreenTabs from '../components/bigScreenTabs/index.vue'
import progressBar from '@/views/bigScreen/components/progress/index.vue'
import colorList from '@/utils/colorPalette'
// import {Liquid} from '@antv/g2plot';
// import resize from '../../dashboard/mixins/resize'
import echarts from 'echarts'
@ -59,6 +60,7 @@ export default {
{ value: 679, name: '类别七' },
{ value: 679, name: '类别八' },
],
colorList,
}
},
mounted() {
@ -83,6 +85,7 @@ export default {
trigger: 'item',
formatter: '{a} <br/>{b}: {c} ({d}%)',
},
color: this.colorList,
legend: {
data: ['类别一', '类别二', '类别三', '类别四', '类别五', '类别六', '类别七', '类别八'],
orient: 'vertical',

View File

@ -34,6 +34,7 @@ import rocketTit from '../components/rocketTit/index.vue'
import container2 from './components/container2/index.vue'
import bigScreenTabs from '../components/bigScreenTabs/index.vue'
import progressBar from '@/views/bigScreen/components/progress/index.vue'
import colorList from '@/utils/colorPalette'
// import {Liquid} from '@antv/g2plot';
// import resize from '../../dashboard/mixins/resize'
import echarts from 'echarts'
@ -49,7 +50,7 @@ export default {
},
data() {
return {
index: 0,
colorList,
}
},
mounted() {
@ -70,6 +71,7 @@ export default {
trigger: 'item',
formatter: '{a} <br/>{b}: {c} ({d}%)',
},
color: this.colorList,
legend: {
data: ['型号一', '型号二', '型号三', '型号四', '型号五', '型号六', '型号七', '型号八'],
orient: 'vertical',