import { request } from '@/api/request2.js'

// 查询收藏列表
export function listCollect(query) {
  return request({
    url: '/mudu/collect/list',
    method: 'get',
    params: query,
  })
}

// 获取收藏详细
export function getCollect(id) {
  return request({
    url: '/mudu/collect/' + id,
    method: 'get',
  })
}

// 新增收藏
export function addCollect(data) {
  return request({
    url: '/mudu/collect',
    method: 'post',
    data: data,
  })
}

// 修改收藏
export function updateCollect(data) {
  return request({
    url: '/mudu/collect',
    method: 'put',
    data
  })
}

// 删除收藏
export function delCollect(id) {
  return request({
    url: '/mudu/collect/' + id,
    method: 'delete',
  })
}
