import request from '@/utils/request'




//移除黑名单
export function delBlacklist(data) {
  return request({
    url: '/laboratory/violation/delBlacklistByPc',
    method: 'post',
    data: data
  })
}

//移除负面清单
export function delNegivelist(data) {
  return request({
    url: '/laboratory/violation/delNegivelistByPc',
    method: 'post',
    data: data
  })
}

//添加黑名单
export function blackAdd(data) {
  return request({
    url: '/laboratory/violation/blackAdd',
    method: 'post',
    data: data
  })
}

// 查询学期设置列表
export function getSemesterList(query) {
  return request({
    url: '/laboratory/semester/getSemesterList',
    method: 'get',
    params: query
  })
}



// 查询个人黑名单历史记录
export function myBlackDetail(query) {
  return request({
    url: '/laboratory/blacklist/myBlackDetail',
    method: 'get',
    params: query
  })
}

// 查询个人负面清单列表列表
export function negativeListHistory(query) {
  return request({
    url: '/laboratory/negativeListHistory/getIdlist',
    method: 'get',
    params: query
  })
}

// 查询个人违规历史记录列表
export function getByIdlist(query) {
  return request({
    url: '/laboratory/violationHistoryRecord/byIdlist',
    method: 'get',
    params: query
  })
}

// 查询我的积分记录列表
export function myListRecord(query) {
  return request({
    url: '/exam/points/record/list/my',
    method: 'get',
    params: query
  })
}

// 查询实验室进出记录列表
export function getMyPointsLoglist(query) {
  return request({
    url: '/exam/points/record/getMyPointsLoglist',
    method: 'get',
    params: query
  })
}

// 奖励分页面个人信息
export function getMyPointsLogInfo(query) {
  return request({
    url: '/exam/points/record/getMyPointsLogInfo',
    method: 'get',
    params: query
  })
}


// 查询违规记录详细
export function getViolation(id) {
  return request({
    url: '/laboratory/violation/' + id,
    method: 'get'
  })
}

// 删除违规记录
export function delViolation(id) {
  return request({
    url: '/laboratory/violation/' + id,
    method: 'delete'
  })
}

// 新增违规记录
export function addViolation(data) {
  return request({
    url: '/laboratory/violation',
    method: 'post',
    data: data
  })
}

// 修改违规记录
export function updateViolation(data) {
  return request({
    url: '/laboratory/violation',
    method: 'put',
    data: data
  })
}

//加入黑名单
export function joinBlackList(id) {
  return request({
    url: '/laboratory/violation/joinBlackList/'+id,
    method: 'post'
  })
}

//获取违规类型
export function violationSiteType(query) {
  return request({
    url: '/laboratory/violationSite/type',
    method: 'get',
    params: query
  })
}


//根据输入值查询除法方式
export function getIntegralMatchingRules(query) {
  return request({
    url: '/exam/violation/getIntegralMatchingRules',
    method: 'get',
    params: query
  })
}

// 新增黑名单
export function addBlacklist(data) {
  return request({
    url: '/laboratory/blacklist',
    method: 'post',
    data: data
  })
}

// 查询实验室字典列表
export function getSubjectDictByViolation(data) {
  return request({
    url: '/laboratory/subject/getSubjectDictByViolation',
    method: 'get',
    params: data
  })
}

// 查询违规记录详情列表
export function violationHistoryRecord(query) {
  return request({
    url: '/laboratory/violationHistoryRecord/list',
    method: 'get',
    params: query
  })
}

// 查询历史记录
export function getBlackDetail(query) {
  return request({
    url: '/laboratory/blacklist/getBlackDetail',
    method: 'get',
    params: query
  })
}

// 查询违规违设置
export function listSite(query) {
  return request({
    url: '/laboratory/violationSite/list',
    method: 'get',
    params: query
  })
}

// 提交违规违设置
export function violationSite(data) {
  return request({
    url: '/laboratory/violationSite',
    method: 'post',
    data: data
  })
}
/************* 违规记录 *************/
// 违规记录-列表
export function examViolationList(data) {
  return request({
    url: '/exam/violation/list',
    method: 'post',
    data: data
  })
}
//添加违规记录
export function examViolationAdd(data) {
  return request({
    url: '/exam/violation/add',
    method: 'post',
    data: data
  })
}
//违规列表-加入黑名单
export function examViolationBlackAdd(data) {
  return request({
    url: '/exam/violation/blackAdd',
    method: 'post',
    data: data
  })
}
//违规列表-移除黑名单
export function examViolationDelBlacklist(data) {
  return request({
    url: '/exam/violation/delBlacklist',
    method: 'post',
    data: data
  })
}
//违规列表-移除负面清单
export function examViolationDelNegivelist(data) {
  return request({
    url: '/exam/violation/delNegivelist',
    method: 'post',
    data: data
  })
}
//违规记录-历史记录
export function examViolationHistoryList(data) {
  return request({
    url: '/exam/violation/historyList',
    method: 'post',
    data: data
  })
}
//违规记录-违规类型下拉列表
export function examViolationSiteGetListByType(query) {
  return request({
    url: '/exam/violationSite/getListByType',
    method: 'get',
    params: query
  })
}

/************* 积分列表 *************/

// 查询用户积分记录列表
export function examPointsRecordList(data) {
  return request({
    url: '/exam/points/record/list',
    method: 'post',
    data: data
  })
}

// 查询用户积分记录详细
export function getRecord(id) {
  return request({
    url: '/exam/points/record/' + id,
    method: 'get'
  })
}

// 删除用户积分记录
export function delRecord(id) {
  return request({
    url: '/exam/points/record/' + id,
    method: 'delete'
  })
}

// 新增用户积分记录
export function addRecord(data) {
  return request({
    url: '/exam/points/record',
    method: 'post',
    data: data
  })
}

// 修改用户积分记录
export function updateRecord(data) {
  return request({
    url: '/exam/points/record',
    method: 'put',
    data: data
  })
}
// 查询用户积分记录列表
export function examPointsRecordGetPointsLoglist(data) {
  return request({
    url: '/exam/points/record/getPointsLoglist',
    method: 'post',
    data: data
  })
}

// 查询用户积分记录列表
export function examPointsRecordGetPointsLoglistByReward(data) {
  return request({
    url: '/exam/points/record/getPointsLoglistByReward',
    method: 'post',
    data: data
  })
}
/************* 违规设置 *************/
// 违规设置-获取
export function examViolationSiteList(query) {
  return request({
    url: '/exam/violationSite/list',
    method: 'get',
    params: query
  })
}
// 违规设置-提交
export function examViolationSiteAdd(data) {
  return request({
    url: '/exam/violationSite/add',
    method: 'post',
    data: data
  })
}
/************* 信用分设置 *************/
// 信用分设置-获取
export function examMarkConfigList(data) {
  return request({
    url: '/exam/markConfig/list',
    method: 'post',
    data: data
  })
}
// 信用分设置-提交
export function examMarkConfigAdd(data) {
  return request({
    url: '/exam/markConfig/add',
    method: 'post',
    data: data
  })
}
// 信用分设置-修改
export function examMarkConfigEdit(data) {
  return request({
    url: '/exam/markConfig/edit',
    method: 'post',
    data: data
  })
}
/************* 奖励分设置 *************/
// 奖励分设置-获取
export function examRewardConfigList(data) {
  return request({
    url: '/exam/rewardConfig/list',
    method: 'post',
    data: data
  })
}
// 奖励分设置-提交
export function examRewardConfigEdit(data) {
  return request({
    url: '/exam/rewardConfig/edit',
    method: 'post',
    data: data
  })
}
/************* 个人违规记录 *************/
// 个人违规记录-获取
export function examViolationMyList(data) {
  return request({
    url: '/exam/violation/myList',
    method: 'post',
    data: data
  })
}
/************* 积分明细 *************/
// 积分明细-信用分/奖励分
export function examPointsRecordGetMyPointsLogInfo(data) {
  return request({
    url: '/exam/points/record/getMyPointsLogInfo',
    method: 'post',
    data: data
  })
}
// 积分明细-信用分/奖励分-列表
export function examPointsRecordGetMyPointsLoglist(data) {
  return request({
    url: '/exam/points/record/getMyPointsLoglist',
    method: 'post',
    data: data
  })
}
