diff options
author | philippe-perrin-sonarsource <philippe.perrin@sonarsource.com> | 2022-01-27 11:06:59 +0100 |
---|---|---|
committer | sonartech <sonartech@sonarsource.com> | 2022-01-27 20:03:05 +0000 |
commit | dca8354af94e9feb46ea2312857e000aaa232372 (patch) | |
tree | 336b645749ab1fb1b1abdac19a69c70257e98b68 /server/sonar-web/src/main/js/api/user_groups.ts | |
parent | 85f744be340d8f404978341186dd77cc05584f31 (diff) | |
download | sonarqube-dca8354af94e9feb46ea2312857e000aaa232372.tar.gz sonarqube-dca8354af94e9feb46ea2312857e000aaa232372.zip |
SONAR-15945 Get rid of T namespace in sonar-web
Diffstat (limited to 'server/sonar-web/src/main/js/api/user_groups.ts')
-rw-r--r-- | server/sonar-web/src/main/js/api/user_groups.ts | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/server/sonar-web/src/main/js/api/user_groups.ts b/server/sonar-web/src/main/js/api/user_groups.ts index bbb8e95a5f8..09ba9bad023 100644 --- a/server/sonar-web/src/main/js/api/user_groups.ts +++ b/server/sonar-web/src/main/js/api/user_groups.ts @@ -19,13 +19,14 @@ */ import throwGlobalError from '../app/utils/throwGlobalError'; import { getJSON, post, postJSON } from '../helpers/request'; +import { Group, Paging, UserSelected } from '../types/types'; export function searchUsersGroups(data: { f?: string; p?: number; ps?: number; q?: string; -}): Promise<{ groups: T.Group[]; paging: T.Paging }> { +}): Promise<{ groups: Group[]; paging: Paging }> { return getJSON('/api/user_groups/search', data).catch(throwGlobalError); } @@ -36,7 +37,7 @@ export function getUsersInGroup(data: { ps?: number; q?: string; selected?: string; -}): Promise<T.Paging & { users: T.UserSelected[] }> { +}): Promise<Paging & { users: UserSelected[] }> { return getJSON('/api/user_groups/users', data).catch(throwGlobalError); } @@ -48,7 +49,7 @@ export function removeUserFromGroup(data: { id?: string; name?: string; login?: return post('/api/user_groups/remove_user', data).catch(throwGlobalError); } -export function createGroup(data: { description?: string; name: string }): Promise<T.Group> { +export function createGroup(data: { description?: string; name: string }): Promise<Group> { return postJSON('/api/user_groups/create', data).then(r => r.group, throwGlobalError); } |