67 lines
1.3 KiB
Vue
67 lines
1.3 KiB
Vue
<template>
|
|
<view class="PopularityList_content">
|
|
<view class="PopularityList_header">
|
|
<view class="PopularityList_header_title">{{isTitle}}</view>
|
|
</view>
|
|
<view class="PopularityList_body">
|
|
<view class="PopularityList_body_item" v-for="m in dataList" :key="m.id" @tap="toBooksReadingDetail(m)">
|
|
<CommBookLeftRigth :bookTips="m.category_name" :bookName="m.title" :bookImage="m.cover" :bookIntroduction="m.intro"/>
|
|
</view>
|
|
</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import CommBookLeftRigth from '@/components/commBookLeftRigth/index.vue'
|
|
export default {
|
|
name:'PopularityList',
|
|
components: {
|
|
CommBookLeftRigth
|
|
},
|
|
props:{
|
|
dataList: {
|
|
type: Array,
|
|
default: []
|
|
},
|
|
isTitle: {
|
|
type: String,
|
|
default:''
|
|
}
|
|
},
|
|
data() {
|
|
return {
|
|
|
|
}
|
|
},
|
|
methods:{
|
|
toBooksReadingDetail(row) {
|
|
uni.navigateTo({
|
|
url: `/pages/booksReadingDetail/booksReadingDetail?sid=${row.id}&t=${row.title}`
|
|
})
|
|
},
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style lang="scss">
|
|
.PopularityList_content {
|
|
width: 100%;
|
|
|
|
.PopularityList_header {
|
|
width: 100%;
|
|
|
|
.PopularityList_header_title {
|
|
font-size: 36rpx;
|
|
color: #1A1A1A;
|
|
line-height: 1;
|
|
font-weight: 600;
|
|
}
|
|
}
|
|
|
|
.PopularityList_body {
|
|
.PopularityList_body_item {
|
|
margin-top: 32rpx;
|
|
}
|
|
}
|
|
}
|
|
</style> |