1、最终效果:
2、pages.json页面:
{
"path": "pages/tabbar/sysLog",
"style": {
"navigationStyle": "custom",//隐藏默认导航头
"enablePullDownRefresh": true, //配置后,可以下拉刷新,上拉加载
"onReachBottomDistance": 50 //距离底部多远时触发 单位px
}
},
3、页面功能:
created() {
},
// 上拉加载
onReachBottom() {
const that = this
//获取数据的方法
......
},
//下拉加载
onPullDownRefresh() {
const that = this
//获取数据的方法
......
uni.stopPullDownRefresh();//停止加载
},
onLoad() {
},
methods: {
}