From 2b3715f1610b4176d7abe33e34542389cef61853 Mon Sep 17 00:00:00 2001
From: zhuguifei <zhuguifei@zhuguifeideiMac.local>
Date: 星期六, 12 四月 2025 17:12:22 +0800
Subject: [PATCH] Merge branch 'main' of http://lanpucloud.cn:1111/r/eims-master

---
 eims-ui-mobile/src/service/app/user.ts |  150 ++++++++++++++++++++++++++++++++++++++++++++++++++
 1 files changed, 150 insertions(+), 0 deletions(-)

diff --git a/eims-ui-mobile/src/service/app/user.ts b/eims-ui-mobile/src/service/app/user.ts
new file mode 100644
index 0000000..2474272
--- /dev/null
+++ b/eims-ui-mobile/src/service/app/user.ts
@@ -0,0 +1,150 @@
+/* eslint-disable */
+// @ts-ignore
+import request from '@/utils/request';
+import { CustomRequestOptions } from '@/interceptors/request';
+
+import * as API from './types';
+
+/** Create user This can only be done by the logged in user. 杩斿洖鍊�: successful operation POST /user */
+export async function createUser({
+  body,
+  options,
+}: {
+  body: API.User;
+  options?: CustomRequestOptions;
+}) {
+  return request<unknown>('/user', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** Get user by user name GET /user/${param0} */
+export async function getUserByName({
+  params,
+  options,
+}: {
+  // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟openapi榛樿娌℃湁鐢熸垚瀵硅薄)
+  params: API.getUserByNameParams;
+  options?: CustomRequestOptions;
+}) {
+  const { username: param0, ...queryParams } = params;
+
+  return request<API.User>(`/user/${param0}`, {
+    method: 'GET',
+    params: { ...queryParams },
+    ...(options || {}),
+  });
+}
+
+/** Updated user This can only be done by the logged in user. PUT /user/${param0} */
+export async function updateUser({
+  params,
+  body,
+  options,
+}: {
+  // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟openapi榛樿娌℃湁鐢熸垚瀵硅薄)
+  params: API.updateUserParams;
+  body: API.User;
+  options?: CustomRequestOptions;
+}) {
+  const { username: param0, ...queryParams } = params;
+
+  return request<unknown>(`/user/${param0}`, {
+    method: 'PUT',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    params: { ...queryParams },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** Delete user This can only be done by the logged in user. DELETE /user/${param0} */
+export async function deleteUser({
+  params,
+  options,
+}: {
+  // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟openapi榛樿娌℃湁鐢熸垚瀵硅薄)
+  params: API.deleteUserParams;
+  options?: CustomRequestOptions;
+}) {
+  const { username: param0, ...queryParams } = params;
+
+  return request<unknown>(`/user/${param0}`, {
+    method: 'DELETE',
+    params: { ...queryParams },
+    ...(options || {}),
+  });
+}
+
+/** Creates list of users with given input array 杩斿洖鍊�: successful operation POST /user/createWithArray */
+export async function createUsersWithArrayInput({
+  body,
+  options,
+}: {
+  body: API.User[];
+  options?: CustomRequestOptions;
+}) {
+  return request<unknown>('/user/createWithArray', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** Creates list of users with given input array 杩斿洖鍊�: successful operation POST /user/createWithList */
+export async function createUsersWithListInput({
+  body,
+  options,
+}: {
+  body: API.User[];
+  options?: CustomRequestOptions;
+}) {
+  return request<unknown>('/user/createWithList', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** Logs user into the system GET /user/login */
+export async function loginUser({
+  params,
+  options,
+}: {
+  // 鍙犲姞鐢熸垚鐨凱aram绫诲瀷 (闈瀊ody鍙傛暟openapi榛樿娌℃湁鐢熸垚瀵硅薄)
+  params: API.loginUserParams;
+  options?: CustomRequestOptions;
+}) {
+  return request<string>('/user/login', {
+    method: 'GET',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** Logs out current logged in user session 杩斿洖鍊�: successful operation GET /user/logout */
+export async function logoutUser({
+  options,
+}: {
+  options?: CustomRequestOptions;
+}) {
+  return request<unknown>('/user/logout', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}

--
Gitblit v1.9.3