import request from '@/utils/request'

// 创建资料下载日志
export function createMaterialDownloadLog(data) {
  return request({
    url: '/server/material-download-log/create',
    method: 'post',
    data: data
  })
}

// 更新资料下载日志
export function updateMaterialDownloadLog(data) {
  return request({
    url: '/server/material-download-log/update',
    method: 'post',
    data: data
  })
}

// 删除资料下载日志
export function deleteMaterialDownloadLog(id) {
  return request({
    url: '/server/material-download-log/delete?id=' + id,
    method: 'post'
  })
}

// 获得资料下载日志
export function getMaterialDownloadLog(id) {
  return request({
    url: '/server/material-download-log/get?id=' + id,
    method: 'get'
  })
}

// 获得资料下载日志分页
export function getMaterialDownloadLogPage(params) {
  return request({
    url: '/server/material-download-log/page',
    method: 'get',
    params
  })
}
// 导出资料下载日志 Excel
export function exportMaterialDownloadLogExcel(params) {
  return request({
    url: '/server/material-download-log/export-excel',
    method: 'get',
    params,
    responseType: 'blob'
  })
}
