Skip to content

Commit e4475a4

Browse files
committed
fix: use v2 api version for user & permission list for backward compatability
1 parent 441de04 commit e4475a4

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

src/Pages/GlobalConfigurations/Authorization/authorization.service.ts

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,9 @@ export const getUserList = async (
5656
try {
5757
const {
5858
result: { users, totalCount },
59-
} = (await get(getUrlWithSearchParams(Routes.USER, queryParams ?? {}), { signal })) as ResponseType<{
59+
} = (await get(getUrlWithSearchParams(`${Routes.USER}/${Routes.API_VERSION_V2}`, queryParams ?? {}), {
60+
signal,
61+
})) as ResponseType<{
6062
users: UserDto[]
6163
totalCount: number
6264
}>
@@ -103,7 +105,10 @@ export const getPermissionGroupList = async (
103105
try {
104106
const {
105107
result: { roleGroups: permissionGroups, totalCount },
106-
} = (await get(getUrlWithSearchParams(Routes.USER_ROLE_GROUP, queryParams ?? {}), { signal })) as ResponseType<{
108+
} = (await get(
109+
getUrlWithSearchParams(`${Routes.USER_ROLE_GROUP}/${Routes.API_VERSION_V2}`, queryParams ?? {}),
110+
{ signal },
111+
)) as ResponseType<{
107112
roleGroups: PermissionGroupDto[]
108113
totalCount: number
109114
}>

0 commit comments

Comments
 (0)