From d962fe91024fce7381b4ebdc01cb5e4076b3ab46 Mon Sep 17 00:00:00 2001 From: tianfeng <769204422@qq.com> Date: Fri, 5 Sep 2025 22:08:25 +0800 Subject: [PATCH] =?UTF-8?q?apply=20=E9=A1=B5=E9=9D=A2=E6=8F=90=E7=A4=BA?= =?UTF-8?q?=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ApplyView.vue | 20 ++------------------ 1 file changed, 2 insertions(+), 18 deletions(-) diff --git a/src/views/ApplyView.vue b/src/views/ApplyView.vue index cbc88b6..02a2d92 100644 --- a/src/views/ApplyView.vue +++ b/src/views/ApplyView.vue @@ -173,28 +173,12 @@ const searchTeamAccount = async (account) => { return response.body.teamProfile.id // 返回团队ID } else { searchedTeamInfo.value = null - throw new Error('Team not found or invalid account') + showError(response.errorMsg) } } catch (error) { - console.error('搜索团队失败:', error) searchedTeamInfo.value = null + showError(error.errorMsg) - if (error instanceof ApiError) { - if (error.type === 'business') { - switch (error.errorCode) { - case 6010: - throw new Error('Account not found or not an agent') - case 6001: - throw new Error('Invalid account format') - default: - throw new Error(error.errorMsg || 'Failed to search account') - } - } else { - throw new Error('Network error, please check your connection') - } - } else { - throw new Error('Failed to search account') - } } }