로그인 로직 변경

This commit is contained in:
yoon 2025-02-10 14:44:29 +09:00
parent 6704f5531a
commit 4413001d9d

View File

@ -63,20 +63,17 @@
};
const handleSubmit = async () => {
const response = await $api.post('user/login', {
$api.post('user/login', {
loginId: id.value,
password: password.value,
remember: remember.value,
});
if (response.status === 200) {
await userStore.userInfo();
router.push('/');
} else {
toastStore.onToast('아이디 혹은 비밀번호가 틀렸습니다.', 'e');
}
})
.then(res => {
if (res.status === 200) {
userStore.userInfo();
router.push('/');
}
})
};
</script>