Commit b3a0d43b by kyle

日历在手机上不显示的问题

parent 3222649e
......@@ -157,13 +157,13 @@
this.studyInfos = res['data']['studyInfos'];
let categories=[];
let data = [];
if(this.studyInfos.length >0){
if(this.studyInfos && this.studyInfos.length >0){
for(let j=0;j<this.studyInfos.length;j++){
categories.push(this.studyInfos[j].month.split('-')[1]);
data.push({value:this.studyInfos[j]['studyTime'],color:'#9EB4FF'});
}
this.currentDate = this.month = this.studyInfos[this.studyInfos.length - 1].month;
}
this.currentDate = this.month = this.studyInfos[this.studyInfos.length - 1].month;
this.chartData.categories = categories;
this.chartData.series = [{name:'月',data:data}];
this.userStudyTime()
......@@ -217,7 +217,7 @@
this.userStudyTime();
}
},
mounted() {
onLoad() {
this.userStudyCount()
}
}
......
......@@ -61,7 +61,6 @@
if(res['success']){
this.userStudyLists = res['data']['userStudyTimeInfos'];
}
console.log(res)
})
},
switchTab(type){
......
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