import request from '@/utils/request'

// 查询分类列表, 支持翻页
export function goodsCategoryList(urlParams, data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/list',
    method: 'post',
    data,
    urlParams
  })
}


// 查询分类列表树状
export function goodsCategoryListTree(urlParams, data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/listTree',
    method: 'post',
    data,
    urlParams
  })
}

// 查询分类下拉列表, 不分页
export function goodsCategoryItems(data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/items',
    method: 'post',
    data
  })
}

// 查询分类详情
export function goodsCategoryDetail(data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/detail',
    method: 'post',
    data
  })
}

// 修改分类信息
export function goodsCategoryUpdate(data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/update',
    method: 'post',
    data
  })
}

// 新增分类信息
export function goodsCategoryCreate(data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/create',
    method: 'post',
    data
  })
}

// 删除分类信息
export function goodsCategoryRemove(data) {
  return request({
    url: '/api/v1/mp/admin/goods/category/remove',
    method: 'post',
    data
  })
}
