Просмотр исходного кода

紧急修正:增加网站配置中状态

紧急修正:增加网站配置中状态
dangyunlong 2 дней назад
Родитель
Сommit
92f4bf83e8
2 измененных файлов с 8 добавлено и 7 удалено
  1. 4 3
      error.vue
  2. 4 4
      pages/index.vue

+ 4 - 3
error.vue

@@ -1,9 +1,10 @@
 <template>
     <div class="errorBox">
-        <img src="http://img.bjzxtw.org.cn/pre/image/jpeg/20250701/1751346180738003.jpg" alt="页面不存在" v-if="errorCode == 404">
+        <img src="http://img.bjzxtw.org.cn/pre/image/jpeg/20250701/1751346180738003.jpg" alt="页面不存在">
         <!-- <img src="http://img.bjzxtw.org.cn/pre/image/jpeg/20250701/1751346208700657.jpg" alt="服务器渲染错误" v-if="errorCode == 500"> -->
         <!-- <div class="errorText" v-if="errorCode == 404">对不起,您访问的页面不存在</div> -->
-        <div class="errorText">对不起,当前网站遇到了一些问题..</div>
+        <div class="errorText" v-if="errorCode == 404">对不起,当前网站遇到了一些问题..</div>
+        <div class="errorText" v-if="errorCode == 500">对不起,网站尚未完成配置..</div>
         <div class="errorDetail">{{ errorMsg }}</div>
         <!-- <div class="errorText">{{ errorMsg }}</div> -->
         <div @click="goHome" class="goHome">返回网站首页</div>
@@ -26,7 +27,7 @@
     console.log('错误来源:',route.query.findPage + ".html")
 
     //展示错误详细
-    const errorMsg = ref('您要访问的页面已不存在!')
+    const errorMsg = ref('当前页面无法访问!')
     //开始查找错误来源:
     if(route.query.findPage == 'index'){
         const websiteId = ref<number>(0)

+ 4 - 4
pages/index.vue

@@ -108,10 +108,10 @@ try {
             ]
         });
     }else if(responseStatus.code == 0){
-        navigateTo('/404?findPage=index')
+        navigateTo('/error?findPage=index')
     }
 } catch (error) {
-    navigateTo('/404?findPage=index')
+    navigateTo('/error?findPage=index')
 }
 //1.获得基本信息单元 end---------------------------------------->
 
@@ -141,11 +141,11 @@ try {
         templateBaseStore.setAdList(adData.value)
     }else if(response.code == 0){
         //第一种情况,code为0 跳转到404
-        navigateTo('/404?findPage=index')
+        navigateTo('/error?findPage=index')
     }
 }catch (error) {
     //第二种情况,服务器无响应 跳转到404
-    navigateTo('/404?findPage=index')
+    navigateTo('/error?findPage=index')
 }
 //2.页面数据 end---------------------------------------->
 </script>