import request from '@/utils/request'

// 查询app商品列表
export function listGoods(query) {
  return request({
    url: '/mall/goods/list',
    method: 'get',
    params: query
  })
}

// 查询app商品详细
export function getGoods(id) {
  return request({
    url: '/mall/goods/' + id,
    method: 'get'
  })
}

// 新增app商品
export function addGoods(data) {
  return request({
    url: '/mall/goods',
    method: 'post',
    data: data
  })
}

// 修改app商品
export function updateGoods(data) {
  return request({
    url: '/mall/goods',
    method: 'put',
    data: data
  })
}

// 删除app商品
export function delGoods(id) {
  return request({
    url: '/mall/goods/' + id,
    method: 'delete'
  })
}


// 新增app商品
export function mallGoodsGoodsallGoods(data) {
  return request({
    url: '/mall/mallGoodsGoods/allGoods',
    method: 'post',
    data: data
  })
}
