This commit is contained in:
2023-07-11 15:31:36 +08:00
parent 847b190462
commit 52b591a6d5
5 changed files with 259 additions and 11 deletions

View File

@@ -157,11 +157,11 @@
<!-- eChart -->
<div style="margin-top: 23px;margin-left: 40px;">
<el-card style="border: none;height:450px">
<el-tabs v-model="activeName" @tab-click="handleClick">
<el-tab-pane label="日期统计" name="first">日期统计</el-tab-pane>
<el-tab-pane label="月度统计" name="second">月度统计</el-tab-pane>
<el-tab-pane label="年度统计" name="third">年度统计</el-tab-pane>
</el-tabs>
<!-- <el-tabs v-model="activeName" @tab-click="handleClick">-->
<!-- <el-tab-pane label="日期统计" name="first">日期统计</el-tab-pane>-->
<!-- <el-tab-pane label="月度统计" name="second">月度统计</el-tab-pane>-->
<!-- <el-tab-pane label="年度统计" name="third">年度统计</el-tab-pane>-->
<!-- </el-tabs>-->
<div ref="echart2" style="width: 20vw;height: 30vh">
</div>
@@ -328,13 +328,13 @@ export default {
that.date=res.data.Date;
that.Month=res.data.Month;
that.Year=res.data.Year;
Object.keys(that.date).forEach(key=>{
that.datecate.push(that.date[key]['date']);
let num = parseInt(that.date[key]['num']);
let datefac = {"value":num,"date":that.date[key]['date'],"type":"line"};
console.log(datefac);
console.log(that.date);
for(let i=0;i<that.date.length;i++){
that.datecate.push(that.date[i]['date']);
let num = parseInt(that.date[i]['num']);
let datefac = {"value":num,"date":that.date[i]['date'],"type":"line"};
that.dateLine.push(datefac);
})
}
console.log(that.dateLine);
console.log(that.datecate);
});