jiangmaniu 4 месяцев назад
Родитель
Сommit
c3bb9c0578

+ 22 - 9
config/config.ts

@@ -150,17 +150,30 @@ export default defineConfig({
    * @doc https://pro.ant.design/zh-cn/docs/openapi/
    */
   openAPI: [
+    // {
+    //   requestLibPath: "import { request } from '@umijs/max'",
+    //   // 或者使用在线的版本
+    //   // schemaPath: "https://gw.alipayobjects.com/os/antfincdn/M%24jrzTTYJN/oneapi.json"
+    //   schemaPath: join(__dirname, 'oneapi.json'),
+    //   mock: false,
+    // },
+    // {
+    //   requestLibPath: "import { request } from '@umijs/max'",
+    //   schemaPath: 'https://gw.alipayobjects.com/os/antfincdn/M%24jrzTTYJN/oneapi.json',
+
     {
-      requestLibPath: "import { request } from '@umijs/max'",
-      // 或者使用在线的版本
-      // schemaPath: "https://gw.alipayobjects.com/os/antfincdn/M%24jrzTTYJN/oneapi.json"
-      schemaPath: join(__dirname, 'oneapi.json'),
-      mock: false,
-    },
-    {
-      requestLibPath: "import { request } from '@umijs/max'",
-      schemaPath: 'https://gw.alipayobjects.com/os/antfincdn/CA1dOm%2631B/openapi.json',
+      requestLibPath: "import { invoke as request } from '@/core/network'",
+      schemaPath: 'https://sect.nosum.cn/v3/api-docs',
+      namespace: 'SectApi',
       projectName: 'swagger',
+      hook: {
+        // customFunctionName: (...arg) => {
+        //   console.log('sect customFunctionName:', ...arg)
+        // },
+        // customClassName: (...arg) => {
+        //   console.log('sect customClassName:', ...arg)
+        // }
+      }
     },
   ],
   mfsu: {

+ 0 - 593
config/oneapi.json

@@ -1,593 +0,0 @@
-{
-  "openapi": "3.0.1",
-  "info": {
-    "title": "Ant Design Pro",
-    "version": "1.0.0"
-  },
-  "servers": [
-    {
-      "url": "http://localhost:8000/"
-    },
-    {
-      "url": "https://localhost:8000/"
-    }
-  ],
-  "paths": {
-    "/api/currentUser": {
-      "get": {
-        "tags": ["api"],
-        "description": "获取当前的用户",
-        "operationId": "currentUser",
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/CurrentUser"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        }
-      },
-      "x-swagger-router-controller": "api"
-    },
-    "/api/login/captcha": {
-      "post": {
-        "description": "发送验证码",
-        "operationId": "getFakeCaptcha",
-        "tags": ["login"],
-        "parameters": [
-          {
-            "name": "phone",
-            "in": "query",
-            "description": "手机号",
-            "schema": {
-              "type": "string"
-            }
-          }
-        ],
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/FakeCaptcha"
-                }
-              }
-            }
-          }
-        }
-      }
-    },
-    "/api/login/outLogin": {
-      "post": {
-        "description": "登录接口",
-        "operationId": "outLogin",
-        "tags": ["login"],
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "type": "object"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        }
-      },
-      "x-swagger-router-controller": "api"
-    },
-    "/api/login/account": {
-      "post": {
-        "tags": ["login"],
-        "description": "登录接口",
-        "operationId": "login",
-        "requestBody": {
-          "description": "登录系统",
-          "content": {
-            "application/json": {
-              "schema": {
-                "$ref": "#/components/schemas/LoginParams"
-              }
-            }
-          },
-          "required": true
-        },
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/LoginResult"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        },
-        "x-codegen-request-body-name": "body"
-      },
-      "x-swagger-router-controller": "api"
-    },
-    "/api/notices": {
-      "summary": "getNotices",
-      "description": "NoticeIconItem",
-      "get": {
-        "tags": ["api"],
-        "operationId": "getNotices",
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/NoticeIconList"
-                }
-              }
-            }
-          }
-        }
-      }
-    },
-    "/api/rule": {
-      "get": {
-        "tags": ["rule"],
-        "description": "获取规则列表",
-        "operationId": "rule",
-        "parameters": [
-          {
-            "name": "current",
-            "in": "query",
-            "description": "当前的页码",
-            "schema": {
-              "type": "number"
-            }
-          },
-          {
-            "name": "pageSize",
-            "in": "query",
-            "description": "页面的容量",
-            "schema": {
-              "type": "number"
-            }
-          }
-        ],
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/RuleList"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        }
-      },
-      "post": {
-        "tags": ["rule"],
-        "description": "新建规则",
-        "operationId": "addRule",
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/RuleListItem"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        }
-      },
-      "put": {
-        "tags": ["rule"],
-        "description": "新建规则",
-        "operationId": "updateRule",
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/RuleListItem"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        }
-      },
-      "delete": {
-        "tags": ["rule"],
-        "description": "删除规则",
-        "operationId": "removeRule",
-        "responses": {
-          "200": {
-            "description": "Success",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "type": "object"
-                }
-              }
-            }
-          },
-          "401": {
-            "description": "Error",
-            "content": {
-              "application/json": {
-                "schema": {
-                  "$ref": "#/components/schemas/ErrorResponse"
-                }
-              }
-            }
-          }
-        }
-      },
-      "x-swagger-router-controller": "api"
-    },
-    "/swagger": {
-      "x-swagger-pipe": "swagger_raw"
-    }
-  },
-  "components": {
-    "schemas": {
-      "CurrentUser": {
-        "type": "object",
-        "properties": {
-          "name": {
-            "type": "string"
-          },
-          "avatar": {
-            "type": "string"
-          },
-          "userid": {
-            "type": "string"
-          },
-          "email": {
-            "type": "string"
-          },
-          "signature": {
-            "type": "string"
-          },
-          "title": {
-            "type": "string"
-          },
-          "group": {
-            "type": "string"
-          },
-          "tags": {
-            "type": "array",
-            "items": {
-              "type": "object",
-              "properties": {
-                "key": {
-                  "type": "string"
-                },
-                "label": {
-                  "type": "string"
-                }
-              }
-            }
-          },
-          "notifyCount": {
-            "type": "integer",
-            "format": "int32"
-          },
-          "unreadCount": {
-            "type": "integer",
-            "format": "int32"
-          },
-          "country": {
-            "type": "string"
-          },
-          "access": {
-            "type": "string"
-          },
-          "geographic": {
-            "type": "object",
-            "properties": {
-              "province": {
-                "type": "object",
-                "properties": {
-                  "label": {
-                    "type": "string"
-                  },
-                  "key": {
-                    "type": "string"
-                  }
-                }
-              },
-              "city": {
-                "type": "object",
-                "properties": {
-                  "label": {
-                    "type": "string"
-                  },
-                  "key": {
-                    "type": "string"
-                  }
-                }
-              }
-            }
-          },
-          "address": {
-            "type": "string"
-          },
-          "phone": {
-            "type": "string"
-          }
-        }
-      },
-      "LoginResult": {
-        "type": "object",
-        "properties": {
-          "status": {
-            "type": "string"
-          },
-          "type": {
-            "type": "string"
-          },
-          "currentAuthority": {
-            "type": "string"
-          }
-        }
-      },
-      "PageParams": {
-        "type": "object",
-        "properties": {
-          "current": {
-            "type": "number"
-          },
-          "pageSize": {
-            "type": "number"
-          }
-        }
-      },
-      "RuleListItem": {
-        "type": "object",
-        "properties": {
-          "key": {
-            "type": "integer",
-            "format": "int32"
-          },
-          "disabled": {
-            "type": "boolean"
-          },
-          "href": {
-            "type": "string"
-          },
-          "avatar": {
-            "type": "string"
-          },
-          "name": {
-            "type": "string"
-          },
-          "owner": {
-            "type": "string"
-          },
-          "desc": {
-            "type": "string"
-          },
-          "callNo": {
-            "type": "integer",
-            "format": "int32"
-          },
-          "status": {
-            "type": "integer",
-            "format": "int32"
-          },
-          "updatedAt": {
-            "type": "string",
-            "format": "datetime"
-          },
-          "createdAt": {
-            "type": "string",
-            "format": "datetime"
-          },
-          "progress": {
-            "type": "integer",
-            "format": "int32"
-          }
-        }
-      },
-      "RuleList": {
-        "type": "object",
-        "properties": {
-          "data": {
-            "type": "array",
-            "items": {
-              "$ref": "#/components/schemas/RuleListItem"
-            }
-          },
-          "total": {
-            "type": "integer",
-            "description": "列表的内容总数",
-            "format": "int32"
-          },
-          "success": {
-            "type": "boolean"
-          }
-        }
-      },
-      "FakeCaptcha": {
-        "type": "object",
-        "properties": {
-          "code": {
-            "type": "integer",
-            "format": "int32"
-          },
-          "status": {
-            "type": "string"
-          }
-        }
-      },
-      "LoginParams": {
-        "type": "object",
-        "properties": {
-          "username": {
-            "type": "string"
-          },
-          "password": {
-            "type": "string"
-          },
-          "autoLogin": {
-            "type": "boolean"
-          },
-          "type": {
-            "type": "string"
-          }
-        }
-      },
-      "ErrorResponse": {
-        "required": ["errorCode"],
-        "type": "object",
-        "properties": {
-          "errorCode": {
-            "type": "string",
-            "description": "业务约定的错误码"
-          },
-          "errorMessage": {
-            "type": "string",
-            "description": "业务上的错误信息"
-          },
-          "success": {
-            "type": "boolean",
-            "description": "业务上的请求是否成功"
-          }
-        }
-      },
-      "NoticeIconList": {
-        "type": "object",
-        "properties": {
-          "data": {
-            "type": "array",
-            "items": {
-              "$ref": "#/components/schemas/NoticeIconItem"
-            }
-          },
-          "total": {
-            "type": "integer",
-            "description": "列表的内容总数",
-            "format": "int32"
-          },
-          "success": {
-            "type": "boolean"
-          }
-        }
-      },
-      "NoticeIconItemType": {
-        "title": "NoticeIconItemType",
-        "description": "已读未读列表的枚举",
-        "type": "string",
-        "properties": {},
-        "enum": ["notification", "message", "event"]
-      },
-      "NoticeIconItem": {
-        "type": "object",
-        "properties": {
-          "id": {
-            "type": "string"
-          },
-          "extra": {
-            "type": "string",
-            "format": "any"
-          },
-          "key": { "type": "string" },
-          "read": {
-            "type": "boolean"
-          },
-          "avatar": {
-            "type": "string"
-          },
-          "title": {
-            "type": "string"
-          },
-          "status": {
-            "type": "string"
-          },
-          "datetime": {
-            "type": "string",
-            "format": "date"
-          },
-          "description": {
-            "type": "string"
-          },
-          "type": {
-            "extensions": {
-              "x-is-enum": true
-            },
-            "$ref": "#/components/schemas/NoticeIconItemType"
-          }
-        }
-      }
-    }
-  }
-}

