页面下拉刷新以及底部回弹

This commit is contained in:
2026-09-23 18:12:04 +08:00
parent 201d0086a4
commit 6e60a409c5
12 changed files with 219 additions and 28 deletions
+5 -2
View File
@@ -1,6 +1,7 @@
<template>
<view class="page">
<view class="page edge">
<fy-header :title="title" back />
<fy-scroll class="edge-scroll" @refresh="load">
<view v-if="loading" class="empty">加载中</view>
<view v-else-if="!rows.length" class="empty">暂无记录</view>
<view v-for="r in rows" :key="r.id || r.no" class="card item" @click="open(r)">
@@ -10,17 +11,19 @@
</view>
<text class="amt">{{ r.amount != null ? '¥' + r.amount : '' }}</text>
</view>
</fy-scroll>
</view>
</template>
<script>
import FyHeader from '../../components/fy-header.vue'
import FyScroll from '../../components/fy-scroll.vue'
import { store } from '../../utils/store.js'
import { asList } from '../../utils/format.js'
import { oaGet } from '../../utils/api.js'
export default {
components: { FyHeader },
components: { FyHeader, FyScroll },
data() { return { title: '单据', type: 'expense', rows: [], loading: false } },
onLoad(q) {
this.type = q.type || 'expense'