로그인 로직 변경
This commit is contained in:
parent
6704f5531a
commit
4413001d9d
@ -63,20 +63,17 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
const handleSubmit = async () => {
|
const handleSubmit = async () => {
|
||||||
const response = await $api.post('user/login', {
|
$api.post('user/login', {
|
||||||
loginId: id.value,
|
loginId: id.value,
|
||||||
password: password.value,
|
password: password.value,
|
||||||
remember: remember.value,
|
remember: remember.value,
|
||||||
});
|
})
|
||||||
|
.then(res => {
|
||||||
if (response.status === 200) {
|
if (res.status === 200) {
|
||||||
await userStore.userInfo();
|
userStore.userInfo();
|
||||||
router.push('/');
|
router.push('/');
|
||||||
} else {
|
}
|
||||||
toastStore.onToast('아이디 혹은 비밀번호가 틀렸습니다.', 'e');
|
})
|
||||||
}
|
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user