From 90b09add4ebe0b245c467bff8372f49b8fe3fb6e Mon Sep 17 00:00:00 2001 From: litian <C21AF165> Date: 星期四, 11 七月 2024 11:42:49 +0800 Subject: [PATCH] bitian --- packageBookService/pages/bookServices/detail/index.js | 17 ++++++++--------- 1 files changed, 8 insertions(+), 9 deletions(-) diff --git a/packageBookService/pages/bookServices/detail/index.js b/packageBookService/pages/bookServices/detail/index.js index e500b90..042346a 100644 --- a/packageBookService/pages/bookServices/detail/index.js +++ b/packageBookService/pages/bookServices/detail/index.js @@ -512,14 +512,14 @@ "fileInfo.bookName": this.data.bookDetail.name, "fileInfo.fileType": "pdf", "fileInfo.md5": res.datas[0].bookshelf_pdf, - "fileInfo.freePage": res.datas[0].bookshelf_probationPage, + "fileInfo.freePage": res.datas[0].bookshelf_probationPage ? res.datas[0].bookshelf_probationPage : 30, }); } else if (res.datas[0].bookshelf_protectedEpub) { this.setData({ "fileInfo.bookName": this.data.bookDetail.name, "fileInfo.fileType": "epub", "fileInfo.md5": res.datas[0].bookshelf_protectedEpub, - "fileInfo.freePage": res.datas[0].bookshelf_freeEpub, + "fileInfo.freePage": res.datas[0].bookshelf_freeEpub ? res.datas[0].bookshelf_freeEpub : 30, }); } } @@ -533,7 +533,7 @@ "fileInfo.bookName": this.data.bookDetail.name, "fileInfo.fileType": "pdf", "fileInfo.md5": this.data.bookDetail.pdf, - "fileInfo.freePage": this.data.bookDetail.probationPage, + "fileInfo.freePage": this.data.bookDetail.probationPage ? this.data.bookDetail.probationPage : 30, }); } else if (this.data.bookDetail.protectedEpub) { @@ -541,7 +541,7 @@ "fileInfo.bookName": this.data.bookDetail.name, "fileInfo.fileType": "epub", "fileInfo.md5": this.data.bookDetail.protectedEpub, - "fileInfo.freePage": this.data.bookDetail.freeEpubPage, + "fileInfo.freePage": this.data.bookDetail.freeEpubPage ? this.data.bookDetail.freeEpubPage : 30, }); } } @@ -690,9 +690,7 @@ // this.getResourceData(checkData); // } if ((e.detail.value == "jsek_teachingResources" && !this.data.teach.length) || (e.detail.value == "jsek_cloudLearning" && !this.data.learn.length)) { - if (e.detail.value == "jsek_teachingResources") { - wx.setStorageSync('teachResourcesPath', checkData.productLinkPath) - } + wx.setStorageSync('teachResourcesPath', checkData.productLinkPath) this.getResourceDataList(checkData) } else if (e.detail.value == "questionBank" && !this.data.test.length) { this.getResourceData(checkData); @@ -2101,7 +2099,7 @@ const smBook = list.find(item => item.content[0].id == this.data.bookDetail.id) console.log('宸茬敵璇�', smBook); if (smBook && smBook.state == 'Normal') { - const flag = new Date(smBook.feedBack.endDate + '23:59:59').getTime() > new Date().getTime() + const flag = new Date(smBook.feedBack.endDate + ' 23:59:59').getTime() > new Date().getTime() if (flag) { this.setData({ applicationState: 'Normal' @@ -2211,7 +2209,8 @@ }); return false; } else if (isApply.state == 'Normal') { - const flag = new Date(isApply.feedBack.endDate + '23:59:59').getTime() > new Date().getTime() + console.log(isApply.state, "isApply.state") + const flag = new Date(isApply.feedBack.endDate + ' 23:59:59').getTime() > new Date().getTime() if (flag) { wx.showToast({ title: "璇ヤ功宸茬敵璇凤紒", -- Gitblit v1.9.1