// @ts-ignore
/* eslint-disable */
import request from "../request";

/** 订单供应商列表 GET /operation/pageOrderSupplier */
export async function pageOrderSupplier(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: BusinessAPI.pageOrderSupplierParams,
  options?: { [key: string]: any },
) {
  return request<BusinessAPI.PageResponseOrderSupplierVO>(
    "/operation/pageOrderSupplier",
    {
      method: "GET",
      params: {
        ...params,
        orderSupplierPageQry: undefined,
        ...params["orderSupplierPageQry"],
      },
      ...(options || {}),
    },
  );
}

/** 订单供应商更新 PUT /operation/updateOrderSupplier */
export async function updateOrderSupplier(
  body: BusinessAPI.OrderSupplierUpdateCmd,
  options?: { [key: string]: any },
) {
  return request<BusinessAPI.SingleResponseOrderSupplierVO>(
    "/operation/updateOrderSupplier",
    {
      method: "PUT",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    },
  );
}

/** 订单供应商更新 PATCH /operation/updateOrderSupplier */
export async function updateOrderSupplier1(
  body: BusinessAPI.OrderSupplierUpdateCmd,
  options?: { [key: string]: any },
) {
  return request<BusinessAPI.SingleResponseOrderSupplierVO>(
    "/operation/updateOrderSupplier",
    {
      method: "PATCH",
      headers: {
        "Content-Type": "application/json",
      },
      data: body,
      ...(options || {}),
    },
  );
}
