From 014f7fdccfbb2691e450d557e1ad34c4551aacb5 Mon Sep 17 00:00:00 2001 From: lixg Date: Tue, 28 Feb 2023 14:21:11 +0800 Subject: [PATCH] =?UTF-8?q?feat:=E4=BF=AE=E6=94=B9=E7=89=88=E6=9C=AC?= =?UTF-8?q?=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/App.vue | 2 +- src/components/PathDetailImage.vue | 2 +- src/views/projectdetails/projectDetails.vue | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/App.vue b/src/App.vue index e7f052b..e22231b 100644 --- a/src/App.vue +++ b/src/App.vue @@ -27,7 +27,7 @@ import { GET_USER_INFO } from "@/api/ThirdApi"; import { getCookie } from "@/api/utils"; import { USER_INFO } from "@/api/api"; -console.log("版本1.2.8------------"); +console.log("版本1.2.10------------"); const store = useStore(); const router = useRouter(); diff --git a/src/components/PathDetailImage.vue b/src/components/PathDetailImage.vue index 9530c87..4ce3427 100644 --- a/src/components/PathDetailImage.vue +++ b/src/components/PathDetailImage.vue @@ -107,7 +107,7 @@ watch(data, () => { // "import.meta.env.VITE_BOE_BASE_URL", // import.meta.env.VITE_BOE_BASE_URL // ); - if (data.value && data.value.list) { + if (data && data.value && data.value.list) { data.value.list.reverse(); current.value = data.value.list.findIndex( (e) => e.id === data.value.currentChapterId diff --git a/src/views/projectdetails/projectDetails.vue b/src/views/projectdetails/projectDetails.vue index 612f0ea..9504cdd 100644 --- a/src/views/projectdetails/projectDetails.vue +++ b/src/views/projectdetails/projectDetails.vue @@ -182,8 +182,8 @@ watch( { deep: true } ); watch(data, () => { - console.log("data.value.projectId", data.value.projectId); - if (!data.value.projectId) { + console.log("data.value.projectId", data.value); + if (data && data.value && !data.value.projectId) { ElMessage.warning("您不是此项目的学员"); window.open( import.meta.env.VITE_BOE_BASE_URL + "/mobile/pages/index/index",