/* 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 {
  FeedMediumDto,
  FeedMediumDtoListServiceResponse,
  FeedMediumDtoServiceResponse,
  PageInputFeedMediumDtoGetPageInput,
  ResultOutputFeedMediumDtoGetOutput,
  ResultOutputPageOutputFeedMediumDtoGetPageOutput,
  ResultOutputInt64,
} from './data-contracts'
import { ContentType, HttpClient, RequestParams } from './http-client'
import { AxiosResponse } from 'axios'

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

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

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

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

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

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