import request from '@/utils/request'

// 查询margin列表
export function listMargin(query) {
  return request({
    url: '/system/margin/list',
    method: 'get',
    params: query
  })
}

// 查询margin详细
export function getMargin(id) {
  return request({
    url: '/system/margin/' + id,
    method: 'get'
  })
}

// 新增margin
export function addMargin(data) {
  return request({
    url: '/system/margin',
    method: 'post',
    data: data
  })
}

// 修改margin
export function updateMargin(data) {
  return request({
    url: '/system/margin',
    method: 'put',
    data: data
  })
}

// 删除margin
export function delMargin(id) {
  return request({
    url: '/system/margin/' + id,
    method: 'delete'
  })
}
