From fab94e9d238bda809590b9efc19053aae1be66d8 Mon Sep 17 00:00:00 2001 From: pxq <1456889284@qq.com> Date: Mon, 25 Jul 2022 14:17:35 +0800 Subject: [PATCH] =?UTF-8?q?fix:=E6=A1=88=E4=BE=8B=E4=B8=AD=E5=BF=83?= =?UTF-8?q?=E6=8E=A5=E5=8F=A3bug=E4=BF=AE=E5=A4=8D=E5=8F=8Amd=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../src/components/AppInfoDetail.vue | 9 +------- .../src/views/showcase/TheShowCase.vue | 21 +++++++++++++------ .../009e4e30-a3e5-ecc4bdfd977b/index.md | 3 +++ 3 files changed, 19 insertions(+), 14 deletions(-) diff --git a/app/.vitepress/src/components/AppInfoDetail.vue b/app/.vitepress/src/components/AppInfoDetail.vue index fde8b36a5..b97f9c454 100644 --- a/app/.vitepress/src/components/AppInfoDetail.vue +++ b/app/.vitepress/src/components/AppInfoDetail.vue @@ -24,11 +24,4 @@ const isDoc = computed(() => { - + diff --git a/app/.vitepress/src/views/showcase/TheShowCase.vue b/app/.vitepress/src/views/showcase/TheShowCase.vue index b099a4a0d..9729d5cab 100644 --- a/app/.vitepress/src/views/showcase/TheShowCase.vue +++ b/app/.vitepress/src/views/showcase/TheShowCase.vue @@ -28,6 +28,8 @@ const tagClick = (i: number, type: string) => { // tag筛选及搜索传输的参数 const data = ref({ keyword: '', + page: 1, + pageSize: 10000, type: '', }); // 根据tag筛选需要显示的案例 @@ -98,7 +100,13 @@ function goDetail(link: string, item: any) { function setCurrentCaseListAll() { getUserCaseData(data.value).then((res: any) => { if (res.status === 200 && res.obj.records) { - currentCaseListAll.value = res.obj.records; + const CaseListAll = res.obj.records; + CaseListAll.forEach((item: any, index: number) => { + if (item.summary === '') { + CaseListAll.splice(index, 1); + } + }); + currentCaseListAll.value = CaseListAll; } else { currentCaseListAll.value = []; } @@ -111,6 +119,7 @@ function searchCase() { activeIndex.value = 0; setCurrentCaseListAll(); } +// 获取所有案例及设置当前需要显示的案例 onMounted(() => { window.addEventListener('scroll', onscroll); getCaseTagData().then((res: any) => { @@ -200,7 +209,7 @@ onUnmounted(() => { -
+
{ > {{ currentPage1 }}/{{ totalPage }} -
+
@@ -244,7 +253,6 @@ onUnmounted(() => {