web-humas-fe/service/master-user-role.ts

20 lines
596 B
TypeScript

import { httpDeleteInterceptor, httpGet, httpPost } from "./http-config/axios-base-service";
export async function listUserRole() {
const headers = {
"content-type": "application/json",
};
return await httpGet(`/user-roles`, headers);
}
export async function createMasterUserRole(data: any) {
const headers = {
"content-type": "application/json",
};
const pathUrl = `/user-roles`;
return await httpPost(pathUrl, headers, data);
}
export async function deleteMasterUserRole(id: string) {
return await httpDeleteInterceptor(`/user-roles/${id}`);
}