+ 2 - 0
package.json

@@ -52,9 +52,11 @@
     "@umijs/route-utils": "^2.2.2",
     "ali-oss": "^6.20.0",
     "antd": "^5.13.2",
+    "antd-mobile-icons": "^0.3.0",
     "antd-style": "^3.6.1",
     "axios": "^1.7.2",
     "classnames": "^2.5.1",
+    "dayjs": "^1.11.11",
     "lodash": "^4.17.21",
     "moment": "^2.30.1",
     "omit.js": "^2.0.2",

Разница между файлами не показана из-за своего большого размера
+ 14003 - 11192
pnpm-lock.yaml


+ 0 - 3
src/pages/Content/HeadLines.tsx

@@ -28,9 +28,6 @@ const Edit: React.FC<{ bundle: EditBundle }> = (props) => {
       onCancel={() => {
         bundle.close();
       }}
-      onClose={() => {
-        bundle.close();
-      }}
       onOk={() => {}}
     >
       <ProForm

+ 21 - 10
src/pages/Settings/Menu.tsx

@@ -112,19 +112,27 @@ const Edit: React.FC<{ bundle: EditBundle;  onSuccess?: () => void }> = (props)
 
           return Promise.resolve({});
         }}
+
+        initialValues={{
+          type: 1 ,
+          status: 2,
+          target: 1,
+          hasRefresh: 0
+        } }
+
       >
 
