diff --git a/src/views/login/index.vue b/src/views/login/index.vue index a5ffbcd..bcbdce2 100644 --- a/src/views/login/index.vue +++ b/src/views/login/index.vue @@ -73,7 +73,7 @@ const captcha_img = ref('') const captcha_id = ref('') const currentStep = ref(2) // 当前步骤 -const httpApi = import.meta.env.BASE_URL + `api/v1/captcha/image` +const httpApi = config('http.apiBasic') + `/api/v1/captcha/image` const redirect = computed(() => decodeURIComponent(route.query?.redirect ?? '')) formRules.value = { @@ -83,6 +83,7 @@ formRules.value = { } onMounted(() => { + // 清理登录信息 userStore.logout() getCaptcha() @@ -97,6 +98,7 @@ async function getCaptcha() { }) captcha_id.value = data.captcha_id captcha_img.value = httpApi + `?id=${data.captcha_id}` + } /** * 登录