| | |
| | | protocolShow: false, |
| | | protocolTxt: '', |
| | | learnMenu: null, |
| | | md5List: [] |
| | | md5List: [], |
| | | editDialog: false |
| | | }, |
| | | |
| | | resetTree: function (e) { |
| | |
| | | this.setData({ |
| | | tabValue: options.tabValue, |
| | | }); |
| | | |
| | | |
| | | } |
| | | }, |
| | | |
| | |
| | | this.setData({ |
| | | num: Number(this.data.paperBookList.length) + Number(this.data.electronicBookList.length), |
| | | }); |
| | | if (this.data.bookDetail) { |
| | | if (this.data.bookDetail.id) { |
| | | this.getBookInfo(this.data.bookDetail.id) |
| | | } |
| | | }, |
| | |
| | | protectedEpub: [], |
| | | probationPage: [], //pdf试读页数 |
| | | freeEpubPage: [], //epub试读百分比 |
| | | bookEditor: [], //图书编辑 |
| | | contactInformation: [], //联系方式 |
| | | }, |
| | | }; |
| | | app.MG.store.getProductDetail(query).then(async (res) => { |
| | | this.getResourceCode(id, res.datas.rootCmsItemId) |
| | | console.log(res.datas, "res.datas") |
| | | res.datas.bookEditor = res.datas.bookEditor ? res.datas.bookEditor : '-' |
| | | res.datas.contactInformation = res.datas.contactInformation ? res.datas.contactInformation : '-' |
| | | this.setData({ |
| | | bookDetail: res.datas, |
| | | buyIdList: res.datas.purchasedSaleMethodIdList, |
| | |
| | | } |
| | | await this.getBookClass(classData); |
| | | } |
| | | } |
| | | // 扫码从题库跳转回图书详情 |
| | | const localData = wx.getStorageSync('tabValue') |
| | | if (localData) { |
| | | this.setData({ |
| | | tabValue: localData |
| | | }) |
| | | wx.removeStorage({ |
| | | key: 'tabValue', |
| | | }) |
| | | } |
| | | if (this.data.tabValue == 'questionBank' || this.data.tabValue == 'jsek_cloudLearning' || this.data.tabValue == 'jsek_teachingResources') { |
| | | const checkData = this.data.cmsDatas.find( |
| | |
| | | "bookDetail.paperPrice": this.numFormat( |
| | | this.data.bookDetail.paperPrice |
| | | ), |
| | | |
| | | }); |
| | | }); |
| | | }, |
| | |
| | | } |
| | | } |
| | | }, |
| | | |
| | | // 联系 |
| | | editPhone() { |
| | | this.setData({ |
| | | editDialog: true |
| | | }) |
| | | }, |
| | | |
| | | // 我要建议 |
| | | suggestBtn() { |
| | | // 检查登录状态 |
| | |
| | | }); |
| | | } |
| | | } else { |
| | | |
| | | if (isTSFW.length > 0) { |
| | | data = res.datas.cmsDatas[0].datas.filter((item) => item.type == 'questionBankFolder' && (item.childrenFolderCount > 0 || item.childrenCount > 0) && (item.name !== '填空题' && |
| | | data = res.datas.cmsDatas[0].datas.filter((item) => item.type == 'questionBankFolder' && item.refCode != 'jsek_interaction' && (item.childrenFolderCount > 0 || item.childrenCount > 0) && (item.name !== '填空题' && |
| | | item.name !== '判断题' && |
| | | item.name !== '多选题' && |
| | | item.name !== '简答题') && item.name !== '单选题') |
| | |
| | | jslx: false, |
| | | }); |
| | | } else { |
| | | data = res.datas.cmsDatas[0].datas.filter((item) => item.type == 'questionBankFolder' && item.refCode != 'jsek_interaction') |
| | | data = res.datas.cmsDatas[0].datas.filter((item) => item.type == 'questionBankFolder') |
| | | // && item.refCode != 'jsek_interaction' |
| | | that.setData({ |
| | | jslx: true, |
| | |
| | | // 云学习全部购买 |
| | | async buyCloudLearnClass() { |
| | | const cloundMenu = this.data.resourceCodeList.find((item) => item.refCode == 'jsek_cloudLearning') |
| | | debugger |
| | | let query = { |
| | | remarks: '云学习', |
| | | requests: [{ |
| | |
| | | requests: [{ |
| | | saleMethodId: this.data.bankSaleData.Id, |
| | | storeEventId: null, |
| | | agentCode: "电子书", |
| | | agentCode: "云测试", |
| | | }, ], |
| | | }; |
| | | app.MG.store.addShoppingCart(query).then(res => { |