| 12345678910111213141516171819202122232425262728 |
- /**
- * Generated by orval v7.0.1 🍺
- * Do not edit manually.
- * Serve API
- * Serve应用接口文档
- * OpenAPI spec version: 0.0.1-SNAPSHOT
- */
- import type { ResponseUploadVo, UploadBody, UploadParams } from "./models";
- import { customAxiosInstance } from "../util/axios-instance";
- export const getAttachmentController = () => {
- /**
- * @summary 上传附件到OSS(需对接OSS配置)
- */
- const upload = (uploadBody: UploadBody, params?: UploadParams) => {
- return customAxiosInstance<ResponseUploadVo>({
- url: `/attachments/upload`,
- method: "POST",
- headers: { "Content-Type": "application/json" },
- data: uploadBody,
- params,
- });
- };
- return { upload };
- };
- export type UploadResult = NonNullable<
- Awaited<ReturnType<ReturnType<typeof getAttachmentController>["upload"]>>
- >;
|