import request from '@/utils/request'

// 查询省市区列表
export function listAddress(query) {
  return request({
    url: '/system/address/list',
    method: 'get',
    params: query
  })
}

export function listAddressList(query) {
  return request({
    url: '/system/address/lists',
    method: 'get',
    params: query
  })
}



// 查询省市区详细
export function getAddress(id) {
  return request({
    url: '/system/address/' + id,
    method: 'get'
  })
}

// 新增省市区
export function addAddress(data) {
  return request({
    url: '/system/address',
    method: 'post',
    data: data
  })
}

// 修改省市区
export function updateAddress(data) {
  return request({
    url: '/system/address',
    method: 'put',
    data: data
  })
}

// 删除省市区
export function delAddress(id) {
  return request({
    url: '/system/address/' + id,
    method: 'delete'
  })
}
