82 lines
1.4 KiB
JavaScript
82 lines
1.4 KiB
JavaScript
|
|
import request from '@/router/axios';
|
||
|
|
|
||
|
|
export const getList = (current, size, params) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/list',
|
||
|
|
method: 'get',
|
||
|
|
params: {
|
||
|
|
...params,
|
||
|
|
current,
|
||
|
|
size,
|
||
|
|
}
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const getLazyList = (parentId, params) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/lazy-list',
|
||
|
|
method: 'get',
|
||
|
|
params: {
|
||
|
|
...params,
|
||
|
|
parentId
|
||
|
|
}
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const remove = (ids) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/remove',
|
||
|
|
method: 'post',
|
||
|
|
params: {
|
||
|
|
ids,
|
||
|
|
}
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const add = (row) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/submit',
|
||
|
|
method: 'post',
|
||
|
|
data: row
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const update = (row) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/submit',
|
||
|
|
method: 'post',
|
||
|
|
data: row
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const getDept = (id) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/detail',
|
||
|
|
method: 'get',
|
||
|
|
params: {
|
||
|
|
id,
|
||
|
|
}
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const getDeptTree = (tenantId) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/tree',
|
||
|
|
method: 'get',
|
||
|
|
params: {
|
||
|
|
tenantId,
|
||
|
|
}
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|
||
|
|
export const getDeptLazyTree = (parentId) => {
|
||
|
|
return request({
|
||
|
|
url: '/api/jobslink-api/system/dept/lazy-tree',
|
||
|
|
method: 'get',
|
||
|
|
params: {
|
||
|
|
parentId
|
||
|
|
}
|
||
|
|
})
|
||
|
|
}
|
||
|
|
|