feat: 优化空容器展示
This commit is contained in:
@@ -9,12 +9,15 @@
|
||||
</div>
|
||||
<div class="new-survey-container" v-loading="requestLoading">
|
||||
<div style="margin-bottom: 80px">
|
||||
<van-list
|
||||
@load="handleLoadSurveys"
|
||||
v-model:loading="loading"
|
||||
:finished="finished"
|
||||
finished-text="没有更多了"
|
||||
>
|
||||
<van-list @load="handleLoadSurveys" v-model:loading="loading" :finished="finished">
|
||||
<template #finished>
|
||||
<!-- 如果问卷大于0的话,显示没有更多了 -->
|
||||
<!-- 如果问卷等于0的话,显示空容器 -->
|
||||
<span v-if="survey.length > 0">
|
||||
<el-text>没有更多了</el-text>
|
||||
</span>
|
||||
</template>
|
||||
|
||||
<div v-for="item in survey" v-if="survey.length > 0" :key="item" class="new-survey_item">
|
||||
<survey-item :survey="item" :is-analysis="true" :disable-action-button="false" />
|
||||
</div>
|
||||
|
||||
@@ -51,6 +51,7 @@ async function fetchSurveys(form: any) {
|
||||
if (survey.value.length >= total.value) {
|
||||
finished.value = true;
|
||||
}
|
||||
|
||||
} else {
|
||||
// Toast()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user