From c3207c8517780ec2019bd1e0943a62cc29b265d0 Mon Sep 17 00:00:00 2001
From: zhengyiming <540361168@qq.com>
Date: 星期二, 18 二月 2025 14:58:32 +0800
Subject: [PATCH] feat: api
---
src/hooks/useUser.ts | 25 ++++++++++++++-----------
1 files changed, 14 insertions(+), 11 deletions(-)
diff --git a/src/hooks/useUser.ts b/src/hooks/useUser.ts
index d522656..fafac84 100644
--- a/src/hooks/useUser.ts
+++ b/src/hooks/useUser.ts
@@ -1,7 +1,6 @@
import { useUserStore } from '@/store/modules/user';
import { UserUtils } from '@bole-core/core';
// import * as userRoleServices from '@/services/api/UserRole';
-import * as userServices from '@/services/api/User';
import { useQuery, useQueryClient } from '@tanstack/vue-query';
export function useIsSystemAdmin() {
@@ -23,17 +22,21 @@
}
export function useAllRoleList() {
- const { data: allRoleList, refetch } = useQuery({
- queryKey: ['userServices/getAllRoles'],
- queryFn: async () => {
- let res = await userServices.getAllRoles({ showLoading: false });
- return res;
- },
- placeholderData: () => [] as API.RoleInfo[],
- });
+ // const { data: allRoleList, refetch } = useQuery({
+ // queryKey: ['userServices/getAllRoles'],
+ // queryFn: async () => {
+ // let res = await userServices.getAllRoles({ showLoading: false });
+ // return res;
+ // },
+ // placeholderData: () => [] as API.RoleInfo[],
+ // });
+ // return {
+ // allRoleList,
+ // refetch,
+ // };
return {
- allRoleList,
- refetch,
+ allRoleList: [],
+ refetch: () => {},
};
}
--
Gitblit v1.9.1