import request, { postBlob, handleImport, getBlob } from '@/utils/request'

export function getListV2(params) {
  return request({
    url: `/notice/list/v2?moduleId=${params.moduleId}`,
    method: 'post',
    data: params
  })
}
// 获取列表
export function getList(params) {
  return request({
    url: '/notice/list',
    method: 'get',
    params
  })
}

// 获取详情
export function getDetail(params) {
  return request({
    url: '/notice/detail',
    method: 'get',
    params
  })
}

// 获取阅读记录
export function getDownloadList(params) {
  return request({
    url: '/com/list/download/log',
    method: 'get',
    params
  })
}

// 删除
export function deleteData(params) {
  return request({
    url: '/notice/mark/del',
    method: 'post',
    params
  })
}

// 新增
export function addData(params) {
  return request({
    url: '/notice/add',
    method: 'post',
    data: params
  })
}

// 获取部门列表
export function getDepartmentList(params) {
  return request({
    url: '/admin/websit/tree',
    method: 'get',
    params
  })
}

// 查收
export function confirmCheck(params) {
  return request({
    url: '/notice/mark/read',
    method: 'post',
    params
  })
}
