mirror of
https://github.com/soybeanjs/soybean-admin.git
synced 2025-11-13 12:13:43 +08:00
refactor(projects): rename directory serviceAlova to service-alova
This commit is contained in:
20
src/service-alova/api/route.ts
Normal file
20
src/service-alova/api/route.ts
Normal file
@@ -0,0 +1,20 @@
|
||||
import { alova } from '../request';
|
||||
|
||||
/** get constant routes */
|
||||
export function fetchGetConstantRoutes() {
|
||||
return alova.Get<Api.Route.MenuRoute[]>('/route/getConstantRoutes');
|
||||
}
|
||||
|
||||
/** get user routes */
|
||||
export function fetchGetUserRoutes() {
|
||||
return alova.Get<Api.Route.UserRoute>('/route/getUserRoutes');
|
||||
}
|
||||
|
||||
/**
|
||||
* whether the route is exist
|
||||
*
|
||||
* @param routeName route name
|
||||
*/
|
||||
export function fetchIsRouteExist(routeName: string) {
|
||||
return alova.Get<boolean>('/route/isRouteExist', { params: { routeName } });
|
||||
}
|
||||
Reference in New Issue
Block a user