-        <ProFormRadio.Group name='type' label='类型' value='2'
+        <ProFormRadio.Group name='type' label='类型'
                             options={[
-                              {label: '目录', value: '1',},
-                              {label: '菜单', value: '2'},
-                              {label: '按钮', value: '3'}]}></ProFormRadio.Group>
-        <ProFormRadio.Group name='status' label='状态' value='1'
-                            options={[{label: '正常', value: '1',}, {label: '隐藏', value: '2'}]}/>
-        <ProFormRadio.Group name='target' label='目标' value='1'
-                            options={[{label: '页签', value: '1',}, {label: '新窗口', value: '2'}]}/>
-        <ProFormRadio.Group name='hasRefresh' label='是否刷新' value='1'
-                            options={[{label: '不刷新', value: '0',}, {label: '刷新', value: '1'}]}/>
+                              {label: '目录', value: 1,},
+                              {label: '菜单', value: 2},
+                              {label: '按钮', value: 3}]}></ProFormRadio.Group>
+        <ProFormRadio.Group name='status' label='状态'
+                            options={[{label: '正常', value: 1,}, {label: '隐藏', value: 2}]}/>
+        <ProFormRadio.Group name='target' label='目标'
+                            options={[{label: '页签', value: 1,}, {label: '新窗口', value: 2}]}/>
+        <ProFormRadio.Group name='hasRefresh' label='是否刷新'
+                            options={[{label: '不刷新', value: 0,}, {label: '刷新', value: 1}]}/>
         <ProFormText name='name' label={'菜单名称'} placeholder={'请输入菜单名称'}
                      rules={[{required: true, message: '请输入菜单名称',}, {
                        min: 3,
@@ -246,6 +254,9 @@ const MenuExp: React.FC = () => {
               },
             ]}
 
+
+
+            pagination={false}
             actionRef={ref}
             toolbar={{
               actions: [

+ 63 - 43
src/pages/Settings/Staff.tsx

@@ -127,7 +127,12 @@ const Edit: React.FC<{ bundle: EditBundle; onSuccess?: () => void }> = (props) =
             console.log(bundle.id, 'bundle');
             const res = await Service.get(bundle.id);
 
-            return res.data;
+            return {
+              ...res.data,
+              roleIds: res.data.roles.map((rule) => {
+                return rule.id
+              })
+            }
           }
 
           return Promise.resolve({});
@@ -189,13 +194,10 @@ const Edit: React.FC<{ bundle: EditBundle; onSuccess?: () => void }> = (props) =
           label="角色"
           request={async () => {
             const res = await Service.listRole();
-            if (res.success) {
               return res.data.records.map(record => ({
                 label: record.name,
                 value: record.id,
               }))
-            }
-            return Promise.resolve({});
           }}
           placeholder="请选择角色"
           rules={[{required: true, message: '请选择角色'}]}
@@ -209,13 +211,18 @@ const Staff: React.FC = () => {
   const bundle = useEdit();
   const ref = useRef<ActionType>();
 
+
+
   return (
     <PageContainer content={''}>
       {bundle.open && <Edit bundle={bundle} onSuccess={() => ref.current?.reload()}></Edit>}
       <Card>
         <ProTable<Member>
           rowKey={'id'}
-          request={async (params) => {
+
+          request={async (params, ...rest) => {
+            console.log(params, ...rest)
+
             const res = await Service.list(params.current || 1, params.pageSize || 10);
 
             return {
@@ -224,43 +231,15 @@ const Staff: React.FC = () => {
               data: res.data.records,
             };
           }}
-          columns={[
-            {
-              title: 'ID',
-              dataIndex: 'id',
-            },
-            {
-              title: '账号',
-              dataIndex: 'username',
-            },
-            {
-              title: '姓名',
-              dataIndex: 'nickname',
-            },
-            {
-              title: '角色列表',
-              dataIndex: 'roles',
-              render: (roles: Role[]) => roles.map(role => role.name).join(', '),
-            },
-            {
-              title: '操作',
-              valueType: 'option',
-              render: (_, record) => [
-                <a key={'edit'} onClick={() => bundle.update(record.id as number)}>
-                  编辑
-                </a>,
-                <a
-                  key={'delete'}
-                  onClick={async () => {
-                    await Service.remove(record.id as number);
-                    ref.current?.reload();
-                  }}
-                >
-                  删除
-                </a>,
-              ],
-            },
-          ]}
+          columns={1}
+          search={{
+            labelWidth: 'auto',
+          }}
+          form={{
+            ignoreRules: false,
+          }}
+
+
           actionRef={ref}
           toolbar={{
             actions: [
@@ -270,7 +249,7 @@ const Staff: React.FC = () => {
             ],
             settings: [],
           }}
-          search={false}
+
         ></ProTable>
       </Card>
     </PageContainer>
@@ -278,3 +257,44 @@ const Staff: React.FC = () => {
 };
 
 export default Staff;
+
+const a = [
+  {
+    title: 'ID',
+    dataIndex: 'id',
+  },
+  {
+    title: '账号',
+    dataIndex: 'username',
+    filters: true,
+  },
+  {
+    title: '姓名',
+    dataIndex: 'nickname',
+    copyable: true,
+    ellipsis: true,
+  },
+  {
+    title: '角色列表',
+    dataIndex: 'roles',
+    render: (roles: Role[]) => roles.map(role => role.name).join(', '),
+  },
+  {
+    title: '操作',
+    valueType: 'option',
+    render: (_, record) => [
+      <a key={'edit'} onClick={() => bundle.update(record.id as number)}>
+        编辑
+      </a>,
+      <a
+        key={'delete'}
+        onClick={async () => {
+          await Service.remove(record.id as number);
+          ref.current?.reload();
+        }}
+      >
+        删除
+      </a>,
+    ],
+  },
+]

+ 0 - 94
src/services/ant-design-pro/api.ts

@@ -1,94 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-import { request } from '@umijs/max';
-
-/** 获取当前的用户 GET /api/currentUser */
-export async function currentUser(options?: { [key: string]: any }) {
-  return request<{
-    data: API.CurrentUser;
-  }>('/api/currentUser', {
-    method: 'GET',
-    ...(options || {}),
-  });
-}
-
-/** 退出登录接口 POST /api/login/outLogin */
-export async function outLogin(options?: { [key: string]: any }) {
-  return request<Record<string, any>>('/api/login/outLogin', {
-    method: 'POST',
-    ...(options || {}),
-  });
-}
-
-/** 登录接口 POST /api/login/account */
-export async function login(body: API.LoginParams, options?: { [key: string]: any }) {
-  return request<API.LoginResult>('/api/login/account', {
-    method: 'POST',
-    headers: {
-      'Content-Type': 'application/json',
-    },
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** 此处后端没有提供注释 GET /api/notices */
-export async function getNotices(options?: { [key: string]: any }) {
-  return request<API.NoticeIconList>('/api/notices', {
-    method: 'GET',
-    ...(options || {}),
-  });
-}
-
-/** 获取规则列表 GET /api/rule */
-export async function rule(
-  params: {
-    // query
-    /** 当前的页码 */
-    current?: number;
-    /** 页面的容量 */
-    pageSize?: number;
-  },
-  options?: { [key: string]: any },
-) {
-  return request<API.RuleList>('/api/rule', {
-    method: 'GET',
-    params: {
-      ...params,
-    },
-    ...(options || {}),
-  });
-}
-
-/** 更新规则 PUT /api/rule */
-export async function updateRule(options?: { [key: string]: any }) {
-  return request<API.RuleListItem>('/api/rule', {
-    method: 'POST',
-    data:{
-      method: 'update',
-      ...(options || {}),
-    }
-  });
-}
-
-/** 新建规则 POST /api/rule */
-export async function addRule(options?: { [key: string]: any }) {
-  return request<API.RuleListItem>('/api/rule', {
-    method: 'POST',
-    data:{
-      method: 'post',
-      ...(options || {}),
-    }
-  });
-}
-
-/** 删除规则 DELETE /api/rule */
-export async function removeRule(options?: { [key: string]: any }) {
-  return request<Record<string, any>>('/api/rule', {
-    method: 'POST',
-    data:{
-      method: 'delete',
-      ...(options || {}),
-    }
-  });
-}

+ 0 - 10
src/services/ant-design-pro/index.ts

@@ -1,10 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-// API 更新时间:
-// API 唯一标识:
-import * as api from './api';
-import * as login from './login';
-export default {
-  api,
-  login,
-};

+ 0 - 21
src/services/ant-design-pro/login.ts

@@ -1,21 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-import { request } from '@umijs/max';
-
-/** 发送验证码 POST /api/login/captcha */
-export async function getFakeCaptcha(
-  params: {
-    // query
-    /** 手机号 */
-    phone?: string;
-  },
-  options?: { [key: string]: any },
-) {
-  return request<API.FakeCaptcha>('/api/login/captcha', {
-    method: 'GET',
-    params: {
-      ...params,
-    },
-    ...(options || {}),
-  });
-}

+ 0 - 101
src/services/ant-design-pro/typings.d.ts

@@ -1,101 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-
-declare namespace API {
-  type CurrentUser = {
-    name?: string;
-    avatar?: string;
-    userid?: string;
-    email?: string;
-    signature?: string;
-    title?: string;
-    group?: string;
-    tags?: { key?: string; label?: string }[];
-    notifyCount?: number;
-    unreadCount?: number;
-    country?: string;
-    access?: string;
-    geographic?: {
-      province?: { label?: string; key?: string };
-      city?: { label?: string; key?: string };
-    };
-    address?: string;
-    phone?: string;
-  };
-
-  type LoginResult = {
-    status?: string;
-    type?: string;
-    currentAuthority?: string;
-  };
-
-  type PageParams = {
-    current?: number;
-    pageSize?: number;
-  };
-
-  type RuleListItem = {
-    key?: number;
-    disabled?: boolean;
-    href?: string;
-    avatar?: string;
-    name?: string;
-    owner?: string;
-    desc?: string;
-    callNo?: number;
-    status?: number;
-    updatedAt?: string;
-    createdAt?: string;
-    progress?: number;
-  };
-
-  type RuleList = {
-    data?: RuleListItem[];
-    /** 列表的内容总数 */
-    total?: number;
-    success?: boolean;
-  };
-
-  type FakeCaptcha = {
-    code?: number;
-    status?: string;
-  };
-
-  type LoginParams = {
-    username?: string;
-    password?: string;
-    autoLogin?: boolean;
-    type?: string;
-  };
-
-  type ErrorResponse = {
-    /** 业务约定的错误码 */
-    errorCode: string;
-    /** 业务上的错误信息 */
-    errorMessage?: string;
-    /** 业务上的请求是否成功 */
-    success?: boolean;
-  };
-
-  type NoticeIconList = {
-    data?: NoticeIconItem[];
-    /** 列表的内容总数 */
-    total?: number;
-    success?: boolean;
-  };
-
-  type NoticeIconItemType = 'notification' | 'message' | 'event';
-
-  type NoticeIconItem = {
-    id?: string;
-    extra?: string;
-    key?: string;
-    read?: boolean;
-    avatar?: string;
-    title?: string;
-    status?: string;
-    datetime?: string;
-    description?: string;
-    type?: NoticeIconItemType;
-  };
-}

+ 38 - 0
src/services/swagger/clientsAuth.ts

@@ -0,0 +1,38 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 获取 Ticket POST /apis/clients/auth/getTicket */
+export async function getTicket(
+  body: SectApi.AuthTicketQuery | SectApi.Mobile | SectApi.Qq | SectApi.WeiBo,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.AuthTicketVO>('/apis/clients/auth/getTicket', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 获取 Token POST /apis/clients/auth/getToken */
+export async function getToken(body: SectApi.AuthTokenQuery, options?: { [key: string]: any }) {
+  return request<SectApi.AuthTokenInfoVO>('/apis/clients/auth/getToken', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 登出 GET /apis/clients/auth/logout */
+export async function logout(options?: { [key: string]: any }) {
+  return request<boolean>('/apis/clients/auth/logout', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}

+ 16 - 6
src/services/swagger/index.ts

@@ -2,11 +2,21 @@
 /* eslint-disable */
 // API 更新时间:
 // API 唯一标识:
-import * as pet from './pet';
-import * as store from './store';
-import * as user from './user';
+import * as userConfigClients from './userConfigClients';
+import * as clientsAuth from './clientsAuth';
+import * as userAdmin from './userAdmin';
+import * as staffAdmin from './staffAdmin';
+import * as roleAdmin from './roleAdmin';
+import * as menuAdmin from './menuAdmin';
+import * as zidianpeizhiguanlihoutaiApi from './zidianpeizhiguanlihoutaiApi';
+import * as yonghuqiandaokehuduanApi from './yonghuqiandaokehuduanApi';
 export default {
-  pet,
-  store,
-  user,
+  userConfigClients,
+  clientsAuth,
+  userAdmin,
+  staffAdmin,
+  roleAdmin,
+  menuAdmin,
+  zidianpeizhiguanlihoutaiApi,
+  yonghuqiandaokehuduanApi,
 };

+ 57 - 0
src/services/swagger/menuAdmin.ts

@@ -0,0 +1,57 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 菜单详情 GET /apis/admin/menu/details */
+export async function details3(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.details3Params,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.MenuVO>('/apis/admin/menu/details', {
+    method: 'GET',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 删除菜单 DELETE /apis/admin/menu/remove */
+export async function remove3(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.remove3Params,
+  options?: { [key: string]: any },
+) {
+  return request<boolean>('/apis/admin/menu/remove', {
+    method: 'DELETE',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 保存菜单 POST /apis/admin/menu/save */
+export async function save2(body: SectApi.MenuSaveQuery, options?: { [key: string]: any }) {
+  return request<boolean>('/apis/admin/menu/save', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 查询菜单树 POST /apis/admin/menu/tree/list */
+export async function listTree(body: SectApi.MenuTreeQuery, options?: { [key: string]: any }) {
+  return request<SectApi.MenuVO[]>('/apis/admin/menu/tree/list', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}

+ 0 - 153
src/services/swagger/pet.ts

@@ -1,153 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-import { request } from '@umijs/max';
-
-/** Update an existing pet PUT /pet */
-export async function updatePet(body: API.Pet, options?: { [key: string]: any }) {
-  return request<any>('/pet', {
-    method: 'PUT',
-    headers: {
-      'Content-Type': 'application/json',
-    },
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Add a new pet to the store POST /pet */
-export async function addPet(body: API.Pet, options?: { [key: string]: any }) {
-  return request<any>('/pet', {
-    method: 'POST',
-    headers: {
-      'Content-Type': 'application/json',
-    },
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Find pet by ID Returns a single pet GET /pet/${param0} */
-export async function getPetById(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.getPetByIdParams,
-  options?: { [key: string]: any },
-) {
-  const { petId: param0, ...queryParams } = params;
-  return request<API.Pet>(`/pet/${param0}`, {
-    method: 'GET',
-    params: { ...queryParams },
-    ...(options || {}),
-  });
-}
-
-/** Updates a pet in the store with form data POST /pet/${param0} */
-export async function updatePetWithForm(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.updatePetWithFormParams,
-  body: { name?: string; status?: string },
-  options?: { [key: string]: any },
-) {
-  const { petId: param0, ...queryParams } = params;
-  const formData = new FormData();
-
-  Object.keys(body).forEach((ele) => {
-    const item = (body as any)[ele];
-
-    if (item !== undefined && item !== null) {
-      formData.append(
-        ele,
-        typeof item === 'object' && !(item instanceof File) ? JSON.stringify(item) : item,
-      );
-    }
-  });
-
-  return request<any>(`/pet/${param0}`, {
-    method: 'POST',
-    params: { ...queryParams },
-    data: formData,
-    ...(options || {}),
-  });
-}
-
-/** Deletes a pet DELETE /pet/${param0} */
-export async function deletePet(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.deletePetParams & {
-    // header
-    api_key?: string;
-  },
-  options?: { [key: string]: any },
-) {
-  const { petId: param0, ...queryParams } = params;
-  return request<any>(`/pet/${param0}`, {
-    method: 'DELETE',
-    headers: {},
-    params: { ...queryParams },
-    ...(options || {}),
-  });
-}
-
-/** uploads an image POST /pet/${param0}/uploadImage */
-export async function uploadFile(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.uploadFileParams,
-  body: { additionalMetadata?: string; file?: string },
-  file?: File,
-  options?: { [key: string]: any },
-) {
-  const { petId: param0, ...queryParams } = params;
-  const formData = new FormData();
-
-  if (file) {
-    formData.append('file', file);
-  }
-
-  Object.keys(body).forEach((ele) => {
-    const item = (body as any)[ele];
-
-    if (item !== undefined && item !== null) {
-      formData.append(
-        ele,
-        typeof item === 'object' && !(item instanceof File) ? JSON.stringify(item) : item,
-      );
-    }
-  });
-
-  return request<API.ApiResponse>(`/pet/${param0}/uploadImage`, {
-    method: 'POST',
-    params: { ...queryParams },
-    data: formData,
-    requestType: 'form',
-    ...(options || {}),
-  });
-}
-
-/** Finds Pets by status Multiple status values can be provided with comma separated strings GET /pet/findByStatus */
-export async function findPetsByStatus(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.findPetsByStatusParams,
-  options?: { [key: string]: any },
-) {
-  return request<API.Pet[]>('/pet/findByStatus', {
-    method: 'GET',
-    params: {
-      ...params,
-    },
-    ...(options || {}),
-  });
-}
-
-/** Finds Pets by tags Muliple tags can be provided with comma separated strings. Use         tag1, tag2, tag3 for testing. GET /pet/findByTags */
-export async function findPetsByTags(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.findPetsByTagsParams,
-  options?: { [key: string]: any },
-) {
-  return request<API.Pet[]>('/pet/findByTags', {
-    method: 'GET',
-    params: {
-      ...params,
-    },
-    ...(options || {}),
-  });
-}

+ 65 - 0
src/services/swagger/roleAdmin.ts

@@ -0,0 +1,65 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 角色详情 GET /apis/admin/role/details */
+export async function details2(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.details2Params,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.RoleVO>('/apis/admin/role/details', {
+    method: 'GET',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 此处后端没有提供注释 POST /apis/admin/role/list */
+export async function list(options?: { [key: string]: any }) {
+  return request<SectApi.RoleVO[]>('/apis/admin/role/list', {
+    method: 'POST',
+    ...(options || {}),
+  });
+}
+
+/** 分页查询角色 POST /apis/admin/role/page */
+export async function page2(body: SectApi.RolePageQuery, options?: { [key: string]: any }) {
+  return request<SectApi.IPageRoleVO>('/apis/admin/role/page', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 删除角色 DELETE /apis/admin/role/remove */
+export async function remove2(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.remove2Params,
+  options?: { [key: string]: any },
+) {
+  return request<boolean>('/apis/admin/role/remove', {
+    method: 'DELETE',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 保存角色 POST /apis/admin/role/save */
+export async function save1(body: SectApi.RoleSaveQuery, options?: { [key: string]: any }) {
+  return request<boolean>('/apis/admin/role/save', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}

+ 77 - 0
src/services/swagger/staffAdmin.ts

@@ -0,0 +1,77 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 管理员详情 GET /apis/admin/staff/details */
+export async function details1(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.details1Params,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.StaffVO>('/apis/admin/staff/details', {
+    method: 'GET',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 登录 POST /apis/admin/staff/login */
+export async function login(body: SectApi.StaffLoginQuery, options?: { [key: string]: any }) {
+  return request<string>('/apis/admin/staff/login', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 当前登录管理员信息 GET /apis/admin/staff/me */
+export async function me(options?: { [key: string]: any }) {
+  return request<SectApi.StaffVO>('/apis/admin/staff/me', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}
+
+/** 分页查询管理员 POST /apis/admin/staff/page */
+export async function page1(body: SectApi.StaffPageQuery, options?: { [key: string]: any }) {
+  return request<SectApi.IPageStaffVO>('/apis/admin/staff/page', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 删除管理员 DELETE /apis/admin/staff/remove */
+export async function remove1(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.remove1Params,
+  options?: { [key: string]: any },
+) {
+  return request<boolean>('/apis/admin/staff/remove', {
+    method: 'DELETE',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 保存管理员 POST /apis/admin/staff/save */
+export async function save(body: SectApi.StaffSaveQuery, options?: { [key: string]: any }) {
+  return request<boolean>('/apis/admin/staff/save', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}

+ 0 - 48
src/services/swagger/store.ts

@@ -1,48 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-import { request } from '@umijs/max';
-
-/** Returns pet inventories by status Returns a map of status codes to quantities GET /store/inventory */
-export async function getInventory(options?: { [key: string]: any }) {
-  return request<Record<string, any>>('/store/inventory', {
-    method: 'GET',
-    ...(options || {}),
-  });
-}
-
-/** Place an order for a pet POST /store/order */
-export async function placeOrder(body: API.Order, options?: { [key: string]: any }) {
-  return request<API.Order>('/store/order', {
-    method: 'POST',
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Find purchase order by ID For valid response try integer IDs with value >= 1 and <= 10.         Other values will generated exceptions GET /store/order/${param0} */
-export async function getOrderById(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.getOrderByIdParams,
-  options?: { [key: string]: any },
-) {
-  const { orderId: param0, ...queryParams } = params;
-  return request<API.Order>(`/store/order/${param0}`, {
-    method: 'GET',
-    params: { ...queryParams },
-    ...(options || {}),
-  });
-}
-
-/** Delete purchase order by ID For valid response try integer IDs with positive integer value.         Negative or non-integer values will generate API errors DELETE /store/order/${param0} */
-export async function deleteOrder(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.deleteOrderParams,
-  options?: { [key: string]: any },
-) {
-  const { orderId: param0, ...queryParams } = params;
-  return request<any>(`/store/order/${param0}`, {
-    method: 'DELETE',
-    params: { ...queryParams },
-    ...(options || {}),
-  });
-}

+ 345 - 67
src/services/swagger/typings.d.ts

@@ -1,112 +1,390 @@
-declare namespace API {
-  type ApiResponse = {
-    code?: number;
+declare namespace SectApi {
+  type AuthTicketQuery = {
+    /** 登录类型 */
+    loginType?: 'qq' | 'weiBo' | 'mobile' | 'weChat';
+    /** 客户端类型 */
+    clientType: 'app';
+  };
+
+  type AuthTicketVO = {
+    /** ticket,用于后续 Token 登录 */
+    ticket?: string;
+    /** 社交ID */
+    socialId?: string;
+    /** 社交类型 */
+    socialType?: string;
+    /** 名称 */
+    nickname?: string;
+    /** 头像-缩略图 */
+    avatarThumbnail?: string;
+    /** 头像-原图 */
+    avatarOriginal?: string;
+    /** 是否绑定手机号 */
+    hasBindMobile?: boolean;
+  };
+
+  type AuthTokenInfoVO = {
+    /** token */
+    token?: string;
+    /** 手机号 */
+    mobile?: string;
+    /** 名称 */
+    nickname?: string;
+    /** 头像-缩略图 */
+    avatarThumbnail?: string;
+    /** 头像-原图 */
+    avatarOriginal?: string;
+  };
+
+  type AuthTokenQuery = {
+    /** 登录类型 */
+    loginType: 'qq' | 'weiBo' | 'mobile' | 'weChat';
+    /** 客户端类型 */
+    clientType: 'app';
+    /** 通过 getTicket 获取的 ticket */
+    ticket?: string;
+  };
+
+  type Config = {
+    createTime?: string;
+    updateTime?: string;
+    id?: number;
     type?: string;
-    message?: string;
+    code?: string;
+    remark?: string;
+    content?: string;
+    permission?: number;
+  };
+
+  type ConfigPageQuery = {
+    cursor?: string;
+    direction?: string;
+    current?: number;
+    size?: number;
+    sorted?: string;
+    sortColumn?: string;
+    asc?: boolean;
+    desc?: boolean;
   };
 
-  type Category = {
+  type ConfigVO = {
+    /** 创建时间 */
+    createTime?: string;
+    /** 更新时间 */
+    updateTime?: string;
     id?: number;
-    name?: string;
+    type?: string;
+    code?: string;
+    remark?: string;
+    content?: string;
+    permission?: number;
   };
 
-  type deleteOrderParams = {
-    /** ID of the order that needs to be deleted */
-    orderId: number;
+  type details1Params = {
+    id: number;
   };
 
-  type deletePetParams = {
-    api_key?: string;
-    /** Pet id to delete */
-    petId: number;
+  type details2Params = {
+    id: number;
   };
 
-  type deleteUserParams = {
-    /** The name that needs to be deleted */
-    username: string;
+  type details3Params = {
+    id: number;
   };
 
-  type findPetsByStatusParams = {
-    /** Status values that need to be considered for filter */
-    status: ('available' | 'pending' | 'sold')[];
+  type detailsParams = {
+    id: number;
   };
 
-  type findPetsByTagsParams = {
-    /** Tags to filter by */
-    tags: string[];
+  type getByCodeParams = {
+    code: string;
   };
 
-  type getOrderByIdParams = {
-    /** ID of pet that needs to be fetched */
-    orderId: number;
+  type IPageConfigVO = {
+    size?: number;
+    records?: ConfigVO[];
+    current?: number;
+    pages?: number;
+    total?: number;
   };
 
-  type getPetByIdParams = {
-    /** ID of pet to return */
-    petId: number;
+  type IPageRoleVO = {
+    size?: number;
+    records?: RoleVO[];
+    current?: number;
+    pages?: number;
+    total?: number;
   };
 
-  type getUserByNameParams = {
-    /** The name that needs to be fetched. Use user1 for testing.  */
-    username: string;
+  type IPageStaffVO = {
+    size?: number;
+    records?: StaffVO[];
+    current?: number;
+    pages?: number;
+    total?: number;
   };
 
-  type loginUserParams = {
-    /** The user name for login */
-    username: string;
-    /** The password for login in clear text */
-    password: string;
+  type IPageUserVO = {
+    size?: number;
+    records?: UserVO[];
+    current?: number;
+    pages?: number;
+    total?: number;
+  };
+
+  type listByCodePrefix1Params = {
+    prefix: string;
+  };
+
+  type listByCodePrefixParams = {
+    prefix: string;
   };
 
-  type Order = {
+  type MenuSaveQuery = {
+    /** 菜单ID */
     id?: number;
-    petId?: number;
-    quantity?: number;
-    shipDate?: string;
-    /** Order Status */
-    status?: 'placed' | 'approved' | 'delivered';
-    complete?: boolean;
+    /** 1:目录 2:菜单 3:按钮) */
+    type?: 1 | 2 | 3;
+    /** 名称 */
+    name?: string;
+    /** 父菜单ID */
+    parentId?: number;
+    /** 显示顺序 */
+    sortNum?: number;
+    /** 请求地址 */
+    url?: string;
+    /** 1:页签 2:新窗口 */
+    target?: 1 | 2;
+    /** 菜单状态(1正常 2隐藏) */
+    status?: 1 | 2;
+    /** 是否刷新 0:不刷新 1:刷新 */
+    hasRefresh?: 0 | 1;
+    /** 权限标识 */
+    perms?: string;
+    /** 菜单图标 */
+    icon?: string;
+  };
+
+  type MenuTreeQuery = {
+    cursor?: string;
+    direction?: string;
+    current?: number;
+    size?: number;
+    sorted?: string;
+    sortColumn?: string;
+    /** 关键字 */
+    keyword?: string;
+    /** 状态(1正常 2隐藏) */
+    status?: 1 | 2;
+    asc?: boolean;
+    desc?: boolean;
+  };
+
+  type MenuVO = {
+    /** 创建时间 */
+    createTime?: string;
+    /** 更新时间 */
+    updateTime?: string;
+    /** 菜单ID */
+    id?: number;
+    /** 1:目录 2:菜单 3:按钮) */
+    type?: 1 | 2 | 3;
+    /** 名称 */
+    name?: string;
+    /** 父菜单ID */
+    parentId?: number;
+    /** 显示顺序 */
+    sortNum?: number;
+    /** 请求地址 */
+    url?: string;
+    /** 1:页签 2:新窗口 */
+    target?: 1 | 2;
+    /** 菜单状态(1正常 2隐藏) */
+    status?: 1 | 2;
+    /** 是否刷新 0:不刷新 1:刷新 */
+    hasRefresh?: 0 | 1;
+    /** 权限标识 */
+    perms?: string;
+    /** 菜单图标 */
+    icon?: string;
+    /** 子菜单列表 */
+    children?: MenuVO[];
   };
 
-  type Pet = {
+  type Mobile =
+    // #/components/schemas/AuthTicketQuery
+    AuthTicketQuery & {
+      /** 手机号 */
+      mobile?: string;
+      /** 验证码 */
+      code?: string;
+      /** 社交票据 */
+      socialTicket?: string;
+    };
+
+  type Qq =
+    // #/components/schemas/AuthTicketQuery
+    AuthTicketQuery & {
+      /** accessToken */
+      accessToken?: string;
+    };
+
+  type remove1Params = {
+    id: number;
+  };
+
+  type remove2Params = {
+    id: number;
+  };
+
+  type remove3Params = {
+    id: number;
+  };
+
+  type removeParams = {
+    id: number;
+  };
+
+  type RolePageQuery = {
+    cursor?: string;
+    direction?: string;
+    current?: number;
+    size?: number;
+    sorted?: string;
+    sortColumn?: string;
+    asc?: boolean;
+    desc?: boolean;
+  };
+
+  type RoleSaveQuery = {
+    /** 角色ID */
     id?: number;
-    category?: Category;
+    /** 角色名称 */
     name: string;
-    photoUrls: string[];
-    tags?: Tag[];
-    /** pet status in the store */
-    status?: 'available' | 'pending' | 'sold';
+    /** 显示顺序 */
+    sortNum?: number;
+    /** 角色状态(1:正常 2:停用) */
+    status: 1 | 2;
+    /** 菜单ID列表 */
+    menuIds: number[];
   };
 
-  type Tag = {
+  type RoleVO = {
+    /** 创建时间 */
+    createTime?: string;
+    /** 更新时间 */
+    updateTime?: string;
+    /** 角色ID */
     id?: number;
+    /** 角色名称 */
     name?: string;
+    /** 显示顺序 */
+    sortNum?: number;
+    /** 角色状态(1:正常 2:停用) */
+    status?: 1 | 2;
+  };
+
+  type StaffLoginQuery = {
+    /** 用户名 */
+    username: string;
+    /** 密码 */
+    password: string;
   };
 
-  type updatePetWithFormParams = {
-    /** ID of pet that needs to be updated */
-    petId: number;
+  type StaffPageQuery = {
+    cursor?: string;
+    direction?: string;
+    current?: number;
+    size?: number;
+    sorted?: string;
+    sortColumn?: string;
+    asc?: boolean;
+    desc?: boolean;
   };
 
-  type updateUserParams = {
-    /** name that need to be updated */
+  type StaffSaveQuery = {
+    /** 管理员ID */
+    id?: number;
+    /** 用户名 */
     username: string;
+    /** 密码 */
+    password: string;
+    /** 昵称 */
+    nickname?: string;
+    /** 头像缩略图 */
+    thumbAvatar?: string;
+    /** 级别 */
+    level: 0 | 1 | 2;
+    /** 角色 */
+    roleIds: number[];
   };
 
-  type uploadFileParams = {
-    /** ID of pet to update */
-    petId: number;
+  type StaffVO = {
+    /** 创建时间 */
+    createTime?: string;
+    /** 更新时间 */
+    updateTime?: string;
+    /** 管理员ID */
+    id?: number;
+    /** 用户名 */
+    username?: string;
+    /** 昵称 */
+    nickname?: string;
+    /** 头像缩略图 */
+    thumbAvatar?: string;
+    /** 级别 */
+    level?: 0 | 1 | 2;
+    /** 角色列表 */
+    roles?: RoleVO[];
+    /** 具备权限的菜单列表 */
+    menus?: MenuVO[];
   };
 
-  type User = {
+  type UserConfig = {
+    createTime?: string;
+    updateTime?: string;
     id?: number;
-    username?: string;
-    firstName?: string;
-    lastName?: string;
-    email?: string;
-    password?: string;
-    phone?: string;
-    /** User Status */
-    userStatus?: number;
+    userId?: number;
+    type?: string;
+    code?: string;
+    remark?: string;
+    content?: string;
+  };
+
+  type UserPageQuery = {
+    cursor?: string;
+    direction?: string;
+    current?: number;
+    size?: number;
+    sorted?: string;
+    sortColumn?: string;
+    asc?: boolean;
+    desc?: boolean;
   };
+
+  type UserVO = {
+    /** 创建时间 */
+    createTime?: string;
+    /** 更新时间 */
+    updateTime?: string;
+    /** 用户ID */
+    id?: number;
+    /** 手机号 */
+    mobile?: string;
+    /** 用户名 */
+    nickname?: string;
+    /** 头像-缩略图 */
+    avatarThumbnail?: string;
+    /** 头像-原图 */
+    avatarOriginal?: string;
+  };
+
+  type WeiBo =
+    // #/components/schemas/AuthTicketQuery
+    AuthTicketQuery & {
+      /** accessToken */
+      accessToken?: string;
+      /** refreshToken */
+      refreshToken?: string;
+    };
 }

+ 0 - 100
src/services/swagger/user.ts

@@ -1,100 +0,0 @@
-// @ts-ignore
-/* eslint-disable */
-import { request } from '@umijs/max';
-
-/** Create user This can only be done by the logged in user. POST /user */
-export async function createUser(body: API.User, options?: { [key: string]: any }) {
-  return request<any>('/user', {
-    method: 'POST',
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Get user by user name GET /user/${param0} */
-export async function getUserByName(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.getUserByNameParams,
-  options?: { [key: string]: any },
-) {
-  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(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.updateUserParams,
-  body: API.User,
-  options?: { [key: string]: any },
-) {
-  const { username: param0, ...queryParams } = params;
-  return request<any>(`/user/${param0}`, {
-    method: 'PUT',
-    params: { ...queryParams },
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Delete user This can only be done by the logged in user. DELETE /user/${param0} */
-export async function deleteUser(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.deleteUserParams,
-  options?: { [key: string]: any },
-) {
-  const { username: param0, ...queryParams } = params;
-  return request<any>(`/user/${param0}`, {
-    method: 'DELETE',
-    params: { ...queryParams },
-    ...(options || {}),
-  });
-}
-
-/** Creates list of users with given input array POST /user/createWithArray */
-export async function createUsersWithArrayInput(
-  body: API.User[],
-  options?: { [key: string]: any },
-) {
-  return request<any>('/user/createWithArray', {
-    method: 'POST',
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Creates list of users with given input array POST /user/createWithList */
-export async function createUsersWithListInput(body: API.User[], options?: { [key: string]: any }) {
-  return request<any>('/user/createWithList', {
-    method: 'POST',
-    data: body,
-    ...(options || {}),
-  });
-}
-
-/** Logs user into the system GET /user/login */
-export async function loginUser(
-  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
-  params: API.loginUserParams,
-  options?: { [key: string]: any },
-) {
-  return request<string>('/user/login', {
-    method: 'GET',
-    params: {
-      ...params,
-    },
-    ...(options || {}),
-  });
-}
-
-/** Logs out current logged in user session GET /user/logout */
-export async function logoutUser(options?: { [key: string]: any }) {
-  return request<any>('/user/logout', {
-    method: 'GET',
-    ...(options || {}),
-  });
-}

+ 45 - 0
src/services/swagger/userAdmin.ts

@@ -0,0 +1,45 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 用户详情 GET /apis/admin/user/details */
+export async function details(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.detailsParams,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.UserVO>('/apis/admin/user/details', {
+    method: 'GET',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 分页查询用户 POST /apis/admin/user/page */
+export async function page(body: SectApi.UserPageQuery, options?: { [key: string]: any }) {
+  return request<SectApi.IPageUserVO>('/apis/admin/user/page', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 删除用户 DELETE /apis/admin/user/remove */
+export async function remove(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.removeParams,
+  options?: { [key: string]: any },
+) {
+  return request<boolean>('/apis/admin/user/remove', {
+    method: 'DELETE',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}

+ 42 - 0
src/services/swagger/userConfigClients.ts

@@ -0,0 +1,42 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 根据配置编码查询用户配置 POST /apis/clients/user_config/list */
+export async function listByCode(body: string[], options?: { [key: string]: any }) {
+  return request<SectApi.ConfigVO[]>('/apis/clients/user_config/list', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 根据配置编码前缀查询用户配置 POST /apis/clients/user_config/list_prefix */
+export async function listByCodePrefix(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.listByCodePrefixParams,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.ConfigVO[]>('/apis/clients/user_config/list_prefix', {
+    method: 'POST',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 批量保存用户配置 POST /apis/clients/user_config/save_batch */
+export async function saveBatch(body: SectApi.UserConfig[], options?: { [key: string]: any }) {
+  return request<boolean>('/apis/clients/user_config/save_batch', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}

+ 27 - 0
src/services/swagger/yonghuqiandaokehuduanApi.ts

@@ -0,0 +1,27 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 获取用户签到次数 GET /apis/clients/user_sign/cnt */
+export async function cnt(options?: { [key: string]: any }) {
+  return request<number>('/apis/clients/user_sign/cnt', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}
+
+/** 获取用户签到列表 GET /apis/clients/user_sign/list */
+export async function list1(options?: { [key: string]: any }) {
+  return request<number[]>('/apis/clients/user_sign/list', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}
+
+/** 用户签到 GET /apis/clients/user_sign/sign */
+export async function sign(options?: { [key: string]: any }) {
+  return request<boolean>('/apis/clients/user_sign/sign', {
+    method: 'GET',
+    ...(options || {}),
+  });
+}

+ 81 - 0
src/services/swagger/zidianpeizhiguanlihoutaiApi.ts

@@ -0,0 +1,81 @@
+// @ts-ignore
+/* eslint-disable */
+import { invoke as request } from '@/core/network';
+
+/** 根据ID获取字典配置 GET /apis/admin/config/get */
+export async function getByCode(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.getByCodeParams,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.ConfigVO>('/apis/admin/config/get', {
+    method: 'GET',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 根据ID获取字典配置 POST /apis/admin/config/list */
+export async function listByCode1(body: string[], options?: { [key: string]: any }) {
+  return request<SectApi.ConfigVO[]>('/apis/admin/config/list', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 根据前缀获取字典配置 POST /apis/admin/config/list_prefix */
+export async function listByCodePrefix1(
+  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
+  params: SectApi.listByCodePrefix1Params,
+  options?: { [key: string]: any },
+) {
+  return request<SectApi.ConfigVO[]>('/apis/admin/config/list_prefix', {
+    method: 'POST',
+    params: {
+      ...params,
+    },
+    ...(options || {}),
+  });
+}
+
+/** 分页查询字典配置 POST /apis/admin/config/page */
+export async function page3(body: SectApi.ConfigPageQuery, options?: { [key: string]: any }) {
+  return request<SectApi.IPageConfigVO>('/apis/admin/config/page', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 保存字典配置 POST /apis/admin/config/save */
+export async function save3(body: SectApi.Config, options?: { [key: string]: any }) {
+  return request<boolean>('/apis/admin/config/save', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}
+
+/** 批量保存字典配置 POST /apis/admin/config/save_batch */
+export async function saveBatch1(body: SectApi.Config[], options?: { [key: string]: any }) {
+  return request<boolean>('/apis/admin/config/save_batch', {
+    method: 'POST',
+    headers: {
+      'Content-Type': 'application/json',
+    },
+    data: body,
+    ...(options || {}),
+  });
+}