yinghe-lowcode-zln
Version:
基于vue、ant-design-vue,datagrid的低代码平台
87 lines (76 loc) • 1.53 kB
JavaScript
import { axios } from '@/utils/request'
// 查询组织列表
export function listOrg (query) {
return axios({
url: '/system/org/list',
method: 'get',
params: query
})
}
// 根据用户名查询组织列表
export function userOrg (data) {
return axios({
url: '/system/org/loginName',
method: 'get',
params: data
})
}
// 切换用户组织
export function changeUserOrg (id) {
return axios({
url: '/auth/changeOrg/'+id,
method: 'get'
})
}
// 查询组织列表(排除节点)
export function listOrgExcludeChild (orgId) {
return axios({
url: '/system/org/list/exclude/' + orgId,
method: 'get'
})
}
// 查询组织详细
export function getOrg (orgId) {
return axios({
url: '/system/org/' + orgId,
method: 'get'
})
}
// 查询组织下拉树结构
export function treeselect (params) {
return axios({
url: '/system/org/treeselect',
method: 'get',
params
})
}
// 根据角色ID查询组织树结构
export function roleOrgTreeselect (roleId) {
return axios({
url: '/system/org/roleOrgTreeselect/' + roleId,
method: 'get'
})
}
// 新增组织
export function addOrg (data) {
return axios({
url: '/system/org',
method: 'post',
data: data
})
}
// 修改组织
export function updateOrg (data) {
return axios({
url: '/system/org/edit',
method: 'post',
data: data
})
}
// 删除组织
export function delOrg (orgId) {
return axios({
url: '/system/org/delete/' + orgId,
method: 'get'
})
}