import request from "@/utils/request";

// 列表
export function list(data) {
  return request({
    url: `/organization/organization/list`,
    method: "post",
    data,
  });
}

// 详情
export function detail(id) {
  return request({
    url: `/organization/organization/${id}`,
    method: "get",
  });
}

// 删除
export function remove(data) {
  return request({
    url: `/organization/organization/remove`,
    method: 'delete',
    data
  })
}

// 企业筛选
export function businessList(data) {
  return request({
    url: `/organization/organization/selectList`,
    method: 'post',
    data
  })
}

// 新增
export function submit(data) {
  return request({
    url: `/organization/organization`,
    method: 'post',
    data
  })
}

// 编辑
export function edit(data) {
  return request({
    url: `/organization/organization`,
    method: 'put',
    data
  })
}

// 状态修改
export function change(data){
  return request({
    url: `/organization/organization/changeStatus`,
    method: 'put',
    data
  })
}

// 企业菜单树
export function reset(data){
  return request({
    url: `/system/user/resetPwdSend`,
    method: 'put',
    data
  })
}

// 所属门店
export function storeSelect(data) {
  return request({
    url: `/store/store/list`,
    method: 'post',
    data
  })
}

// 设备列表
export function deviceList(data) {
  return request({
    url: `/device/version/clientTypeList`,
    method: 'post',
    data
  })
}

// 查询菜单下拉树结构
export function treeselect() {
  return request({
    url: '/system/menu/orgTreeselect',
    method: 'get'
  })
}