Authored by 郭成尧

go-back

... ... @@ -65,6 +65,7 @@ class Grade {
res.render('grade/detail', {
module: 'activity',
page: 'grade-detail',
bgcolor: '#2b2b2b',
width750: true,
localCss: true,
title: '成长值'
... ...
<div class="grade-detail-page">
{{> grade/user-defined-header}}
<div id="gradeGraph" class="grade-graph"></div>
<div class="loading-mask" id="loadingMask">
<div class="loading-logo"></div>
... ...
... ... @@ -7,6 +7,7 @@ import 'echarts/lib/component/markLine';
import tip from 'plugin/tip';
import Page from 'yoho-page';
import graphOptions from './graph-options';
import yoho from 'yoho-app';
class GradeDetailPage extends Page {
constructor() {
... ... @@ -16,11 +17,13 @@ class GradeDetailPage extends Page {
levelStr: $('#levelStr'),
gradeGraph: $('#gradeGraph'),
gradeBillList: $('#gradeBillList'),
loadingMask: $('#loadingMask')
loadingMask: $('#loadingMask'),
navBack: $('.nav-back')
};
this.eGradeGraph = echarts.init(this.view.gradeGraph[0]);
this.eGradeGraph.on('click', this.monthDetailInit.bind(this));
this.view.navBack.on('click', this.back.bind(this));
this.beforeScroll = document.body.scrollTop;
this.year = 0;
... ... @@ -132,6 +135,13 @@ class GradeDetailPage extends Page {
this.monthDetailRender();
}
}
// 返回上一页
goBack() {
if (yoho.isApp) {
yoho.invokeMethod('go.back');
}
}
}
export default GradeDetailPage;
... ...
... ... @@ -13,7 +13,7 @@
top: 0;
left: 0;
z-index: 2;
background-color: #303030;
background-color: #2b2b2b;
display: flex;
flex-direction: column;
justify-content: center;
... ...