11.13带单位

master
zz 2 weeks ago
parent 9c397ddcf2
commit eb69219cab

@ -102,6 +102,8 @@ const eChartOptions = reactive<EChartsOption>({
series: [ series: [
{ {
name: '换电车辆', name: '换电车辆',
label:{show:true,position:'top',textStyle:{color:'#000000'}, formatter:function(data){
return data.value+'辆'}},
type: 'bar', type: 'bar',
data: [70,266,210,35,112,98,91] data: [70,266,210,35,112,98,91]
} }

@ -20,7 +20,7 @@
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import dayjs, { Dayjs } from 'dayjs' import dayjs, { Dayjs } from 'dayjs'
import { EChartsOption } from 'echarts' import { color, EChartsOption } from 'echarts'
import * as TradeStatisticsApi from '@/api/mall/statistics/trade' import * as TradeStatisticsApi from '@/api/mall/statistics/trade'
import { fenToYuan } from '@/utils' import { fenToYuan } from '@/utils'
import { formatDate } from '@/utils/formatTime' import { formatDate } from '@/utils/formatTime'
@ -107,9 +107,13 @@ const eChartOptions = reactive<EChartsOption>({
} }
], ],
series: [ series: [
{ {
name: '充换电营收', name: '充换电营收',
type: 'bar', type: 'bar',
label:{show:true,position:'top',textStyle:{color:'#000000'},formatter:function(data){
return data.value+'元'
}},
data: [ 29792.40, 18646.14, 15153.60,14488.05,7735.55,6667.58,7035.60], data: [ 29792.40, 18646.14, 15153.60,14488.05,7735.55,6667.58,7035.60],
markPoint: { markPoint: {
data: [ data: [
@ -124,6 +128,8 @@ const eChartOptions = reactive<EChartsOption>({
{ {
name: '充换电量', name: '充换电量',
type: 'bar', type: 'bar',
label:{show:true,position:'top',textStyle:{color:'#000000'},formatter:function(data){
return data.value+'kwh'}},
data: [ 35636.84,18949.33,18126.32,16062.14,9609.38,7620.10,7680.79], data: [ 35636.84,18949.33,18126.32,16062.14,9609.38,7620.10,7680.79],
markPoint: { markPoint: {
data: [ data: [

@ -20,7 +20,11 @@ const loading = ref(false) // 加载中
/** 会员终端统计图配置 */ /** 会员终端统计图配置 */
const terminalChartOptions = reactive<EChartsOption>({ const terminalChartOptions = reactive<EChartsOption>({
tooltip: {}, tooltip: {
trigger: "item",
formatter: "{b}:{d}%"
},
legend: { legend: {
orient: 'vertical', orient: 'vertical',
@ -32,7 +36,8 @@ const terminalChartOptions = reactive<EChartsOption>({
name: '占比', name: '占比',
type: 'pie', type: 'pie',
label: { label: {
show: true show: true,
formatter:"{b}: {d}%"
}, },
labelLine: { labelLine: {
show: true show: true

Loading…
Cancel
Save