Files
gofly-platform-services/zlt-web/src/services/ant-design-pro/typings.d.ts
T
2022-10-04 00:12:49 +08:00

60 lines
1.0 KiB
TypeScript

// @ts-ignore
/* eslint-disable */
declare namespace API {
type Result<T> = {
resp_code?: number;
resp_msg?: number;
datas?: T[];
};
type OptionalResult<T> = {
resp_code?: number;
resp_msg?: number;
datas?: T;
};
type CurrentUser = {
userId?: string;
username?: string;
nickname?: string;
headImgUrl?: string;
sex?: number;
type?: string;
};
type Menu = {
id?: number;
name?: string;
path?: string;
url?: string;
css?: string;
subMenus?: Menu[];
};
type LoginResult = {
access_token?: string;
token_type?: string;
refresh_token?: string;
expires_in?: number;
scope?: string;
account_type?: string;
};
type LoginParams = {
username?: string;
password?: string;
validCode?: string;
deviceId?: string;
};
type ErrorResponse = {
/** 业务约定的错误码 */
errorCode: string;
/** 业务上的错误信息 */
errorMessage?: string;
/** 业务上的请求是否成功 */
success?: boolean;
};
}