新增:新增获取路由信息 API(默认前端动态路由处于关闭状态,可通过[页面配置]>[菜单来源于后台]开启)

1.在页面导航栏中通过[页面配置]>[菜单来源于后台]临时启用,刷新后配置失效
2.在前端项目 src/config/setting.json 中,可通过 menuFromServer 配置永久启用
This commit is contained in:
2023-03-09 00:06:02 +08:00
parent fb0effed9a
commit d8ceda4654
24 changed files with 260 additions and 17 deletions

View File

@@ -27,6 +27,6 @@ export function getUserInfo() {
return axios.get<UserState>(`${BASE_URL}/user/info`);
}
export function getMenuList() {
return axios.get<RouteRecordNormalized[]>('/api/user/menu');
export function listRoute() {
return axios.get<RouteRecordNormalized[]>(`${BASE_URL}/route`);
}