修复bug

This commit is contained in:
zhouyanli
2026-08-07 18:05:16 +08:00
parent 3851aebe66
commit 92dd39cf4b
7 changed files with 128 additions and 16 deletions

View File

@@ -40,6 +40,9 @@
import {
getMyCarList
} from '@/pageSubPack/api/apiSub.js'
import {
onShow
} from '@dcloudio/uni-app'
const statusBarHeight = ref(20)
const defaultCarImg = "http://47.104.199.163:9090/images/propertyImgs/defaultCarImg.png"
const carList = ref([])
@@ -61,9 +64,17 @@
}
// 页面加载时请求第一页
onMounted(() => {
getList()
})
onMounted(() => {
getList()
})
// 从子页面返回时刷新列表(如新增/编辑/删除车辆后)
onShow(() => {
pageNum.value = 1
noMoreData.value = false
loadingMore.value = false
carList.value = []
getList()
})
const getList = async () => {
// 防重复请求
if (loadingMore.value || noMoreData.value) return
@@ -268,4 +279,4 @@
width: 100vw;
height: 46px;
}
</style>
</style>