packageBookService/pages/bookServices/detail/components/tree/index.js | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
packageBookService/pages/bookServices/detail/index.js | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
packageDomain/pages/resourceDetails/document/index.js | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
packageDomain/pages/resourceDetails/document/index.wxml | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 | |
packageDomain/pages/resourceDetails/document/index.wxss | ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史 |
packageBookService/pages/bookServices/detail/components/tree/index.js
@@ -253,7 +253,7 @@ ) { url = "/packageDomain/pages/resourceDetails/myAudio/index"; } if (item.selectType == "picture") { if (item.selectType == "picture" || item.selectType == 'document') { url = "/packageDomain/pages/resourceDetails/document/index"; } wx.navigateTo({ packageBookService/pages/bookServices/detail/index.js
@@ -971,7 +971,6 @@ }, } app.MG.store.getProductDetailNoChildren(query).then((res) => { console.log('未处理资源', res.datas.cmsDatas[0].datas); if (!res.datas.cmsDatas[0].datas.length) { return this.setData({ noResources: true, packageDomain/pages/resourceDetails/document/index.js
@@ -283,7 +283,6 @@ //刚进来的时候调用 handleTeachData(item) { //图片 console.log(item, 'item11111'); if (item.selectType == 'picture') { this.setData({ showData: item.file ? app.config.requestCtx + '/file/api/ApiDownload?md5=' + item.file : app.config.requestCtx + '/file/api/ApiDownload?md5=' + item.freeFile, @@ -307,13 +306,17 @@ app.MG.file.getPdfInfo({ md5: item.file }).then((res) => { let naturalResources = [] if (res && JSON.parse(res).totalPages) { for (let i = 0; i < JSON.parse(res).totalPages; i++) { const src = app.config.requestCtx + '/file/GetPdfPageImage?md5=' + item.file + '&index=' + (i + 1) + '&dpi=300' this.data.naturalResources.push(src) // console.log(this.data.naturalResources, ' this.data.naturalResources'); naturalResources.push(src) } } this.setData({ naturalResources }) console.log('ppt', this.data.naturalResources); }) } }, packageDomain/pages/resourceDetails/document/index.wxml
@@ -40,8 +40,14 @@ wx:key="index" wx:for-item="item" wx:for-index="index" class="img-box" > <image src="{{item}}" alt="" style="min-height: 550px"></image> <image src="{{item}}" alt="" style="min-height: 550px" mode="aspectFit" ></image> <view class="divider">第 {{index + 1}} 页</view> </view> </view> packageDomain/pages/resourceDetails/document/index.wxss
@@ -103,4 +103,12 @@ 75% { transform: scale(2.0); } } .img-box { display: flex; flex-direction: column; justify-content: center; align-items: center; box-shadow: 0 3px 6px 1px #00000029; }