import request from '@/utils/request'

// 查询参数配置列表
export function listParams(query) {
  return request({
    url: '/test/param/list',
    method: 'get',
    params: query
  })
}

// 查询参数配置详细
export function getParams(id) {
  return request({
    url: '/test/param/' + id,
    method: 'get'
  })
}

// 新增参数配置
export function addParams(data) {
  return request({
    url: '/test/param',
    method: 'post',
    data: data
  })
}

// 修改参数配置
export function updateParams(data) {
  return request({
    url: '/test/param',
    method: 'put',
    data: data
  })
}

// 删除参数配置
export function delParams(id) {
  return request({
    url: '/test/param/' + id,
    method: 'delete'
  })
}

// 参数来源
export function getParamSources(id) {
  return request({
    url: '/test/param/sources',
    method: 'get'
  })
}

// 参数类型
export function getParamTypes(id) {
  return request({
    url: '/test/param/types',
    method: 'get'
  })
}
