From abbd7d18ea431ee8b6b8e634abf3e8ccb1fbb1b3 Mon Sep 17 00:00:00 2001 From: 闫增涛 <1829501689@qq.com> Date: 星期五, 28 三月 2025 18:43:33 +0800 Subject: [PATCH] 登录迁移 --- packageDomain/pages/resourceDetails/myAudio/index.js | 35 +++++++++++++++-------------------- 1 files changed, 15 insertions(+), 20 deletions(-) diff --git a/packageDomain/pages/resourceDetails/myAudio/index.js b/packageDomain/pages/resourceDetails/myAudio/index.js index cfda077..85e1bc6 100644 --- a/packageDomain/pages/resourceDetails/myAudio/index.js +++ b/packageDomain/pages/resourceDetails/myAudio/index.js @@ -116,27 +116,14 @@ parentName: options.parentName, }) } - const token = wx.getStorageSync(app.config.tokenKey) - if (!token) { - loginInfo(app, (data) => { - if (data) { - this.resourceDetailsData() - this.getNoteList() - } else { - this.resourceDetailsData() - this.getNoteList() - } - }) - } else { - this.resourceDetailsData() - this.getNoteList() - } if (options.formPath == 'jsek_cloudLearning') { + this.getNoteList() this.setData({ learnStartTime: Date.now(), }) this.getLearnTime() } + this.resourceDetailsData() this.getBookInfo(options.bookId) }, @@ -339,11 +326,17 @@ }, onTakeNotes() {}, showDialog(e) { - this.setData({ - submitTitle: this.data.titleName, - dialogKey: true, - textvalue: '' - }); + const token = wx.getStorageSync(app.config.tokenKey); + if (token) { + this.setData({ + submitTitle: this.data.titleName, + dialogKey: true, + textvalue: '' + }); + } else { + loginInfo(app, (data) => {}) + } + }, closeDialog() { @@ -909,6 +902,8 @@ }) }, setPlayerList() { + const token = wx.getStorageSync(app.config.tokenKey); + if (!token) return let that = this if (that.data.progress > 0) { let index = that.data.playerList.findIndex((itemData) => itemData.cmsItemId == that.data.activeId) -- Gitblit v1.9.1