mirror of
https://github.com/EstrellaXD/Auto_Bangumi.git
synced 2026-04-29 13:02:03 +08:00
refactor: 整理unocss,重构useApi,完善通知i18n,调整了一些代码写法,调整了一些样式,清理了一些无用依赖和代码
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
import type { LoginSuccess, Logout, Update } from '#/auth';
|
||||
import type { LoginSuccess, Update } from '#/auth';
|
||||
import type { ApiSuccess } from '#/api';
|
||||
|
||||
export const apiAuth = {
|
||||
async login(username: string, password: string) {
|
||||
@@ -26,8 +27,8 @@ export const apiAuth = {
|
||||
},
|
||||
|
||||
async logout() {
|
||||
const { data } = await axios.get<Logout>('api/v1/auth/logout');
|
||||
return data.message === 'logout success';
|
||||
const { data } = await axios.get<ApiSuccess>('api/v1/auth/logout');
|
||||
return data;
|
||||
},
|
||||
|
||||
async update(username: string, password: string) {
|
||||
|
||||
@@ -1,3 +1,4 @@
|
||||
import { omit } from 'lodash';
|
||||
import type { BangumiAPI, BangumiRule } from '#/bangumi';
|
||||
import type { ApiSuccess } from '#/api';
|
||||
|
||||
|
||||
Reference in New Issue
Block a user