From ce3a08b28c16f5cce2185167f8a9030ee16898ed Mon Sep 17 00:00:00 2001 From: litian <C21AF165> Date: 星期六, 07 九月 2024 14:44:55 +0800 Subject: [PATCH] xiugai --- pages/digitalCourses/digitalCoursesDetails/index.js | 16 ++++++++++++---- 1 files changed, 12 insertions(+), 4 deletions(-) diff --git a/pages/digitalCourses/digitalCoursesDetails/index.js b/pages/digitalCourses/digitalCoursesDetails/index.js index d443f2c..b9528d1 100644 --- a/pages/digitalCourses/digitalCoursesDetails/index.js +++ b/pages/digitalCourses/digitalCoursesDetails/index.js @@ -1,6 +1,5 @@ // pages/digitalCourses/digitalCoursesDetails/index.js const app = getApp() -import moment from 'moment' import SparkMD5 from 'spark-md5' import FormData from '../../../utils/formdata/index.js'; import Wxml2Canvas from 'wxml2canvas'; @@ -95,6 +94,7 @@ fullName: '', //鍚嶇О userPicture: '' //鐢宠璇佷功鐢ㄦ埛鍥剧墖 }, + userName: '', pictureMd5: '', publishingUnit: '', pubCertificateHide: true, @@ -155,18 +155,25 @@ */ onLoad(options) { this.setData({ - bookId: options.id + bookId: options.id, + userName: wx.getStorageSync(app.config.tokenKey) }) const token = wx.getStorageSync(app.config.tokenKey) if (!token) { loginInfo(app, (data) => { - if (data) {} else {} + if (data) { + this.digitalCoursesDetailsGet(options.id) + this.getPlayerList() + this.getType() + } else {} }) } this.digitalCoursesDetailsGet(options.id) this.getPlayerList() this.getType() - + this.setData({ + userName: JSON.parse(wx.getStorageSync(app.config.userInfoKey)).name + }) }, /** @@ -514,6 +521,7 @@ i.children = [] this.getTreeList(rootList, pathLength + addNum, i.children, i.productLinkPath, addNum) if (i.children.length == 0) { + newArr[0].istry = true delete i.children } } -- Gitblit v1.9.1