接口改动
This commit is contained in:
@@ -5,14 +5,14 @@
|
||||
<view class="title">{{talkBookDetail.title}}</view>
|
||||
<view class="voices" v-if="talkBookDetail.voices != '' && audioShow">
|
||||
<audio style="text-align: left" :src="talkBookDetail.voices" poster="../../static/icon/fengziIcon.jpg"
|
||||
:name="talkBookDetail.title" :author="bookInfo.authorName" :action="audioAction" controls></audio>
|
||||
:name="talkBookDetail.title" :author="bookInfo.author.authorName" :action="audioAction" controls></audio>
|
||||
</view>
|
||||
<view class="content" v-if="talkBookDetail.content != ''" v-html="talkBookDetail.content"></view>
|
||||
<view class="content" v-else></view>
|
||||
<view class="time">
|
||||
<text>{{talkBookDetail.createTime}}</text>
|
||||
</view>
|
||||
<view class="tuijin" v-if="!isBuy">
|
||||
<view class="tuijin" v-if="!isBuy && bookInfo.productId != null">
|
||||
<p>觉得这本书还不错?</p>
|
||||
<view class="flexbox" style="justify-content: space-between; border: 1px solid #55aa7f; padding: 10rpx; border-radius: 10rpx;">
|
||||
<view class="flexbox">
|
||||
@@ -22,7 +22,7 @@
|
||||
</view>
|
||||
<view>
|
||||
<text style=" display: inline-block; margin-top: 40rpx;">{{bookInfo.name}}</text><br/>
|
||||
<text>作者:{{bookInfo.authorName}}</text>
|
||||
<text>作者:{{bookInfo.author.authorName}}</text>
|
||||
</view>
|
||||
</view>
|
||||
<view class="btn" @click="gotoBuy()">
|
||||
@@ -57,7 +57,11 @@
|
||||
playData: {},
|
||||
teachId: null, // 讲书id
|
||||
bookId: null, // 书籍id
|
||||
bookInfo: {}, // 书籍信息
|
||||
bookInfo: {
|
||||
author:{
|
||||
authorName:''
|
||||
}
|
||||
}, // 书籍信息
|
||||
talkBookDetail: {},
|
||||
}
|
||||
},
|
||||
@@ -78,13 +82,16 @@
|
||||
// 购买
|
||||
gotoBuy(){
|
||||
uni.navigateTo({
|
||||
url: '../bookShop/settlementBook?type=2&list=' + this.bookId
|
||||
url: '../bookShop/commodityDetail?id=' + this.bookInfo.productId
|
||||
});
|
||||
},
|
||||
getBookInfo() {
|
||||
// 获取书本基本信息
|
||||
this.$http
|
||||
.post('book/book/appinfo/' + this.bookId + '/' + this.userInfo.id)
|
||||
this.$http
|
||||
.post('book/book/getBookInfo', {
|
||||
'bookId': this.bookId,
|
||||
'userId': this.userInfo.id
|
||||
})
|
||||
.then(res => {
|
||||
if (res.code == 0) {
|
||||
console.log(res, 'res')
|
||||
|
||||
Reference in New Issue
Block a user