import request from '@/utils/request'


//组织列表

export function organizationsList(params) {
    return request({
      url: '/organizations',
      method: 'get',
      params
    })
}
//获取父级组织名称
export function fatherLists(params) {
    return request({
      url: '/organizations-select-options',
      method: 'get',
      params
    })
}

//获取班级
export function classLists(params) {
  return request({
    url: '/staff-class-select-options',
    method: 'get',
    params
  })
}
//编辑组织列表
export function editOrganization(data) {
  return request({
    url: '/organizations/' + data.id,
    method: 'put',
    data
  })
}
//删除组织列表

export function deleteOrganization(data) {
  return request({
    url: '/organizations/' + data,
    method: 'delete',
  })
}
//创建组织

export function buildOrganizations(data) {
  return request({
    url: '/organizations',
    method: 'post',
    data
  })
}