Skip to content

Commit

Permalink
Pre-publish: 修复课表显示逻辑,修复个人信息获取逻辑
Browse files Browse the repository at this point in the history
  • Loading branch information
jeneser committed Jan 1, 2018
1 parent 6458d20 commit dcfa4a5
Showing 1 changed file with 11 additions and 10 deletions.
21 changes: 11 additions & 10 deletions pages/index/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -110,31 +110,32 @@ Page({
// 获取用户基本信息
this.getUserInfo();
if (this.data.bind) {
// 设置日期
this.setDate();
this.getCourse();
this.getTodayCourse();
this.initialize();
}
},

onShow: function() {
if (!this.data.todayCourse.length && this.data.bind) {
// 设置日期
this.setDate();
this.getCourse();
this.getTodayCourse();
this.initialize();
}
},

onPullDownRefresh: function() {
this.initialize();
wx.stopPullDownRefresh();
},

initialize: function() {
this.setDate();
this.getCourse();
this.getTodayCourse();
wx.stopPullDownRefresh();
},

getUserInfo: function() {
var store = app.store;
var store = {};

app.checkInfo();
store = app.store;

if (JSON.stringify(store) !== '{}') {
this.setData({
Expand Down

0 comments on commit dcfa4a5

Please sign in to comment.