From ecbc81c918a288dc752b1634b3f545f795d992aa Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期三, 20 三月 2024 16:15:41 +0800 Subject: [PATCH] 图书分类,图书列表样式修改,答题器优化 --- pages/personalCenter/index.js | 64 +++++++++++++++++++++---------- 1 files changed, 43 insertions(+), 21 deletions(-) diff --git a/pages/personalCenter/index.js b/pages/personalCenter/index.js index e086528..cda03ed 100644 --- a/pages/personalCenter/index.js +++ b/pages/personalCenter/index.js @@ -3,63 +3,63 @@ { title: '鎴戠殑璁㈠崟', icon: '/static/images/personal/order.png', - url: '/pages/personalCenter/myOrder/index', + url: '/packagePersonal/pages/myOrder/index', type: 'order', }, { title: '婵�娲诲晢鍝�', icon: '/static/images/personal/jihuo.png', - url: '/pages/personalCenter/activateProduct/index', + url: '/packagePersonal/pages/activateProduct/index', type: 'activateProduct', }, { title: '鎴戠殑璇佷功', icon: '/static/images/personal/certificate.png', - url: '/pages/personalCenter/certificate/index', + url: '', type: 'certificate', }, { title: '鎴戠殑鏀惰棌', icon: '/static/images/personal/wodeshoucang.png', - url: '/pages/personalCenter/myCollection/index', + url: '/packagePersonal/pages/myCollection/index', type: 'collection', }, { title: '鎴戠殑涓嬭浇', icon: '/static/images/personal/download.png', - url: '/pages/personalCenter/downloads/index', + url: '/packagePersonal/pages/downloads/index', type: 'download', }, { title: '鏍蜂功鐢宠', icon: '/static/images/personal/yangshushenqing.png', - url: '/pages/personalCenter/sampleBooks/index', + url: '/packagePersonal/pages/sampleBooks/index', type: 'sampleBook', - }, - { - title: '鍑轰功鐢宠', - icon: '/static/images/personal/chushu.png', - url: '/pages/personalCenter/publishBooks/index', - type: 'publishBooks', }, { title: '鎴戠殑涓婁紶', icon: '/static/images/personal/upload.png', url: '', type: 'upload', + }, + { + title: '鍑轰功鐢宠', + icon: '/static/images/personal/chushu.png', + url: '/packagePersonal/pages/publishBooks/index', + type: 'publishBooks', } ]; const moreMenu = [ { title: '鎴戠殑娑堟伅', icon: '/static/images/personal/notification.png', - url: '/pages/personalCenter/myMassage/index', + url: '/packagePersonal/pages/myMassage/index', type: 'message', }, { title: '寤鸿涓庡弽棣�', icon: '/static/images/personal/feedback.png', - url: '/pages/personalCenter/feedback/index', + url: '/packagePersonal/pages/feedBack/index', type: 'feedback', } ]; @@ -67,13 +67,13 @@ { title: '鍏充簬鎴戜滑', icon: '/static/images/personal/about.png', - url: '', + url: '/packagePersonal/pages/aboutUs/index?types=jsek_aboutUs', type: 'aboutUs', }, { title: '鑱旂郴鎴戜滑', icon: '/static/images/personal/contact.png', - url: '', + url: '/packagePersonal/pages/aboutUs/index?types=jsek_contactUs', type: 'contact', } ]; @@ -83,6 +83,7 @@ * 椤甸潰鐨勫垵濮嬫暟鎹� */ data: { + isWhite: false, show: false, userInfo: { avatarUrl: @@ -104,6 +105,7 @@ * 鐢熷懡鍛ㄦ湡鍑芥暟--鐩戝惉椤甸潰鍔犺浇 */ onLoad(options) { + console.log(options); }, @@ -122,9 +124,11 @@ selected: 4 //杩欎釜鏁板瓧鏄綋鍓嶉〉闈㈠湪tabBar涓璴ist鏁扮粍鐨勭储寮� }) } - if (this.data.userInfo) { - this.getTeacherInfo() - } + this.getTeacherInfo() + } else { + wx.navigateTo({ + url: "/pages/testLogin/index", + }); } }, /** @@ -159,7 +163,8 @@ } } app.MG.ugc.getTopicMessageList(data).then((res) => { - const resData = res.datas.find((i) => i.appUserCreator.userId == userId.value) + console.log(this.data.userInfo, "userInfo") + const resData = res.datas.find((i) => i.appUserCreator.userId == this.data.userInfo.userId) if (resData) { this.setData({ teacherState: { @@ -170,11 +175,17 @@ } }) }, + //鏁欏笀璁よ瘉 + toCertification() { + wx.navigateTo({ + url: "/packageDomain/pages/teacherCertification/index", + }); + }, //鐐瑰嚮鐩綍 toPages(item) { console.log(item) - let info = item.target.dataset.info + let info = item.currentTarget.dataset.info if (info.url) { wx.navigateTo({ url: info.url @@ -193,5 +204,16 @@ */ onShareAppMessage() { + }, + + onPageScroll(e) { + this.setData({ + isWhite: e.scrollTop > 50 ? true : false + }) + + }, + //璺宠浆鍏充簬鎴戜滑鍜岃仈绯绘垜浠� + onAboutUS() { + console.log(111); } }) \ No newline at end of file -- Gitblit v1.9.1