|
@@ -7,7 +7,7 @@ Page({
|
|
isNeedlogin: false,
|
|
isNeedlogin: false,
|
|
// 课程轮播
|
|
// 课程轮播
|
|
bnrUrl: [{
|
|
bnrUrl: [{
|
|
- clasImg:"../../images/zbfm.png"
|
|
|
|
|
|
+ clasImg: "../../images/zbfm.png"
|
|
}],
|
|
}],
|
|
gridArr: [{
|
|
gridArr: [{
|
|
url: "/images/icon1.png",
|
|
url: "/images/icon1.png",
|
|
@@ -25,8 +25,8 @@ Page({
|
|
url: "/images/icon4.png",
|
|
url: "/images/icon4.png",
|
|
name: "测试答卷",
|
|
name: "测试答卷",
|
|
isread: true
|
|
isread: true
|
|
- }],
|
|
|
|
- xczsArr: []
|
|
|
|
|
|
+ }]
|
|
|
|
+ // xczsArr: []
|
|
},
|
|
},
|
|
gomyClass(e) {
|
|
gomyClass(e) {
|
|
console.log(e.currentTarget.dataset.item.isActive, "我是测试跳转的")
|
|
console.log(e.currentTarget.dataset.item.isActive, "我是测试跳转的")
|
|
@@ -180,6 +180,27 @@ Page({
|
|
}
|
|
}
|
|
})
|
|
})
|
|
},
|
|
},
|
|
|
|
+ getfour1() {
|
|
|
|
+ wx.request({
|
|
|
|
+ url: app.globalData.publicUrl + '/wx/course/listCategory',
|
|
|
|
+ method: "post",
|
|
|
|
+ success: (res) => {
|
|
|
|
+ // console.log(JSON.stringify(this.data.xczsArr))
|
|
|
|
+ // console.log(JSON.stringify(res.data.list))
|
|
|
|
+ if (this.data.xczsArr.sort().toString() == res.data.list.sort().toString()) {
|
|
|
|
+ console.log("我和上次一样")
|
|
|
|
+ } else {
|
|
|
|
+ console.log("我和上次不一样")
|
|
|
|
+ this.setData({
|
|
|
|
+ xczsArr: res.data.list
|
|
|
|
+ })
|
|
|
|
+ }
|
|
|
|
+ },
|
|
|
|
+ fail(res) {
|
|
|
|
+ console.log(res, "调取请求公开课失败")
|
|
|
|
+ }
|
|
|
|
+ })
|
|
|
|
+ },
|
|
getRedPoint1(sessionKey) {
|
|
getRedPoint1(sessionKey) {
|
|
let completeStatus1 = `gridArr[${0}].isread`;
|
|
let completeStatus1 = `gridArr[${0}].isread`;
|
|
let completeStatus2 = `gridArr[${1}].isread`;
|
|
let completeStatus2 = `gridArr[${1}].isread`;
|
|
@@ -231,13 +252,16 @@ Page({
|
|
},
|
|
},
|
|
onReady: function () {},
|
|
onReady: function () {},
|
|
async onShow() {
|
|
async onShow() {
|
|
- // console.log("我调用了onShow")
|
|
|
|
const sessionKey = await tools.checkSessionAndLogin();
|
|
const sessionKey = await tools.checkSessionAndLogin();
|
|
this.getBanner(sessionKey);
|
|
this.getBanner(sessionKey);
|
|
this.getjjLength(sessionKey);
|
|
this.getjjLength(sessionKey);
|
|
this.getwqLength(sessionKey);
|
|
this.getwqLength(sessionKey);
|
|
|
|
+ this.getRedPoint1(sessionKey);
|
|
|
|
+ this.getRedPoint4(sessionKey);
|
|
|
|
+ this.getfour1();
|
|
|
|
+ },
|
|
|
|
+ async onLoad() {
|
|
|
|
+ // console.log("我调用了onShow")
|
|
this.getfour();
|
|
this.getfour();
|
|
- this.getRedPoint1(sessionKey)
|
|
|
|
- this.getRedPoint4(sessionKey)
|
|
|
|
},
|
|
},
|
|
})
|
|
})
|