import request from '@/utils/request'

// 查询分级��控管理列表
export function listGradeManage(query) {
  return request({
    url: '/laboratory/gradeManage/list',
    method: 'get',
    params: query
  })
}
// 查询分级��控管理详细
export function getGradeManage(id) {
  return request({
    url: '/laboratory/gradeManage/' + id,
    method: 'get'
  })
}
// 删除分级��控管理
export function delGradeManage(id) {
  return request({
    url: '/laboratory/gradeManage/' + id,
    method: 'delete'
  })
}
// 新增分级��控管理
export function addGradeManage(data) {
  return request({
    url: '/laboratory/gradeManage',
    method: 'post',
    data: data
  })
}
// 修改分级��控管理
export function updateGradeManage(data) {
  return request({
    url: '/laboratory/gradeManage',
    method: 'put',
    data: data
  })
}
//化学品存放页面-获取当前账号学院数据
export function filterDept(query) {
  return request({
    url: '/system/dept/filterDept',
    method: 'get',
    params: query
  })
}
// 查询安全分级所有列表(不带分页)
export function listClassifiedAll(query) {
  return request({
    url: '/laboratory/classified/listAll',
    method: 'get',
    params: query
  })
}
// 查询安全分级类型列表(不带分页)
export function listClasstypeAll(query) {
  return request({
    url: '/laboratory/classtype/listAll',
    method: 'get',
    params: query
  })
}
// 查询实验室类型列表
export function labMoldQueryOption(data) {
  return request({
    url: '/laboratory/labMold/queryOption',
    method: 'post',
    data: data
  })
}

//获取实验室列表
export function listInfo(query) {
  return request({
    url: '/laboratory/subject/listInfo',
    method: 'get',
    params: query
  })
}
// 删除实验室类型
export function queryOption(data) {
  return request({
    url: '/laboratory/labMold/queryOption/',
    method: 'post',
    data: data
  })
}
// 查询用户列表
export function listUser(query) {
  return request({
    url: '/system/user/getNotAuthList',
    method: 'get',
    params: query
  })
}

// 查询院系列表
export function listDepartments() {
  return request({
    url: '/system/dept/departments/list',
    method: 'get'
  })
}
//获取职位列表
export function optionselect(query) {
  return request({
    url: '/system/post/optionselect',
    method: 'get',
    params: query
  })
}

// 查询管控执行记录列表
export function listGradeManageRecord(query) {
  return request({
    url: '/laboratory/gradeManageRecord/list',
    method: 'get',
    params: query
  })
}
// 查询管控执行记录详细
export function getGradeManageRecord(id) {
  return request({
    url: '/laboratory/gradeManageRecord/' + id,
    method: 'get'
  })
}
// 删除管控执行记录
export function delGradeManageRecord(id) {
  return request({
    url: '/laboratory/gradeManageRecord/' + id,
    method: 'delete'
  })
}
// 新增管控执行记录
export function addGradeManageRecord(data) {
  return request({
    url: '/laboratory/gradeManageRecord',
    method: 'post',
    data: data
  })
}
// 修改管控执行记录
export function updateGradeManageRecord(data) {
  return request({
    url: '/laboratory/gradeManageRecord',
    method: 'put',
    data: data
  })
}

//查询分级管控管理工作详情
export function gradeManageWorkInfo(recordId) {
  return request({
    url: '/laboratory/gradeManageWork/'+recordId,
    method: 'get',
  })
}
// 查询分级控管理工作-完成
export function gradeManageWorkFinish(data) {
  return request({
    url: '/laboratory/gradeManageWork/finish',
    method: 'post',
    data: data
  })
}

// 查询分级控管理列表
export function gradeManageWorkList(query) {
  return request({
    url: '/laboratory/gradeManageWork/list',
    method: 'get',
    params: query
  })
}
