// @ts-ignore
/* eslint-disable */
import request from '@/request/http'

/** 修改 修改UpdateVO中不为空的字段 PUT /basePosition */
export async function update1(body: API.BasePositionUpdateVO, options?: { [key: string]: any }) {
  return request<API.RBasePosition>(`/base/basePosition`, {
    method: 'PUT',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  })
}

/** 新增 POST /basePosition */
export async function save1(body: API.BasePositionSaveVO, options?: { [key: string]: any }) {
  return request<API.RBasePosition>(`/base/basePosition`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  })
}

/** 删除 DELETE /basePosition */
export async function delete2(body: number[], options?: { [key: string]: any }) {
  return request<API.RBoolean>(`/base/basePosition`, {
    method: 'DELETE',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  })
}

/** 单体查询 单体查询 GET /basePosition/${param0} */
export async function get2(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.get2Params,
  options?: { [key: string]: any }
) {
  const { id: param0, ...queryParams } = params
  return request<API.RBasePositionResultVO>(`/base/basePosition/${param0}`, {
    method: 'GET',
    params: { ...queryParams },
    ...(options || {})
  })
}

/** 检测名称是否可用 GET /basePosition/check */
export async function check1(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.check1Params,
  options?: { [key: string]: any }
) {
  return request<API.RBoolean>(`/base/basePosition/check`, {
    method: 'GET',
    params: {
      ...params
    },
    ...(options || {})
  })
}

/** 复制 POST /basePosition/copy */
export async function copy1(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.copy1Params,
  options?: { [key: string]: any }
) {
  return request<API.RBasePosition>(`/base/basePosition/copy`, {
    method: 'POST',
    params: {
      ...params
    },
    ...(options || {})
  })
}

/** 查询单体详情 GET /basePosition/detail */
export async function getDetail2(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.getDetail2Params,
  options?: { [key: string]: any }
) {
  return request<API.RBasePositionResultVO>(`/base/basePosition/detail`, {
    method: 'GET',
    params: {
      ...params
    },
    ...(options || {})
  })
}

/** 根据Id批量查询 根据Id批量查询 POST /basePosition/findByIds */
export async function findByIds2(body: number[], options?: { [key: string]: any }) {
  return request<API.RListBasePositionResultVO>(`/base/basePosition/findByIds`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  })
}

/** 分页列表查询 POST /basePosition/page */
export async function page2(
  body: API.PageParamsBasePositionPageQuery,
  options?: { [key: string]: any }
) {
  return request<API.RIPageBasePositionResultVO>(`/base/basePosition/page`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  })
}

/** 批量查询 批量查询 POST /basePosition/query */
export async function query2(body: API.BasePositionPageQuery, options?: { [key: string]: any }) {
  return request<API.RListBasePositionResultVO>(`/base/basePosition/query`, {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json'
    },
    data: body,
    ...(options || {})
  })
}
