版本提交

This commit is contained in:
zhangwentao 2024-10-31 19:08:09 +08:00
parent 466da10079
commit 96bbbd253f
6 changed files with 23 additions and 19 deletions

View File

@ -61,7 +61,7 @@
org_id: getApp().globalData.org_id, org_id: getApp().globalData.org_id,
type: 3, type: 3,
page: 1, page: 1,
limit: 10, limit: 20,
}, },
swiperList: [], swiperList: [],
assetList: [], assetList: [],
@ -96,11 +96,11 @@
} }
}, },
onReachBottom() { onReachBottom() {
if (this.assetList.length >= that.count) { if (this.assetList.length >= this.count) {
this.status = 'nomore'; this.status = 'nomore';
return return
} }
this.page++ this.queryParams.page++
this.status = 'loading'; this.status = 'loading';
this.getList() this.getList()
@ -148,7 +148,7 @@
}) })
}, },
search() { search() {
this.page = 1 this.queryParams.page=1
this.assetList = [] this.assetList = []
this.getList() this.getList()
}, },
@ -180,7 +180,7 @@
}, },
btntabs(item) { btntabs(item) {
this.queryParams.type = item.type this.queryParams.type = item.type
this.page = 1 this.queryParams.page = 1
this.assetList = [] this.assetList = []
this.getList() this.getList()
}, },

View File

@ -12,7 +12,7 @@
<!-- 图文列表 --> <!-- 图文列表 -->
<!-- 有内容 --> <!-- 有内容 -->
<view v-if="assetList.length > 0"> <view v-if="assetList.length > 0">
<topic-list @click.native="goTopicDetail(item1)" :item="item1" v-for="(item1,index1) in assetList" <topic-list @click.native="goTopicDetail(item1)" type='history' :item="item1" v-for="(item1,index1) in assetList"
:key="index1"></topic-list> :key="index1"></topic-list>
<u-loadmore :status="status"></u-loadmore> <u-loadmore :status="status"></u-loadmore>
</view> </view>
@ -84,13 +84,13 @@
} }
}, },
onReachBottom() { onReachBottom() {
if (this.assetList.length >= that.count) { if (this.assetList.length >= this.count) {
this.status = 'nomore'; this.status = 'nomore';
return return
} }
this.page++ this.queryParams.page++
this.status = 'loading'; this.status = 'loading';
this.getList() this.getLists()
}, },
onLoad(options) { onLoad(options) {
@ -214,7 +214,7 @@
changeTab(item) { changeTab(item) {
this.tabIndex = item.index this.tabIndex = item.index
this.swiperIndex = item.index this.swiperIndex = item.index
this.page = 1 this.queryParams.page = 1
this.assetList = [] this.assetList = []
this.queryParams.type = item.type this.queryParams.type = item.type
this.getLists() this.getLists()

View File

@ -2,7 +2,7 @@
<!-- 新鲜事/话题列表 --> <!-- 新鲜事/话题列表 -->
<view class="topic-list flex items-center"> <view class="topic-list flex items-center">
<image style="width: 200rpx; height: 150rpx;" :src="item.cover" lazy-load mode="aspectFill"></image> <image style="width: 200rpx; height: 150rpx;" :src="item.cover" lazy-load mode="aspectFill"></image>
<view class="my-20 flex-1"> <view class="my-20 " style="width: 500rpx; border: solid 1px red;">
<view class="text-black text-32 asset_name">{{item.asset_name}}</view> <view class="text-black text-32 asset_name">{{item.asset_name}}</view>
<view class="text-gray-400 text-26 my-10 digest">{{item.digest}}</view> <view class="text-gray-400 text-26 my-10 digest">{{item.digest}}</view>
<view class="operation"> <view class="operation">

View File

@ -2,10 +2,10 @@
<!-- 新鲜事/话题列表 --> <!-- 新鲜事/话题列表 -->
<view class="topic-list flex items-center"> <view class="topic-list flex items-center">
<image style="width: 200rpx; height: 150rpx;" :src="item.cover" lazy-load mode="aspectFill"></image> <image style="width: 200rpx; height: 150rpx;" :src="item.cover" lazy-load mode="aspectFill"></image>
<view class="my-20 flex-1"> <view class="my-20" style="width: 500rpx; ">
<view class="text-black text-32 asset_name">{{item.asset_name}}</view> <view class="text-black text-32 asset_name">{{item.asset_name}}</view>
<view class="text-gray-400 text-26 my-10 digest">{{item.digest}}</view> <view class="text-gray-400 text-26 my-10 digest">{{item.digest}}</view>
<view class="operation"> <view v-if="type!='history'" class="operation">
<view>点击量{{formatNumber(item.read_num)}}</view> <view>点击量{{formatNumber(item.read_num)}}</view>
<view>今日{{formatNumber(item.today)}}</view> <view>今日{{formatNumber(item.today)}}</view>
<!-- <view v-if='item.type==2' class="download"><u-icon name="download" color="#9CA3AF " <!-- <view v-if='item.type==2' class="download"><u-icon name="download" color="#9CA3AF "
@ -27,6 +27,10 @@
item: { item: {
type: Object, type: Object,
default: () => ({}) default: () => ({})
},
type: {
type: String,
default: ""
} }
}, },
data() { data() {

View File

@ -57,7 +57,7 @@
type: '', type: '',
group_id: '', group_id: '',
page: 1, page: 1,
limit: 10, limit: 20,
}, },
groupParams: { groupParams: {
type: "", type: "",
@ -70,13 +70,13 @@
} }
}, },
onReachBottom() { onReachBottom() {
if (this.assetList.length >= that.count) { if (this.assetList.length >= this.count) {
this.status = 'nomore'; this.status = 'nomore';
return return
} }
this.page++ this.queryParams.page++
this.status = 'loading'; this.status = 'loading';
this.getList() this.getLists()
}, },
onLoad(options) { onLoad(options) {
@ -200,7 +200,7 @@
changeTab(item) { changeTab(item) {
this.tabIndex = item.index this.tabIndex = item.index
this.swiperIndex = item.index this.swiperIndex = item.index
this.page = 1 this.queryParams.page = 1
this.assetList = [] this.assetList = []
this.queryParams.group_id = item.group_id this.queryParams.group_id = item.group_id
this.getLists() this.getLists()
@ -211,7 +211,7 @@
}) })
}, },
search() { search() {
this.page = 1 this.queryParams.page = 1
this.assetList = [] this.assetList = []
this.getLists() this.getLists()
}, },

Binary file not shown.

Before

Width:  |  Height:  |  Size: 282 KiB