Files
ruoyi-plus-soybean/src/typings/api.d.ts
2023-12-14 21:45:29 +08:00

43 lines
729 B
TypeScript

/**
* Namespace Api
*
* All backend api type
*/
declare namespace Api {
/**
* Namespace Auth
*
* Backend api module: "auth"
*/
namespace Auth {
interface LoginToken {
token: string;
refreshToken: string;
}
interface UserInfo {
userId: string;
userName: string;
roles: string[];
}
}
/**
* Namespace Route
*
* Backend api module: "route"
*/
namespace Route {
type ElegantConstRoute = import('@elegant-router/types').ElegantConstRoute;
interface MenuRoute extends ElegantConstRoute {
id: string;
}
interface UserRoute {
routes: MenuRoute[];
home: import('@elegant-router/types').LastLevelRouteKey;
}
}
}