<template>
|
<view class="box">
|
<view class="item" v-for="(item,index) in list1">
|
<view class="name">
|
{{item.docTitle}}
|
</view>
|
<view class="time">
|
{{item.createTime}}
|
</view>
|
<view class="bottom" @click="chakan(item.docId)">
|
<view class="left">
|
查看详情
|
</view>
|
<img src="/static/i08.png" class="img" alt="" />
|
</view>
|
</view>
|
<!-- <view class="item">
|
<view class="name">
|
涨了,本月起发放!一图看懂养老金怎么调
|
</view>
|
<view class="time">
|
2023.04.05 12:23
|
</view>
|
<view class="bottom">
|
<view class="left">
|
查看详情
|
</view>
|
<img src="/static/i08.png" class="img" alt="" />
|
</view>
|
</view>
|
<view class="item">
|
<view class="name">
|
涨了,本月起发放!一图看懂养老金怎么调
|
</view>
|
<view class="time">
|
2023.04.05 12:23
|
</view>
|
<view class="bottom">
|
<view class="left">
|
查看详情
|
</view>
|
<img src="/static/i08.png" class="img" alt="" />
|
</view>
|
</view>
|
<view class="item">
|
<view class="name">
|
涨了,本月起发放!一图看懂养老金怎么调
|
</view>
|
<view class="time">
|
2023.04.05 12:23
|
</view>
|
<view class="bottom">
|
<view class="left">
|
查看详情
|
</view>
|
<img src="/static/i08.png" class="img" alt="" />
|
</view>
|
</view> -->
|
</view>
|
</template>
|
|
<script>
|
import { docList } from '@/api/index.js'
|
|
export default {
|
|
data() {
|
return {
|
list1:[],
|
queryParams: {
|
pageNum: 1,
|
pageSize: 10
|
},
|
total: 1,
|
}
|
},
|
onShow() {
|
this.list1 = []
|
this.queryParams.pageNum = 1
|
this.getList()
|
},
|
onReachBottom() {
|
if(this.list1.length == this.total) {
|
return
|
}
|
this.queryParams.pageNum++
|
this.getList()
|
},
|
methods: {
|
chakan(id){
|
uni.navigateTo({
|
url: `/pages/hqzc/details?id=${id}`
|
})
|
},
|
getList() {
|
docList({...this.queryParams}).then(val => {
|
// console.log(val.data)
|
this.total = val.data.total
|
this.list1 = [...this.list1,...val.data.rows]
|
})
|
},
|
}
|
}
|
</script>
|
|
<style>
|
page{
|
background-color: #F4F4F4;
|
}
|
</style>
|
<style scoped lang="scss">
|
.box{
|
.item{
|
background: #fff;
|
border-radius: 5px;
|
padding: 24rpx;
|
box-sizing: border-box;
|
margin: 20rpx 32rpx;
|
.name{
|
color: #202d44;
|
font-size:32rpx;
|
margin-bottom: 16rpx;
|
}
|
.time{
|
color: #7e8596;
|
font-size: 26rpx;
|
margin-bottom: 16rpx;
|
|
}
|
.bottom{
|
padding-top: 14rpx;
|
border-top: 1px solid #f1f1f1;
|
display: flex;
|
justify-content: space-between;
|
align-items: center;
|
.left{
|
color: #202d44;
|
font-size: 28rpx;
|
font-weight: 400;
|
}
|
.img{
|
width: 28rpx;
|
height: 28rpx;
|
}
|
}
|
}
|
|
}
|
|
</style>
|