refactor: 重命名login参数类型

Former-commit-id: e5bbbd05ecb8fda2083406c4e166427413ebd758
This commit is contained in:
haoxr
2023-02-06 01:04:16 +08:00
parent 4c4311396f
commit 65287e85c7

View File

@@ -5,7 +5,7 @@ import { loginApi, logoutApi } from '@/api/auth';
import { getUserInfo } from '@/api/user';
import { resetRouter } from '@/router';
import { store } from '@/store';
import { LoginData } from '@/api/auth/types';
import { LoginType } from '@/api/auth/types';
import { ref } from 'vue';
import { UserInfo } from '@/api/user/types';
@@ -20,7 +20,7 @@ export const useUserStore = defineStore('user', () => {
// actions
// 登录
function login(loginData: LoginData) {
function login(loginData: LoginType) {
return new Promise<void>((resolve, reject) => {
loginApi(loginData)
.then(response => {