import request from '@/utils/request'

// 查询价目表系统列表
export function listPriceList(query) {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList/list',
    method: 'get',
    params: query
  })
}

// 查询价目表系统详细
export function getPriceList(id) {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList/' + id,
    method: 'get'
  })
}

// 查询任务表详细
export function getTaskTypeList() {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList/taskTypeList' ,
    method: 'get'
  })
}


// 新增价目表系统
export function addPriceList(data) {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList',
    method: 'post',
    data: data
  })
}

// 修改价目表系统
export function updatePriceList(data) {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList',
    method: 'put',
    data: data
  })
}

// 删除价目表系统
export function delPriceList(id) {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList/' + id,
    method: 'delete'
  })
}

//获取租户列表
export function getTenantList(query) {
  request.defaults.baseURL = '/ezhizao-yzbh-sys'
  return request({
    url: '/priceList/priceList/tenantList' ,
    method: 'get',
    params: query
  })
}
