import request from '@/utils/request'

// 查询物理书架列表
export function listBookshelf(query) {
  return request({
    url: '/dangan/bookshelf/list',
    method: 'get',
    params: query
  })
}

// 查询物理书架详细
export function getBookshelf(shelfId) {
  return request({
    url: '/dangan/bookshelf/' + shelfId,
    method: 'get'
  })
}

// 新增物理书架
export function addBookshelf(data) {
  return request({
    url: '/dangan/bookshelf',
    method: 'post',
    data: data
  })
}

// 修改物理书架
export function updateBookshelf(data) {
  return request({
    url: '/dangan/bookshelf',
    method: 'put',
    data: data
  })
}

// 删除物理书架
export function delBookshelf(shelfId) {
  return request({
    url: '/dangan/bookshelf/' + shelfId,
    method: 'delete'
  })
}
