Commit 68cb7a01 authored by zhengke's avatar zhengke

增加特殊节假日统计

parent 93165a34
This diff is collapsed.
<style>
.sexChart{
height: 100%;
}
</style>
<template>
<div class="sexChart" ref="sexChart">
</div>
</template>
<script>
export default {
props: ["dataList","totalCount"],
data() {
return {
nameList:[],
data:[],
};
},watch:{
},
mounted() {
if(this.dataList&&this.dataList.length>0){
this.data=[];
this.dataList.forEach(x => {
this.nameList.push(x.FestivalName);
let obj={
value:0,
name:''
}
// obj.value=((x.OrderCount / this.totalCount * 10000) / 100.00).toFixed(1);
obj.value=x.OrderCount;
obj.name=x.FestivalName
this.data.push(obj);
});
}
this.init()
let myChart = this.$echarts.init(this.$refs.sexChart);
window.addEventListener("resize", () => {
myChart.resize();
});
},
methods: {
init(){
let myChart = this.$echarts.init(this.$refs.sexChart);
let option = {
title: {
text: '',
subtext: '',
left: 'center'
},
tooltip: {
trigger: 'item',
formatter: '{a} <br/>{b} : {c} ({d}%)'
},
legend: {
orient: 'vertical',
left: 'left',
data: []
},
series: [
{
name: '访问来源',
type: 'pie',
radius: '55%',
center: ['50%', '60%'],
data: this.data,
emphasis: {
itemStyle: {
shadowBlur: 10,
shadowOffsetX: 0,
shadowColor: 'rgba(0, 0, 0, 0.5)'
}
}
}
]
};
myChart.setOption(option);
}
}
}
</script>
\ No newline at end of file
...@@ -155,6 +155,14 @@ export default new Router({ ...@@ -155,6 +155,14 @@ export default new Router({
title: "出游类型统计" title: "出游类型统计"
} }
}, },
{
path: "/festivalOrderList",
name: "festivalOrderList",
component: ()=>import('./components/statistics/festivalOrderList.vue'),
meta: {
title: "特殊节假日统计"
}
},
{ {
path: "/marriage", path: "/marriage",
name: "marriage", name: "marriage",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment