From e6a0859f877baabe82ac7aec027a71fdaaf5a468 Mon Sep 17 00:00:00 2001 From: yangws <1607839436@qq.com> Date: Wed, 28 Aug 2024 14:07:14 +0800 Subject: [PATCH] =?UTF-8?q?fix=EF=BC=9A=E6=97=A0=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E6=97=B6=E5=A4=84=E7=90=86=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/renderer/src/components/choose-textbook/third.vue | 4 ++++ src/renderer/src/components/choose-textbook/third/index.vue | 1 + 2 files changed, 5 insertions(+) diff --git a/src/renderer/src/components/choose-textbook/third.vue b/src/renderer/src/components/choose-textbook/third.vue index 14d3d45..554a6f5 100644 --- a/src/renderer/src/components/choose-textbook/third.vue +++ b/src/renderer/src/components/choose-textbook/third.vue @@ -163,6 +163,10 @@ const handleNodeClick = (data,node) => { onMounted(() => { titleName.value = `${useStore.user.edustage}-${useStore.user.edusubject}` treeLoading.value = true + //存在查看无课程的情况,两秒后关闭loading框 + setTimeout(() => { + treeLoading.value = false + },2000) }) //监听数据变化 watch(() => useThird,() => { diff --git a/src/renderer/src/components/choose-textbook/third/index.vue b/src/renderer/src/components/choose-textbook/third/index.vue index 354f79d..2b7a6a2 100644 --- a/src/renderer/src/components/choose-textbook/third/index.vue +++ b/src/renderer/src/components/choose-textbook/third/index.vue @@ -34,6 +34,7 @@ const getSubject = (value) => { const currentIndex = gradeList.findIndex(item => item.value === value) getSubjects({stage:value}).then(res => { if(res.code === 200){ + if(res.data.length === 0) return subjectList.value = res.data.map(item => { return { ...item, -- 2.44.0.windows.1