|
|
@ -200,6 +200,9 @@ export class echartsComponent implements OnInit { |
|
|
|
} |
|
|
|
} |
|
|
|
//获取数据
|
|
|
|
//获取数据
|
|
|
|
async getechartsData(){ |
|
|
|
async getechartsData(){ |
|
|
|
|
|
|
|
this.datayuex=[] |
|
|
|
|
|
|
|
this.datayuey=[] |
|
|
|
|
|
|
|
this.zongcount=0 |
|
|
|
let paramdata={ |
|
|
|
let paramdata={ |
|
|
|
planStatus:this.tid=='pieone'?'': this.type, |
|
|
|
planStatus:this.tid=='pieone'?'': this.type, |
|
|
|
PlanCategory:this.tid=='pieone'?this.type:'', |
|
|
|
PlanCategory:this.tid=='pieone'?this.type:'', |
|
|
@ -208,7 +211,7 @@ export class echartsComponent implements OnInit { |
|
|
|
} |
|
|
|
} |
|
|
|
await this.echartsData.getData(paramdata,`/api/StatisticsAnalysis/Trends`) |
|
|
|
await this.echartsData.getData(paramdata,`/api/StatisticsAnalysis/Trends`) |
|
|
|
this.tabledata=JSON.parse(JSON.stringify(this.echartsData.allDate)) |
|
|
|
this.tabledata=JSON.parse(JSON.stringify(this.echartsData.allDate)) |
|
|
|
console.log(this.tabledata) |
|
|
|
//console.log(this.tabledata)
|
|
|
|
for(var i=0;i<this.tabledata[0].length;i++){ |
|
|
|
for(var i=0;i<this.tabledata[0].length;i++){ |
|
|
|
if(this.tabledata[0][i].month>=this.echartsData.selectStartMonth||this.tabledata[0][i].month<=this.echartsData.selectEndMonth){ |
|
|
|
if(this.tabledata[0][i].month>=this.echartsData.selectStartMonth||this.tabledata[0][i].month<=this.echartsData.selectEndMonth){ |
|
|
|
this.datayuex.push(this.tabledata[0][i].month) |
|
|
|
this.datayuex.push(this.tabledata[0][i].month) |
|
|
@ -231,6 +234,7 @@ export class echartsComponent implements OnInit { |
|
|
|
if (e=='year') { |
|
|
|
if (e=='year') { |
|
|
|
//this.oneInit(this.dataYearX,this.dataYearY)
|
|
|
|
//this.oneInit(this.dataYearX,this.dataYearY)
|
|
|
|
this.dataYearX=[] |
|
|
|
this.dataYearX=[] |
|
|
|
|
|
|
|
this.dataYearY=[] |
|
|
|
this.echartsData.selectType=2 |
|
|
|
this.echartsData.selectType=2 |
|
|
|
this.zongcount=0 |
|
|
|
this.zongcount=0 |
|
|
|
let paramdata={ |
|
|
|
let paramdata={ |
|
|
@ -252,7 +256,7 @@ export class echartsComponent implements OnInit { |
|
|
|
this.dataYearX.forEach((value,index,array)=>{ |
|
|
|
this.dataYearX.forEach((value,index,array)=>{ |
|
|
|
this.dataYearX[index]=this.dataYearX[index]+'年' |
|
|
|
this.dataYearX[index]=this.dataYearX[index]+'年' |
|
|
|
}) |
|
|
|
}) |
|
|
|
this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.datayuey,this.datayuex)
|
|
|
|
//this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.datayuey,this.datayuex)
|
|
|
|
//this.oneInit()
|
|
|
|
//this.oneInit()
|
|
|
|
this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.dataYearY,this.dataYearX) |
|
|
|
this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.dataYearY,this.dataYearX) |
|
|
|
this.twoInit(this.dataYearX,this.dataYearY) |
|
|
|
this.twoInit(this.dataYearX,this.dataYearY) |
|
|
@ -263,6 +267,7 @@ export class echartsComponent implements OnInit { |
|
|
|
this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.datayuey,this.datayuex) |
|
|
|
this.tiaoshiPao=this.echartsData.qipao(this.tiaoshiPao,this.datayuey,this.datayuex) |
|
|
|
//this.oneInit()
|
|
|
|
//this.oneInit()
|
|
|
|
this.echartsData.selectType=0 |
|
|
|
this.echartsData.selectType=0 |
|
|
|
|
|
|
|
this.getechartsData() |
|
|
|
this.twoInit(this.datayuex,this.datayuey) |
|
|
|
this.twoInit(this.datayuex,this.datayuey) |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|