| | |
| | | } |
| | | this.getAboutBook(res.datas.productLinkInfo[res.datas.productLinkInfo.length - 1].LinkPath) |
| | | this.getCertificateList() |
| | | res.datas.content = res.datas.content.replace('../', app.config.requestCtx + '/') |
| | | res.datas.content = res.datas.content && res.datas.content.replace('../', app.config.requestCtx + '/') |
| | | this.setData({ |
| | | lecturerList: lecturer, |
| | | digitalsData: res.datas, |
| | |
| | | } |
| | | }) |
| | | .then((res) => { |
| | | this.setData({ |
| | | relationTextBook: res.datas[0] |
| | | }) |
| | | if (this.data.relationTextBook.purchasedSaleMethodIdList.includes(this.data.relationTextBook.defaultSaleMethodId)) { |
| | | if (res.datas.length > 0) { |
| | | this.setData({ |
| | | isTextBookBuy: true |
| | | relationTextBook: res.datas[0] |
| | | }) |
| | | } else { |
| | | this.setData({ |
| | | isTextBookBuy: false |
| | | }) |
| | | if (this.data.relationTextBook.purchasedSaleMethodIdList.includes(this.data.relationTextBook.defaultSaleMethodId)) { |
| | | this.setData({ |
| | | isTextBookBuy: true |
| | | }) |
| | | } else { |
| | | this.setData({ |
| | | isTextBookBuy: false |
| | | }) |
| | | } |
| | | } |
| | | }) |
| | | }, |