Pārlūkot izejas kodu

refactor(login): 移除重复的错误提示

- 删除登录失败时的重复错误消息提示-保留控制台错误日志输出
- 简化错误处理逻辑
panqiuyao 1 mēnesi atpakaļ
vecāks
revīzija
4566573cfa
1 mainītis faili ar 4 papildinājumiem un 4 dzēšanām
  1. 4 4
      frontend/src/components/login/index.vue

+ 4 - 4
frontend/src/components/login/index.vue

@@ -195,7 +195,7 @@ const loginRules = reactive({
 
 const handleLogin = async () => {
   loading.value = true;
-  
+
   try {
     const  res = await  useUserInfoStore.loginAction({
       "site":1,
@@ -226,7 +226,7 @@ const handleLogin = async () => {
     }
   } catch (error) {
     console.error('登录失败:', error);
-    ElMessage.error('登录失败,请重试');
+   // ElMessage.error('登录失败,请重试');
   } finally {
     loading.value = false;
   }
@@ -259,9 +259,9 @@ async function  showCompany() {
 // 切换组织
 async function toggleCompany() {
   if (!companyId.value) return false
-  
+
   loading.value = true;
-  
+
   try {
     const res = await selectCompany({
       id: companyId.value