2025-01-08 15:25:03 +00:00
|
|
|
import {
|
|
|
|
|
httpDeleteInterceptor,
|
|
|
|
|
httpGetInterceptor,
|
|
|
|
|
httpPostInterceptor,
|
|
|
|
|
} from "../http-config/http-interceptor-service";
|
|
|
|
|
|
2025-09-27 05:25:36 +00:00
|
|
|
export async function getUserListAll() {
|
|
|
|
|
const url = `users/pagination/all?enablePage=0`;
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
2025-01-08 15:25:03 +00:00
|
|
|
export async function AdministrationUserList(
|
|
|
|
|
id: string,
|
|
|
|
|
page: number,
|
|
|
|
|
name = "",
|
|
|
|
|
size: string,
|
|
|
|
|
featureId: string,
|
|
|
|
|
role = ""
|
|
|
|
|
) {
|
|
|
|
|
const url = `users/pagination/internal?enablePage=1&size=${size}&page=${page}&levelId=${id}&name=${name}&featureId=${featureId}&roleFilter=${role}`;
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function AdministrationLevelList() {
|
|
|
|
|
const url = "users/user-levels/list";
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function getListEducation() {
|
|
|
|
|
const url = "users/user-educations/list";
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function getListSchools() {
|
|
|
|
|
const url = "users/user-schools/list";
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
2025-03-03 02:46:53 +00:00
|
|
|
|
2025-01-08 15:25:03 +00:00
|
|
|
export async function getListCompetencies() {
|
|
|
|
|
const url = "users/user-competencies/list";
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
2025-03-03 02:46:53 +00:00
|
|
|
export async function getListExperiences() {
|
|
|
|
|
const url = "users/user-experiences/list";
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
2025-01-08 15:25:03 +00:00
|
|
|
export async function saveUserInternal(data: any) {
|
|
|
|
|
const url = "users/save";
|
|
|
|
|
return httpPostInterceptor(url, data);
|
|
|
|
|
}
|
|
|
|
|
|
2025-06-22 05:08:08 +00:00
|
|
|
export async function checkRolePlacementsAvailability(data: any) {
|
|
|
|
|
const url = "users/role-placements/availability";
|
|
|
|
|
return httpPostInterceptor(url, data);
|
|
|
|
|
}
|
|
|
|
|
|
2025-03-03 02:46:53 +00:00
|
|
|
export async function saveUserRolePlacements(data: any) {
|
|
|
|
|
const url = "users/role-placements";
|
|
|
|
|
return httpPostInterceptor(url, data);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function getUserRolePlacements(userId: number) {
|
|
|
|
|
const url = `users/role-placements?userId=${userId}`;
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
2025-01-08 15:25:03 +00:00
|
|
|
export async function getUserById(id: string) {
|
|
|
|
|
const url = `users?id=${id}`;
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|
2025-01-09 12:28:37 +00:00
|
|
|
|
|
|
|
|
export async function disableUser(userId: number | string) {
|
|
|
|
|
const url = `users/disable-user?userId=${userId}`;
|
|
|
|
|
return httpPostInterceptor(url);
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export async function deleteUser(userId: number | string) {
|
|
|
|
|
const url = `users/delete-user?userId=${userId}`;
|
|
|
|
|
return httpDeleteInterceptor(url);
|
|
|
|
|
}
|
2025-05-26 10:48:12 +00:00
|
|
|
|
|
|
|
|
export async function getOperatorUser(typeId: any) {
|
|
|
|
|
const url = `users/search-operator-user?code=opt-id&typeId=${typeId}`;
|
|
|
|
|
return httpGetInterceptor(url);
|
|
|
|
|
}
|