import request from '@/utils/request'

// 歌手列表
export function list(data) {
  return request({
    url: `/admin/singer/list`,
    method: 'post',
    data
  })
}

// 新增 编辑
export function submit(data) {
  return request({
    url: `/admin/singer/addOrUpdate`,
    method: 'post',
    data
  })
}

// 详情
export function detail(id) {
  return request({
    url: `/admin/singer/queryById/${id}`,
    method: 'get'
  })
}

// 删除
export function remove(id) {
  return request({
    url: `/admin/singer/remove/${id}`,
    method: 'delete'
  })
}

// 上下架
export function change(ids, status) {
  return request({
    url: `/admin/singer/hitOrSold/${ids}/${status}`,
    method: 'get'
  })
}

// 查询歌手
export function selectSinger(name){
  return request({
    url: `/admin/singer/querySingerlistByName/${name}`,
    method: 'get'
  })
}