import request from '@/utils/request'
//

// 新增/编辑
export function add(data) {
  return request({
    url: '/web/materials/addMaterial',
    method: 'post',
    data: data
  })
}
// 新增/编辑
export function update(data) {
  return request({
    url: '/web/materials/modifyMaterialInfo',
    method: 'put',
    data: data
  })
}
// 详情
export function getInfo(resourcesId) {
  return request({
    url: '/web/materials/getMaterialDetail',
    method: 'get',
  })
}
// 删除
export function remove(materialIds) {
  return request({
    url: '/web/materials/deleteMaterials',
    method: 'delete',
    params: {
      materialIds
    }
  })
}
// 列表
export function list(params) {
  return request({
    url: '/web/materials/getMaterials',
    method: 'get',
    params: params
  })
}
