/* eslint-disable */
/* tslint:disable */
/*
 * ---------------------------------------------------------------
 * ## THIS FILE WAS GENERATED VIA SWAGGER-TYPESCRIPT-API        ##
 * ##                                                           ##
 * ## AUTHOR: adademo / https://github.com/adademo/swagger-typescript-api ##
 * ## SOURCE: https://github.com/adademo/swagger-typescript-api ##
 * ---------------------------------------------------------------
 */

import {
  BasicMediumDto,
  BasicMediumDtoListServiceResponse,
  BasicMediumDtoServiceResponse,
  PageInputBasicMediumDtoGetPageInput,
  ResultOutputBasicMediumDtoGetOutput,
  ResultOutputPageOutputBasicMediumDtoGetPageOutput,
  ResultOutputInt64,
} from './data-contracts'
import { ContentType, HttpClient, RequestParams } from './http-client'
import { AxiosResponse } from 'axios'

export class ItemDefBasicMediumApi<SecurityDataType = unknown> extends HttpClient<SecurityDataType> {
  /**
   * No description
   *
   * @tags basic-medium
   * @name Get
   * @summary 获取初始培养基详情
   * @request GET:/api/admin/item-def-basic-medium/get
   * @secure
   */
  get = (
    query?: {
      /** @format int64 */
      id?: number
    },
    params: RequestParams = {}
  ) =>
    this.request<ResultOutputBasicMediumDtoGetOutput, any>({
      path: `/api/admin/item-def-basic-medium/get`,
      method: 'GET',
      query: query,
      secure: true,
      format: 'json',
      ...params,
    })

  /**
   * No description
   *
   * @tags basic-medium
   * @name GetPage
   * @summary 获取初始培养基分页列表
   * @request POST:/api/admin/item-def-basic-medium/get-page
   * @secure
   */
  getPage = (data: PageInputBasicMediumDtoGetPageInput, params: RequestParams = {}) =>
    this.request<ResultOutputPageOutputBasicMediumDtoGetPageOutput, any>({
      path: `/api/admin/item-def-basic-medium/get-page`,
      method: 'POST',
      body: data,
      secure: true,
      type: ContentType.Json,
      format: 'json',
      ...params,
    })

  /**
   * No description
   *
   * @tags basic-medium
   * @name Add
   * @summary 新增初始培养基
   * @request POST:/api/admin/item-def-basic-medium/add
   * @secure
   */
  add = (data: BasicMediumDto, params: RequestParams = {}) =>
    this.request<ResultOutputInt64, any>({
      path: `/api/admin/item-def-basic-medium/add`,
      method: 'POST',
      body: data,
      secure: true,
      type: ContentType.Json,
      format: 'json',
      ...params,
    })

  /**
   * No description
   *
   * @tags basic-medium
   * @name Update
   * @summary 修改初始培养基
   * @request PUT:/api/admin/item-def-basic-medium/update
   * @secure
   */
  update = (data: BasicMediumDto, params: RequestParams = {}) =>
    this.request<AxiosResponse, any>({
      path: `/api/admin/item-def-basic-medium/update`,
      method: 'PUT',
      body: data,
      secure: true,
      type: ContentType.Json,
      ...params,
    })

  /**
   * No description
   *
   * @tags basic-medium
   * @name Delete
   * @summary 彻底删除初始培养基
   * @request DELETE:/api/admin/item-def-basic-medium/delete
   * @secure
   */
  delete = (
    query?: {
      /** @format int64 */
      id?: number
    },
    params: RequestParams = {}
  ) =>
    this.request<AxiosResponse, any>({
      path: `/api/admin/item-def-basic-medium/delete`,
      method: 'DELETE',
      query: query,
      secure: true,
      ...params,
    })

  /**
   * No description
   *
   * @tags basic-medium
   * @name SoftDelete
   * @summary 删除初始培养基
   * @request DELETE:/api/admin/item-def-basic-medium/soft-delete
   * @secure
   */
  softDelete = (
    query?: {
      /** @format int64 */
      id?: number
    },
    params: RequestParams = {}
  ) =>
    this.request<AxiosResponse, any>({
      path: `/api/admin/item-def-basic-medium/soft-delete`,
      method: 'DELETE',
      query: query,
      secure: true,
      ...params,
    })
}
