...
|
...
|
@@ -31,6 +31,7 @@ class GradeDetailPage extends Page { |
|
|
this.page = 0;
|
|
|
this.requesting = false;
|
|
|
this.noListData = false;
|
|
|
this.graphData = {};
|
|
|
|
|
|
this.graphRender();
|
|
|
this.monthDetailRender(true);
|
...
|
...
|
@@ -59,13 +60,12 @@ class GradeDetailPage extends Page { |
|
|
graphRender() {
|
|
|
this.ajax({
|
|
|
url: '/activity/grade/graph'
|
|
|
}).then(graphData => {
|
|
|
if (graphData.code === 200) {
|
|
|
if (graphData) {
|
|
|
this.view.levelStr.text(graphData.levelStr);
|
|
|
this.eGradeGraph.setOption(graphOptions(graphData.graphData));
|
|
|
this.view.loadingMask.addClass('hide');
|
|
|
}
|
|
|
}).then(result => {
|
|
|
if (result.code === 200) {
|
|
|
this.graphData = result.graphData;
|
|
|
this.view.levelStr.text(result.levelStr);
|
|
|
this.eGradeGraph.setOption(graphOptions(result.graphData));
|
|
|
this.view.loadingMask.addClass('hide');
|
|
|
} else {
|
|
|
setTimeout(() => {
|
|
|
this.graphRender();
|
...
|
...
|
@@ -78,7 +78,15 @@ class GradeDetailPage extends Page { |
|
|
* 月度数据初始化
|
|
|
*/
|
|
|
monthDetailInit(event) {
|
|
|
let tapData = event.data;
|
|
|
let tapData = {};
|
|
|
|
|
|
if (event.componentType === 'xAxis') {
|
|
|
let whichLine = Number(event.event.target.anid.split('_')[1]);
|
|
|
|
|
|
tapData = this.graphData.seriesData[whichLine];
|
|
|
} else {
|
|
|
tapData = event.data;
|
|
|
}
|
|
|
|
|
|
this.year = tapData.year;
|
|
|
this.month = tapData.month;
|
...
|
...
|
|