Files

53 lines
922 B
JavaScript
Raw Normal View History

2023-05-17 09:56:28 +08:00
import request from "@/utils/request";
2023-05-09 15:21:05 +08:00
// 查询部门列表
export function listDept(query) {
return request({
2023-05-17 09:56:28 +08:00
url: "/system/dept/list",
method: "get",
params: query,
});
2023-05-09 15:21:05 +08:00
}
// 查询部门列表(排除节点)
export function listDeptExcludeChild(deptId) {
return request({
2023-05-17 09:56:28 +08:00
url: "/system/dept/list/exclude/" + deptId,
method: "get",
});
2023-05-09 15:21:05 +08:00
}
// 查询部门详细
export function getDept(deptId) {
return request({
2023-05-17 09:56:28 +08:00
url: "/system/dept/" + deptId,
method: "get",
});
2023-05-09 15:21:05 +08:00
}
// 新增部门
export function addDept(data) {
return request({
2023-05-17 09:56:28 +08:00
url: "/system/dept",
method: "post",
data: data,
});
2023-05-09 15:21:05 +08:00
}
// 修改部门
export function updateDept(data) {
return request({
2023-05-17 09:56:28 +08:00
url: "/system/dept",
method: "put",
data: data,
});
2023-05-09 15:21:05 +08:00
}
// 删除部门
export function delDept(deptId) {
return request({
2023-05-17 09:56:28 +08:00
url: "/system/dept/" + deptId,
method: "delete",
});
}