diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 4eac27a84..d34be7cb4 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -7,7 +7,7 @@ on: - "**.csproj" env: - DOTNET_VERSION: "8.0.200" + DOTNET_VERSION: "9.0.101" jobs: build: diff --git a/.github/workflows/publish.yml b/.github/workflows/publish.yml index cb3855bc6..a3b942008 100644 --- a/.github/workflows/publish.yml +++ b/.github/workflows/publish.yml @@ -1,10 +1,10 @@ name: "Publish" on: - push: - branches: [ rel-8.3.0 ] + pull_request: + branches: [ main ] env: - DOTNET_VERSION: "8.0.200" + DOTNET_VERSION: "9.0.101" jobs: publish: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index a7794b528..5046b54bd 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -1,8 +1,8 @@ name: "Tagged Release" on: - push: - branches: [ rel-8.3.0 ] + pull_request: + branches: [ main ] jobs: tagged-release: @@ -14,4 +14,4 @@ jobs: with: repo_token: "${{ secrets.GITHUB_TOKEN }}" prerelease: false - automatic_release_tag: "8.3.0" + automatic_release_tag: "9.0.4" diff --git a/.gitignore b/.gitignore index 597037eca..8004fc9e8 100644 --- a/.gitignore +++ b/.gitignore @@ -40,5 +40,4 @@ yarn-error.log* *.suo *.ntvs* *.njsproj -*.sln *.sw* diff --git a/Directory.Packages.props b/Directory.Packages.props index 1bb7eb350..4558148f5 100644 --- a/Directory.Packages.props +++ b/Directory.Packages.props @@ -1,13 +1,13 @@ - 8.2.0 + 8.3.2 2.14.1 - 3.2.3 - 8.3.0 - 8.3.0 - 8.0.0 - 8.0.0 - 8.0.0 + 3.3.0-rc7 + 9.0.4 + 9.0.4 + 9.0.0.0 + 9.0.0.0 + 9.0.0.0 true @@ -20,6 +20,8 @@ + + @@ -52,6 +54,7 @@ + @@ -74,6 +77,7 @@ + @@ -133,6 +137,7 @@ + @@ -140,23 +145,29 @@ - + - + + + + - + + + + @@ -179,6 +190,21 @@ + + + + + + + + + + + + + + + @@ -186,33 +212,36 @@ + + + - - + + - - - + + + - + - - + + - - - + + + @@ -222,27 +251,28 @@ - + - - - - - + + + + + + - - + + - + - + - - + + @@ -251,16 +281,16 @@ - + - - - + + + - - - - + + + + diff --git a/README.en.md b/README.en.md index 74883c04b..fb79ea7d0 100644 --- a/README.en.md +++ b/README.en.md @@ -10,6 +10,19 @@ This is a [vue-vben-admin](https://github.com/anncwb/vue-vben-admin) -based Abp [![Build](https://github.com/colinin/abp-next-admin/actions/workflows/build.yml/badge.svg)](https://github.com/colinin/abp-next-admin/actions/workflows/build.yml) +## Deployment Options + +### Monolithic Service Deployment + +If you don't need a microservices architecture, you can choose the monolithic service deployment option. Monolithic services are characterized by simple deployment and easy maintenance. + +- [Monolithic Service Startup Guide](./docs/startup-aio-readme.en.md) +- [单体服务启动说明](./docs/startup-aio-readme.md) + +### Microservices Deployment + +If you need higher scalability and a more flexible service architecture, you can choose the microservices deployment option. + ## Quick Start ### 0、Configurate hosts diff --git a/README.md b/README.md index 9f0c91c39..dbcc172d0 100644 --- a/README.md +++ b/README.md @@ -1,4 +1,3 @@ - [English](./README.en.md) | 简体中文 [更新说明](./RELEASE.md) 更新说明 @@ -11,6 +10,18 @@ [![Build](https://github.com/colinin/abp-next-admin/actions/workflows/build.yml/badge.svg)](https://github.com/colinin/abp-next-admin/actions/workflows/build.yml) +## 部署方案 + +### 单体服务部署 + +如果您不需要微服务架构,可以选择单体服务部署方案。单体服务具有部署简单、维护方便的特点。 + +- [单体服务启动说明](./docs/startup-aio-readme.md) +- [Monolithic Service Startup Guide](./docs/startup-aio-readme.en.md) + +### 微服务部署 + +如果您需要更高的可扩展性和更灵活的服务架构,可以选择微服务部署方案。 ## 快速搭建微服务启动项目 diff --git a/apps/react-admin/.dockerignore b/apps/react-admin/.dockerignore new file mode 100644 index 000000000..1046b8e45 --- /dev/null +++ b/apps/react-admin/.dockerignore @@ -0,0 +1,4 @@ +.github +.vscode/ +dist/ +node_modules/ diff --git a/apps/react-admin/.env b/apps/react-admin/.env new file mode 100644 index 000000000..19c1d9f4b --- /dev/null +++ b/apps/react-admin/.env @@ -0,0 +1 @@ +VITE_GLOB_APP_TITLE = Vite React TS Template diff --git a/apps/react-admin/.env.development b/apps/react-admin/.env.development new file mode 100644 index 000000000..8a1166a28 --- /dev/null +++ b/apps/react-admin/.env.development @@ -0,0 +1,12 @@ +VITE_APP_BASE_API= +VITE_APP_HOMEPAGE=/dashboard/workbench +VITE_APP_BASE_PATH=/ +# VITE_GLOB_CLIENT_ID=react-admin-client +# VITE_GLOB_CLIENT_SECRET='' +# VITE_GLOB_SCOPE="openid email address phone profile offline_access miwen-abp-application" +# VITE_PROXY_API=http://192.168.31.246:30001 + +VITE_GLOB_CLIENT_ID=vue-admin-client +VITE_GLOB_CLIENT_SECRET=1q2w3e* +VITE_GLOB_SCOPE="openid email address phone profile offline_access lingyun-abp-application" +VITE_PROXY_API=http://124.223.5.95:30001 \ No newline at end of file diff --git a/apps/react-admin/.env.production b/apps/react-admin/.env.production new file mode 100644 index 000000000..42140e5bc --- /dev/null +++ b/apps/react-admin/.env.production @@ -0,0 +1,3 @@ +VITE_APP_BASE_API=/api +VITE_APP_HOMEPAGE=/dashboard/workbench +VITE_APP_BASE_PATH=/ diff --git a/apps/react-admin/.gitignore b/apps/react-admin/.gitignore new file mode 100644 index 000000000..6df0aabe7 --- /dev/null +++ b/apps/react-admin/.gitignore @@ -0,0 +1,28 @@ +# Logs +logs +*.log +npm-debug.log* +yarn-debug.log* +yarn-error.log* +pnpm-debug.log* +lerna-debug.log* + +node_modules +dist +dist-ssr +*.local + +# Editor directories and files +.idea +.DS_Store +*.suo +*.ntvs* +*.njsproj +*.sln +*.sw? + +# vite 打包分析产物 +stats.html + +# 取消上层忽略 +!.vscode/ \ No newline at end of file diff --git a/apps/react-admin/.vscode/extensions.json b/apps/react-admin/.vscode/extensions.json new file mode 100644 index 000000000..bc8a17487 --- /dev/null +++ b/apps/react-admin/.vscode/extensions.json @@ -0,0 +1,7 @@ +{ + "recommendations": [ + "biomejs.biome", + "bradlc.vscode-tailwindcss", + "lokalise.i18n-ally" + ] +} diff --git a/apps/react-admin/.vscode/settings.json b/apps/react-admin/.vscode/settings.json new file mode 100644 index 000000000..b05ff2ed1 --- /dev/null +++ b/apps/react-admin/.vscode/settings.json @@ -0,0 +1,35 @@ +{ + "typescript.tsdk": "./node_modules/typescript/lib", + "editor.tabSize": 2, + "editor.formatOnSave": true, + "editor.codeActionsOnSave": { + "quickfix.biome": "explicit", + "source.organizeImports.biome": "explicit" + }, + "editor.quickSuggestions": { + "strings": "on" + }, + "tailwindCSS.experimental.classRegex": [ + ["cn\\(([^)]*)\\)", "[\"'`]([^\"'`]*).*?[\"'`]"] + ], + "npm.packageManager": "pnpm", + "i18n-ally.localesPaths": ["src/locales/lang"], + "i18n-ally.enabledParsers": ["json"], + "i18n-ally.pathMatcher": "{locale}/{namespaces}.{ext}", + "i18n-ally.keystyle": "flat", + "i18n-ally.sortKeys": true, + "i18n-ally.sourceLanguage": "en_US", + "i18n-ally.displayLanguage": "zh_CN", + "[javascript]": { + "editor.defaultFormatter": "biomejs.biome" + }, + "[typescript]": { + "editor.defaultFormatter": "biomejs.biome" + }, + "[typescriptreact]": { + "editor.defaultFormatter": "biomejs.biome" + }, + "[json]": { + "editor.defaultFormatter": "biomejs.biome" + } +} diff --git a/apps/react-admin/Dockerfile b/apps/react-admin/Dockerfile new file mode 100644 index 000000000..615a02da9 --- /dev/null +++ b/apps/react-admin/Dockerfile @@ -0,0 +1,24 @@ +# Stage 1: build stage +FROM node:22-alpine as build-stage +# make the 'app' folder the current working directory +WORKDIR /app +# config node options +ENV NODE_OPTIONS=--max_old_space_size=8192 +# config pnpm, install dependencies +COPY package.json pnpm-lock.yaml* ./ +RUN npm install pnpm@9.x -g && \ + pnpm install --frozen-lockfile +# copy project files and folders to the current working directory (i.e. 'app' folder) +COPY . ./ +# build the project +RUN pnpm build +RUN echo "build successful 🎉 🎉 🎉" + + +# Stage 2: production stage +FROM nginx:latest as production-stage +COPY --from=build-stage /app/dist /usr/share/nginx/html +EXPOSE 80 +CMD ["nginx", "-g", "daemon off;"] +RUN echo "deploy to nginx successful 🎉 🎉 🎉" + diff --git a/apps/react-admin/LICENSE b/apps/react-admin/LICENSE new file mode 100644 index 000000000..ceb73cc97 --- /dev/null +++ b/apps/react-admin/LICENSE @@ -0,0 +1,21 @@ +MIT License + +Copyright (c) 2023 d3george + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/apps/react-admin/README.md b/apps/react-admin/README.md new file mode 100644 index 000000000..56f71dadd --- /dev/null +++ b/apps/react-admin/README.md @@ -0,0 +1,132 @@ +
+
+
+ +

Slash Admin

+

+

+ Slash Admin is a modern admin dashboard template built with React 18, Vite, Ant Design, and TypeScript. It is designed to help developers quickly create powerful admin management systems. +

+
+
+ Preview + · + Discord + · + Document +
+
+ d3george%2Fslash-admin | Trendshift +
+ +**English** | [中文](./README.zh-CN.md) + +## Sponsor +
+ + +
+ +## Preview ++ https://admin.slashspaces.com/ + +|![login.png](https://d3george.github.io/github-static/slash-admin/login.jpeg)|![login_dark.png](https://d3george.github.io/github-static/slash-admin/login_dark.jpeg) +| ----------------------------------------------------------------- | ------------------------------------------------------------------- | +|![analysis.png](https://d3george.github.io/github-static/slash-admin/analysis.png)|![workbench.png](https://d3george.github.io/github-static/slash-admin/workbench.png) + +## Features + +- Built using React 18 hooks. +- Powered by Vite for rapid development and hot module replacement. +- Integrates Ant Design, providing a rich set of UI components and design patterns. +- Written in TypeScript, offering type safety and an improved development experience. +- Responsive design, adapting to various screen sizes and devices. +- Flexible routing configuration, supporting nested routes. +- Integrated access control based on user roles. +- Supports internationalization for easy language switching. +- Includes common admin features like user management, role management, and permission management. +- Customizable themes and styles to meet your branding needs. +- Mocking solution based on MSW and Faker.js. +- State management using Zustand. +- Data fetching using React-Query. + +## Quick Start + +### Get the Project Code + +```bash +git clone https://github.com/d3george/slash-admin.git +``` + +### Install Dependencies + +In the project's root directory, run the following command to install project dependencies: + +```bash +pnpm install +``` + +### Start the Development Server + +Run the following command to start the development server: + +```bash +pnpm dev +``` + +Visit [http://localhost:3001](http://localhost:3001) to view your application. + +### Build for Production + +Run the following command to build the production version: + +```bash +pnpm build +``` + +## Docker deployment + + +### Build image and Run container +#### build image +Enter the project root directory in the terminal and execute the following command to build the Docker image: +``` +docker build -t your-image-name . +``` +Make sure to replace `your-image-name` with your own image name + +#### run container +Run your application in the Docker container using the following command: +``` +docker run -p 3001:80 your-image-name +``` +This will run your application on port `80`(exposed in `Dockerfile`) of the container and map it to port `3001` on your host. + +Now you can access http://localhost:3001 to view the deployed applications. + +### use docker-compose.yaml +Enter the project root directory in the terminal and execute the following command to start Docker Compose: +``` +docker-compose up -d +``` +Docker Compose will build an image based on the configuration defined by 'docker-compose. yaml' and run the container in the background. + +After the container runs successfully, it can also be accessed through http://localhost:3001 To view the deployed applications. + + +## Git Contribution submission specification + +reference[.commitlint.config.js](./commitlint.config.js) + +- `feat` new features +- `fix` fix the +- `docs` documentation or comments +- `style` code format (changes that do not affect code execution) +- `refactor` refactor +- `perf` performance optimization +- `revert` revert commit +- `test` test related +- `chore` changes in the construction process or auxiliary tools +- `ci` modify CI configuration and scripts +- `types` type definition file changes +- `wip` in development diff --git a/apps/react-admin/README.zh-CN.md b/apps/react-admin/README.zh-CN.md new file mode 100644 index 000000000..5f9ff89c1 --- /dev/null +++ b/apps/react-admin/README.zh-CN.md @@ -0,0 +1,131 @@ +
+
+
+ +

Slash Admin

+

+

+ Slash Admin 是一款现代化的后台管理模板,基于 React 18、Vite、Ant Design 和 TypeScript 构建。它旨在帮助开发人员快速搭建功能强大的后台管理系统。 +

+
+
+ Preview + · + Discord + · + Document +
+
+ d3george%2Fslash-admin | Trendshift +
+ +**中文** | [English](./README.md) + +## 赞助 +
+ + +
+ + +## 预览 ++ https://admin.slashspaces.com/ + +|![login.png](https://d3george.github.io/github-static/slash-admin/login.jpeg)|![login_dark.png](https://d3george.github.io/github-static/slash-admin/login_dark.jpeg) +| ----------------------------------------------------------------- | ------------------------------------------------------------------- | +|![analysis.png](https://d3george.github.io/github-static/slash-admin/analysis.png)|![workbench.png](https://d3george.github.io/github-static/slash-admin/workbench.png) +## 特性 + +- 使用 React 18 hooks 进行构建。 +- 基于 Vite 进行快速开发和热模块替换。 +- 集成 Ant Design,提供丰富的 UI 组件和设计模式。 +- 使用 TypeScript 编写,提供类型安全性和更好的开发体验。 +- 响应式设计,适应各种屏幕尺寸和设备。 +- 灵活的路由配置,支持多级嵌套路由。 +- 集成权限管理,根据用户角色控制页面访问权限。 +- 集成国际化支持,轻松切换多语言。 +- 集成常见的后台管理功能,如用户管理、角色管理、权限管理等。 +- 可定制的主题和样式,以满足您的品牌需求。 +- 基于 MSW 和 Faker.js 的Mock方案 +- 使用 Zustand 进行状态管理 +- 使用 React-Query 进行数据获取 + +## 快速开始 + +### 获取项目代码 + +```bash +git clone https://github.com/d3george/slash-admin.git +``` + +### 安装依赖 + +在项目根目录下运行以下命令安装项目依赖: + +```bash +pnpm install +``` + +### 启动开发服务器 + +运行以下命令以启动开发服务器: + +```bash +pnpm dev +``` + +访问 [http://localhost:3001](http://localhost:3001) 查看您的应用程序。 + +### 构建生产版本 + +运行以下命令以构建生产版本: + +```bash +pnpm build +``` + +构建后的文件将位于 `dist` 目录中。 + +## 容器化部署 + +### 构建镜像并运行容器 +#### 构建镜像 +在终端中进入项目根目录,并执行以下命令来构建 Docker 镜像: +``` +docker build -t your-image-name . +``` +确保将 `your-image-name` 替换为你自己的镜像名称 + +#### 运行容器 +使用以下命令在 Docker 容器中运行你的应用: +``` +docker run -p 3001:80 your-image-name +``` +这将在容器的端口 `80` (暴露在`Dockerfile`中) 上运行你的应用,并将其映射到你主机的端口 `3001` 上。 + +现在,你可以通过访问 http://localhost:3001 来查看部署的应用。 + + +### 使用docker-compose.yaml +在终端中进入项目根目录,并执行以下命令来启动 Docker Compose: +``` +docker-compose up -d +``` +Docker Compose 根据`docker-compose.yaml`定义的配置构建镜像并在后台运行容器. + +容器运行成功后,同样可以通过访问 http://localhost:3001来查看部署的应用。 + +参考[.commitlint.config.js](./commitlint.config.js) + +- `feat` 新功能 +- `fix` 修复bug +- `docs` 文档注释 +- `style` 代码格式(不影响代码运行的变动) +- `refactor` 重构 +- `perf` 性能优化 +- `revert` 回滚commit +- `test` 测试相关 +- `chore` 构建过程或辅助工具的变动 +- `ci` 修改CI配置、脚本 +- `types` 类型定义文件修改 +- `wip` 开发中 diff --git a/apps/react-admin/biome.json b/apps/react-admin/biome.json new file mode 100644 index 000000000..47ef3986f --- /dev/null +++ b/apps/react-admin/biome.json @@ -0,0 +1,44 @@ +{ + "$schema": "https://biomejs.dev/schemas/1.9.4/schema.json", + "vcs": { + "enabled": true, + "clientKind": "git", + "useIgnoreFile": true, + "defaultBranch": "main" + }, + "files": { + "ignoreUnknown": false, + "ignore": ["public", ".vscode", "src/api/gen"] + }, + "formatter": { + "enabled": true, + "lineWidth": 120, + "indentStyle": "tab" + }, + "organizeImports": { + "enabled": true + }, + "linter": { + "enabled": true, + "rules": { + "recommended": true, + "suspicious": { + "noExplicitAny": "off" + }, + "a11y": { + "useKeyWithClickEvents": "off" + }, + "complexity": { + "noForEach": "off" + }, + "correctness": { + "useExhaustiveDependencies": "off" + } + } + }, + "javascript": { + "formatter": { + "quoteStyle": "double" + } + } +} diff --git a/apps/react-admin/docker-compose.yaml b/apps/react-admin/docker-compose.yaml new file mode 100644 index 000000000..c34a48a4f --- /dev/null +++ b/apps/react-admin/docker-compose.yaml @@ -0,0 +1,7 @@ +services: + slash: + build: + context: . + ports: + - "3001:80" + restart: always diff --git a/apps/react-admin/index.html b/apps/react-admin/index.html new file mode 100644 index 000000000..aca743b1f --- /dev/null +++ b/apps/react-admin/index.html @@ -0,0 +1,13 @@ + + + + + + Slash Admin + + + +
+ + + diff --git a/apps/react-admin/lefthook.yml b/apps/react-admin/lefthook.yml new file mode 100644 index 000000000..2a7a0f6e1 --- /dev/null +++ b/apps/react-admin/lefthook.yml @@ -0,0 +1,26 @@ +# SKIP CI in commit message to skip hooks +skip_output: + - meta + - success + - summary + +pre-commit: + parallel: true + commands: + format: + glob: "*.{js,jsx,ts,tsx,json,md}" + run: npx @biomejs/biome format --write --no-errors-on-unmatched {staged_files} + stage_fixed: true + lint: + glob: "*.{js,jsx,ts,tsx}" + run: npx @biomejs/biome lint --no-errors-on-unmatched {staged_files} + check-types: + glob: "*.{ts,tsx}" + run: npx tsc --noEmit + +commit-msg: + commands: + commitlint: + run: npx commitlint --edit {1} + # 允许空提交信息 + skip: merge|rebase diff --git a/apps/react-admin/openapi-ts.config.ts b/apps/react-admin/openapi-ts.config.ts new file mode 100644 index 000000000..13571810d --- /dev/null +++ b/apps/react-admin/openapi-ts.config.ts @@ -0,0 +1,18 @@ +import { defineConfig } from "@hey-api/openapi-ts"; +import { defaultPlugins } from "@hey-api/openapi-ts"; +export default defineConfig({ + client: "@hey-api/client-axios", + input: "http://192.168.31.246:30001/swagger/v1/swagger.json", + output: { + format: "biome", + lint: "biome", + path: "src/api/gen", + }, + plugins: [ + ...defaultPlugins, + { + enums: "typescript", + name: "@hey-api/typescript", + }, + ], +}); diff --git a/apps/react-admin/package.json b/apps/react-admin/package.json new file mode 100644 index 000000000..47f2243e5 --- /dev/null +++ b/apps/react-admin/package.json @@ -0,0 +1,117 @@ +{ + "name": "slash-admin", + "private": true, + "version": "0.0.0", + "type": "module", + "homepage": "https://github.com/d3george/slash-admin", + "scripts": { + "dev": "vite", + "build": "tsc && vite build", + "preview": "vite preview", + "preinstall": "lefthook install", + "gen-api": "openapi-ts" + }, + "dependencies": { + "@ant-design/cssinjs": "^1.17.2", + "@ant-design/icons": "^5.2.6", + "@ant-design/pro-table": "^3.18.3", + "@fullcalendar/common": "^5.11.5", + "@fullcalendar/core": "^6.1.9", + "@fullcalendar/daygrid": "^6.1.9", + "@fullcalendar/interaction": "^6.1.9", + "@fullcalendar/list": "^6.1.9", + "@fullcalendar/react": "^6.1.9", + "@fullcalendar/timegrid": "^6.1.9", + "@fullcalendar/timeline": "^6.1.9", + "@hey-api/client-axios": "^0.2.12", + "@iconify/react": "^4.1.1", + "@microsoft/signalr": "^8.0.7", + "@tanstack/react-query": "^5.50.1", + "@tanstack/react-query-devtools": "^5.50.1", + "@vanilla-extract/css": "^1.17.0", + "@vanilla-extract/vite-plugin": "^4.0.19", + "@vercel/analytics": "^1.2.2", + "@vitejs/plugin-react": "^4.1.0", + "antd": "^5.9.3", + "apexcharts": "^3.43.0", + "autosuggest-highlight": "^3.3.4", + "axios": "^1.5.1", + "classnames": "^2.3.2", + "clsx": "^2.1.1", + "color": "^4.2.3", + "dayjs": "^1.11.10", + "defu": "^6.1.4", + "framer-motion": "^10.16.4", + "highlight.js": "^11.9.0", + "i18next": "^23.5.1", + "i18next-browser-languagedetector": "^7.1.0", + "json-edit-react": "^1.19.2", + "nprogress": "^0.2.0", + "numeral": "^2.0.6", + "ramda": "^0.29.1", + "react": "18.2.0", + "react-apexcharts": "^1.4.1", + "react-beautiful-dnd": "^13.1.1", + "react-dom": "18.2.0", + "react-error-boundary": "^4.0.13", + "react-helmet-async": "^2.0.5", + "react-i18next": "^13.2.2", + "react-icons": "^4.11.0", + "react-markdown": "^8.0.7", + "react-organizational-chart": "^2.2.1", + "react-quill": "^2.0.0", + "react-router": "^7.0.2", + "react-use": "^17.4.0", + "rehype-highlight": "^6.0.0", + "rehype-raw": "^6.1.1", + "remark-gfm": "^3.0.1", + "reset-css": "^5.0.2", + "screenfull": "^6.0.2", + "simplebar-react": "^3.2.4", + "sonner": "^1.7.0", + "styled-components": "^6.0.9", + "tailwind-merge": "^2.5.4", + "zustand": "^4.4.3" + }, + "devDependencies": { + "@biomejs/biome": "1.9.4", + "@commitlint/cli": "^17.7.2", + "@commitlint/config-conventional": "^17.7.0", + "@faker-js/faker": "^8.1.0", + "@hey-api/openapi-ts": "^0.59.1", + "@types/autosuggest-highlight": "^3.2.0", + "@types/color": "^3.0.4", + "@types/nprogress": "^0.2.1", + "@types/numeral": "^2.0.3", + "@types/ramda": "^0.29.6", + "@types/react": "^18.2.28", + "@types/react-beautiful-dnd": "^13.1.6", + "@types/react-dom": "^18.2.13", + "@types/styled-components": "^5.1.28", + "autoprefixer": "^10.4.16", + "axios-mock-adapter": "^2.1.0", + "lefthook": "^1.8.2", + "msw": "^2.4.9", + "postcss": "^8.4.31", + "postcss-import": "^15.1.0", + "postcss-nesting": "^11.3.0", + "rollup-plugin-visualizer": "^5.9.2", + "tailwindcss": "^3.3.3", + "ts-node": "^10.9.1", + "typescript": "^5.2.2", + "vite": "^5.4.9", + "vite-plugin-svg-icons": "^2.0.1", + "vite-tsconfig-paths": "^5.0.1", + "vitest": "^2.1.8" + }, + "engines": { + "node": "20.*" + }, + "packageManager": "pnpm@9.1.0", + "msw": { + "workerDirectory": "public" + }, + "commitlint": { + "extends": ["@commitlint/config-conventional"] + } +} diff --git a/apps/react-admin/postcss.config.js b/apps/react-admin/postcss.config.js new file mode 100644 index 000000000..a5a8f1524 --- /dev/null +++ b/apps/react-admin/postcss.config.js @@ -0,0 +1,8 @@ +export default { + plugins: { + "postcss-import": {}, + "tailwindcss/nesting": "postcss-nesting", + tailwindcss: {}, + autoprefixer: {}, + }, +}; diff --git a/apps/react-admin/public/mockServiceWorker.js b/apps/react-admin/public/mockServiceWorker.js new file mode 100644 index 000000000..8241ef8cc --- /dev/null +++ b/apps/react-admin/public/mockServiceWorker.js @@ -0,0 +1,295 @@ +/* eslint-disable */ +/* tslint:disable */ + +/** + * Mock Service Worker. + * @see https://github.com/mswjs/msw + * - Please do NOT modify this file. + * - Please do NOT serve this file on production. + */ + +const PACKAGE_VERSION = '2.6.4' +const INTEGRITY_CHECKSUM = 'ca7800994cc8bfb5eb961e037c877074' +const IS_MOCKED_RESPONSE = Symbol('isMockedResponse') +const activeClientIds = new Set() + +self.addEventListener('install', function () { + self.skipWaiting() +}) + +self.addEventListener('activate', function (event) { + event.waitUntil(self.clients.claim()) +}) + +self.addEventListener('message', async function (event) { + const clientId = event.source.id + + if (!clientId || !self.clients) { + return + } + + const client = await self.clients.get(clientId) + + if (!client) { + return + } + + const allClients = await self.clients.matchAll({ + type: 'window', + }) + + switch (event.data) { + case 'KEEPALIVE_REQUEST': { + sendToClient(client, { + type: 'KEEPALIVE_RESPONSE', + }) + break + } + + case 'INTEGRITY_CHECK_REQUEST': { + sendToClient(client, { + type: 'INTEGRITY_CHECK_RESPONSE', + payload: { + packageVersion: PACKAGE_VERSION, + checksum: INTEGRITY_CHECKSUM, + }, + }) + break + } + + case 'MOCK_ACTIVATE': { + activeClientIds.add(clientId) + + sendToClient(client, { + type: 'MOCKING_ENABLED', + payload: { + client: { + id: client.id, + frameType: client.frameType, + }, + }, + }) + break + } + + case 'MOCK_DEACTIVATE': { + activeClientIds.delete(clientId) + break + } + + case 'CLIENT_CLOSED': { + activeClientIds.delete(clientId) + + const remainingClients = allClients.filter((client) => { + return client.id !== clientId + }) + + // Unregister itself when there are no more clients + if (remainingClients.length === 0) { + self.registration.unregister() + } + + break + } + } +}) + +self.addEventListener('fetch', function (event) { + const { request } = event + + // Bypass navigation requests. + if (request.mode === 'navigate') { + return + } + + // Opening the DevTools triggers the "only-if-cached" request + // that cannot be handled by the worker. Bypass such requests. + if (request.cache === 'only-if-cached' && request.mode !== 'same-origin') { + return + } + + // Bypass all requests when there are no active clients. + // Prevents the self-unregistered worked from handling requests + // after it's been deleted (still remains active until the next reload). + if (activeClientIds.size === 0) { + return + } + + // Generate unique request ID. + const requestId = crypto.randomUUID() + event.respondWith(handleRequest(event, requestId)) +}) + +async function handleRequest(event, requestId) { + const client = await resolveMainClient(event) + const response = await getResponse(event, client, requestId) + + // Send back the response clone for the "response:*" life-cycle events. + // Ensure MSW is active and ready to handle the message, otherwise + // this message will pend indefinitely. + if (client && activeClientIds.has(client.id)) { + ;(async function () { + const responseClone = response.clone() + + sendToClient( + client, + { + type: 'RESPONSE', + payload: { + requestId, + isMockedResponse: IS_MOCKED_RESPONSE in response, + type: responseClone.type, + status: responseClone.status, + statusText: responseClone.statusText, + body: responseClone.body, + headers: Object.fromEntries(responseClone.headers.entries()), + }, + }, + [responseClone.body], + ) + })() + } + + return response +} + +// Resolve the main client for the given event. +// Client that issues a request doesn't necessarily equal the client +// that registered the worker. It's with the latter the worker should +// communicate with during the response resolving phase. +async function resolveMainClient(event) { + const client = await self.clients.get(event.clientId) + + if (activeClientIds.has(event.clientId)) { + return client + } + + if (client?.frameType === 'top-level') { + return client + } + + const allClients = await self.clients.matchAll({ + type: 'window', + }) + + return allClients + .filter((client) => { + // Get only those clients that are currently visible. + return client.visibilityState === 'visible' + }) + .find((client) => { + // Find the client ID that's recorded in the + // set of clients that have registered the worker. + return activeClientIds.has(client.id) + }) +} + +async function getResponse(event, client, requestId) { + const { request } = event + + // Clone the request because it might've been already used + // (i.e. its body has been read and sent to the client). + const requestClone = request.clone() + + function passthrough() { + // Cast the request headers to a new Headers instance + // so the headers can be manipulated with. + const headers = new Headers(requestClone.headers) + + // Remove the "accept" header value that marked this request as passthrough. + // This prevents request alteration and also keeps it compliant with the + // user-defined CORS policies. + headers.delete('accept', 'msw/passthrough') + + return fetch(requestClone, { headers }) + } + + // Bypass mocking when the client is not active. + if (!client) { + return passthrough() + } + + // Bypass initial page load requests (i.e. static assets). + // The absence of the immediate/parent client in the map of the active clients + // means that MSW hasn't dispatched the "MOCK_ACTIVATE" event yet + // and is not ready to handle requests. + if (!activeClientIds.has(client.id)) { + return passthrough() + } + + // Notify the client that a request has been intercepted. + const requestBuffer = await request.arrayBuffer() + const clientMessage = await sendToClient( + client, + { + type: 'REQUEST', + payload: { + id: requestId, + url: request.url, + mode: request.mode, + method: request.method, + headers: Object.fromEntries(request.headers.entries()), + cache: request.cache, + credentials: request.credentials, + destination: request.destination, + integrity: request.integrity, + redirect: request.redirect, + referrer: request.referrer, + referrerPolicy: request.referrerPolicy, + body: requestBuffer, + keepalive: request.keepalive, + }, + }, + [requestBuffer], + ) + + switch (clientMessage.type) { + case 'MOCK_RESPONSE': { + return respondWithMock(clientMessage.data) + } + + case 'PASSTHROUGH': { + return passthrough() + } + } + + return passthrough() +} + +function sendToClient(client, message, transferrables = []) { + return new Promise((resolve, reject) => { + const channel = new MessageChannel() + + channel.port1.onmessage = (event) => { + if (event.data && event.data.error) { + return reject(event.data.error) + } + + resolve(event.data) + } + + client.postMessage( + message, + [channel.port2].concat(transferrables.filter(Boolean)), + ) + }) +} + +async function respondWithMock(response) { + // Setting response status code to 0 is a no-op. + // However, when responding with a "Response.error()", the produced Response + // instance will have status code set to 0. Since it's not possible to create + // a Response instance with status code 0, handle that use-case separately. + if (response.status === 0) { + return Response.error() + } + + const mockedResponse = new Response(response.body, response) + + Reflect.defineProperty(mockedResponse, IS_MOCKED_RESPONSE, { + value: true, + enumerable: true, + }) + + return mockedResponse +} diff --git a/apps/react-admin/src/App.tsx b/apps/react-admin/src/App.tsx new file mode 100644 index 000000000..fdf7414a3 --- /dev/null +++ b/apps/react-admin/src/App.tsx @@ -0,0 +1,44 @@ +import { Helmet } from "react-helmet-async"; + +import Logo from "@/assets/images/logo.png"; +import Router from "@/router/index"; + +import { MotionLazy } from "./components/animate/motion-lazy"; +import Toast from "./components/toast"; +import { AntdAdapter } from "./theme/adapter/antd.adapter"; +import { ThemeProvider } from "./theme/theme-provider"; +import { useEffect } from "react"; + +import { useSetLocale } from "./store/localeI18nStore"; +import { useTranslation } from "react-i18next"; +import { getStringItem } from "./utils/storage"; +import { LocalEnum, StorageEnum } from "#/enum"; +import { useSessions } from "./hooks/abp/use-sessions"; + +function App() { + const { i18n } = useTranslation(); + const setLocale = useSetLocale(); + const defaultLng = getStringItem(StorageEnum.I18N) || LocalEnum.en_US; + useSessions(); + useEffect(() => { + async function initializeI18n() { + await setLocale(defaultLng as LocalEnum, i18n); + } + initializeI18n(); //触发abp语言包加载 + }, [defaultLng, i18n, setLocale]); + return ( + + + + Slash Admin + + + + + + + + ); +} + +export default App; diff --git a/apps/react-admin/src/_mock/assets.js b/apps/react-admin/src/_mock/assets.js new file mode 100644 index 000000000..2c248bfd5 --- /dev/null +++ b/apps/react-admin/src/_mock/assets.js @@ -0,0 +1,610 @@ +import useUserStore from "@/store/userStore"; +import { faker } from "@faker-js/faker"; + +import { BasicStatus, PermissionType } from "#/enum"; +/** + * Organization data mock + */ +export const ORG_LIST = [ + { + id: "1", + name: "East China Branch", + status: "enable", + desc: faker.lorem.words(), + order: 1, + children: [ + { + id: "1-1", + name: "R&D Department", + status: "disable", + desc: "", + order: 1, + }, + { + id: "1-2", + name: "Marketing Department", + status: "enable", + desc: "", + order: 2, + }, + { + id: "1-3", + name: "Finance Department", + status: "enable", + desc: "", + order: 3, + }, + ], + }, + { + id: "2", + name: "South China Branch", + status: "enable", + desc: faker.lorem.words(), + order: 2, + children: [ + { + id: "2-1", + name: "R&D Department", + status: "disable", + desc: "", + order: 1, + }, + { + id: "2-2", + name: "Marketing Department", + status: "enable", + desc: "", + order: 2, + }, + { + id: "2-3", + name: "Finance Department", + status: "enable", + desc: "", + order: 3, + }, + ], + }, +]; + +/** + * User permission mock + */ +const DASHBOARD_PERMISSION = { + id: "9100714781927703", + parentId: "", + label: "sys.menu.dashboard", + name: "Dashboard", + icon: "ic-analysis", + type: PermissionType.CATALOGUE, + route: "dashboard", + order: 1, + children: [ + { + id: "8426999229400979", + parentId: "9100714781927703", + label: "sys.menu.workbench", + name: "Workbench", + type: PermissionType.MENU, + route: "workbench", + component: "/dashboard/workbench/index.tsx", + }, + { + id: "9710971640510357", + parentId: "9100714781927703", + label: "sys.menu.analysis", + name: "Analysis", + type: PermissionType.MENU, + route: "analysis", + component: "/dashboard/analysis/index.tsx", + }, + ], +}; +const MANAGEMENT_PERMISSION = { + id: "0901673425580518", + parentId: "", + label: "sys.menu.management", + name: "Management", + icon: "ic-management", + type: PermissionType.CATALOGUE, + route: "management", + order: 2, + children: [ + { + id: "2781684678535711", + parentId: "0901673425580518", + label: "sys.menu.user.index", + name: "User", + type: PermissionType.CATALOGUE, + route: "user", + children: [ + { + id: "4754063958766648", + parentId: "2781684678535711", + label: "sys.menu.user.profile", + name: "Profile", + type: PermissionType.MENU, + route: "profile", + component: "/management/user/profile/index.tsx", + }, + { + id: "2516598794787938", + parentId: "2781684678535711", + label: "sys.menu.user.account", + name: "Account", + type: PermissionType.MENU, + route: "account", + component: "/management/user/account/index.tsx", + }, + ], + }, + { + id: "0249937641030250", + parentId: "0901673425580518", + label: "sys.menu.system.index", + name: "System", + type: PermissionType.CATALOGUE, + route: "system", + children: [ + { + id: "1985890042972842", + parentId: "0249937641030250", + label: "sys.menu.system.organization", + name: "Organization", + type: PermissionType.MENU, + route: "organization", + component: "/management/system/organization/index.tsx", + }, + { + id: "4359580910369984", + parentId: "0249937641030250", + label: "sys.menu.system.permission", + name: "Permission", + type: PermissionType.MENU, + route: "permission", + component: "/management/system/permission/index.tsx", + }, + { + id: "1689241785490759", + parentId: "0249937641030250", + label: "sys.menu.system.role", + name: "Role", + type: PermissionType.MENU, + route: "role", + component: "/management/system/role/index.tsx", + }, + { + id: "0157880245365433", + parentId: "0249937641030250", + label: "sys.menu.system.user", + name: "User", + type: PermissionType.MENU, + route: "user", + component: "/management/system/user/index.tsx", + }, + { + id: "0157880245365434", + parentId: "0249937641030250", + label: "sys.menu.system.user_detail", + name: "User Detail", + type: PermissionType.MENU, + route: "user/:id", + component: "/management/system/user/detail.tsx", + hide: true, + }, + ], + }, + ], +}; +const COMPONENTS_PERMISSION = { + id: "2271615060673773", + parentId: "", + label: "sys.menu.components", + name: "Components", + icon: "solar:widget-5-bold-duotone", + type: PermissionType.CATALOGUE, + route: "components", + order: 3, + children: [ + { + id: "2478488238255411", + parentId: "2271615060673773", + label: "sys.menu.icon", + name: "Icon", + type: PermissionType.MENU, + route: "icon", + component: "/components/icon/index.tsx", + }, + { + id: "6755238352318767", + parentId: "2271615060673773", + label: "sys.menu.animate", + name: "Animate", + type: PermissionType.MENU, + route: "animate", + component: "/components/animate/index.tsx", + }, + { + id: "9992476513546805", + parentId: "2271615060673773", + label: "sys.menu.scroll", + name: "Scroll", + type: PermissionType.MENU, + route: "scroll", + component: "/components/scroll/index.tsx", + }, + { + id: "1755562695856395", + parentId: "2271615060673773", + label: "sys.menu.markdown", + name: "Markdown", + type: PermissionType.MENU, + route: "markdown", + component: "/components/markdown/index.tsx", + }, + { + id: "2122547769468069", + parentId: "2271615060673773", + label: "sys.menu.editor", + name: "Editor", + type: PermissionType.MENU, + route: "editor", + component: "/components/editor/index.tsx", + }, + { + id: "2501920741714350", + parentId: "2271615060673773", + label: "sys.menu.i18n", + name: "Multi Language", + type: PermissionType.MENU, + route: "i18n", + component: "/components/multi-language/index.tsx", + }, + { + id: "2013577074467956", + parentId: "2271615060673773", + label: "sys.menu.upload", + name: "upload", + type: PermissionType.MENU, + route: "Upload", + component: "/components/upload/index.tsx", + }, + { + id: "7749726274771764", + parentId: "2271615060673773", + label: "sys.menu.chart", + name: "Chart", + type: PermissionType.MENU, + route: "chart", + component: "/components/chart/index.tsx", + }, + { + id: "2013577074467957", + parentId: "2271615060673773", + label: "sys.menu.toast", + name: "Toast", + type: PermissionType.MENU, + route: "toast", + component: "/components/toast/index.tsx", + }, + ], +}; +const FUNCTIONS_PERMISSION = { + id: "8132044808088488", + parentId: "", + label: "sys.menu.functions", + name: "functions", + icon: "solar:plain-2-bold-duotone", + type: PermissionType.CATALOGUE, + route: "functions", + order: 4, + children: [ + { + id: "3667930780705750", + parentId: "8132044808088488", + label: "sys.menu.clipboard", + name: "Clipboard", + type: PermissionType.MENU, + route: "clipboard", + component: "/functions/clipboard/index.tsx", + }, + { + id: "3667930780705751", + parentId: "8132044808088488", + label: "sys.menu.token_expired", + name: "Token Expired", + type: PermissionType.MENU, + route: "token-expired", + component: "/functions/token-expired/index.tsx", + }, + ], +}; +const MENU_LEVEL_PERMISSION = { + id: "0194818428516575", + parentId: "", + label: "sys.menu.menulevel.index", + name: "Menu Level", + icon: "ic-menulevel", + type: PermissionType.CATALOGUE, + route: "menu-level", + order: 5, + children: [ + { + id: "0144431332471389", + parentId: "0194818428516575", + label: "sys.menu.menulevel.1a", + name: "Menu Level 1a", + type: PermissionType.MENU, + route: "menu-level-1a", + component: "/menu-level/menu-level-1a/index.tsx", + }, + { + id: "7572529636800586", + parentId: "0194818428516575", + label: "sys.menu.menulevel.1b.index", + name: "Menu Level 1b", + type: PermissionType.CATALOGUE, + route: "menu-level-1b", + children: [ + { + id: "3653745576583237", + parentId: "7572529636800586", + label: "sys.menu.menulevel.1b.2a", + name: "Menu Level 2a", + type: PermissionType.MENU, + route: "menu-level-2a", + component: "/menu-level/menu-level-1b/menu-level-2a/index.tsx", + }, + { + id: "4873136353891364", + parentId: "7572529636800586", + label: "sys.menu.menulevel.1b.2b.index", + name: "Menu Level 2b", + type: PermissionType.CATALOGUE, + route: "menu-level-2b", + children: [ + { + id: "4233029726998055", + parentId: "4873136353891364", + label: "sys.menu.menulevel.1b.2b.3a", + name: "Menu Level 3a", + type: PermissionType.MENU, + route: "menu-level-3a", + component: "/menu-level/menu-level-1b/menu-level-2b/menu-level-3a/index.tsx", + }, + { + id: "3298034742548454", + parentId: "4873136353891364", + label: "sys.menu.menulevel.1b.2b.3b", + name: "Menu Level 3b", + type: PermissionType.MENU, + route: "menu-level-3b", + component: "/menu-level/menu-level-1b/menu-level-2b/menu-level-3b/index.tsx", + }, + ], + }, + ], + }, + ], +}; +const ERRORS_PERMISSION = { + id: "9406067785553476", + parentId: "", + label: "sys.menu.error.index", + name: "Error", + icon: "bxs:error-alt", + type: PermissionType.CATALOGUE, + route: "error", + order: 6, + children: [ + { + id: "8557056851997154", + parentId: "9406067785553476", + label: "sys.menu.error.403", + name: "403", + type: PermissionType.MENU, + route: "403", + component: "/sys/error/Page403.tsx", + }, + { + id: "5095669208159005", + parentId: "9406067785553476", + label: "sys.menu.error.404", + name: "404", + type: PermissionType.MENU, + route: "404", + component: "/sys/error/Page404.tsx", + }, + { + id: "0225992135973772", + parentId: "9406067785553476", + label: "sys.menu.error.500", + name: "500", + type: PermissionType.MENU, + route: "500", + component: "/sys/error/Page500.tsx", + }, + ], +}; +const OTHERS_PERMISSION = [ + { + id: "3981225257359246", + parentId: "", + label: "sys.menu.calendar", + name: "Calendar", + icon: "solar:calendar-bold-duotone", + type: PermissionType.MENU, + route: "calendar", + component: "/sys/others/calendar/index.tsx", + }, + { + id: "3513985683886393", + parentId: "", + label: "sys.menu.kanban", + name: "kanban", + icon: "solar:clipboard-bold-duotone", + type: PermissionType.MENU, + route: "kanban", + component: "/sys/others/kanban/index.tsx", + }, + { + id: "5455837930804461", + parentId: "", + label: "sys.menu.disabled", + name: "Disabled", + icon: "ic_disabled", + type: PermissionType.MENU, + route: "disabled", + status: BasicStatus.DISABLE, + component: "/sys/others/calendar/index.tsx", + }, + { + id: "7728048658221587", + parentId: "", + label: "sys.menu.label", + name: "Label", + icon: "ic_label", + type: PermissionType.MENU, + route: "label", + newFeature: true, + component: "/sys/others/blank.tsx", + }, + { + id: "5733704222120995", + parentId: "", + label: "sys.menu.frame", + name: "Frame", + icon: "ic_external", + type: PermissionType.CATALOGUE, + route: "frame", + children: [ + { + id: "9884486809510480", + parentId: "5733704222120995", + label: "sys.menu.external_link", + name: "External Link", + type: PermissionType.MENU, + route: "external_link", + hideTab: true, + component: "/sys/others/iframe/external-link.tsx", + frameSrc: "https://ant.design/", + }, + { + id: "9299640886731819", + parentId: "5733704222120995", + label: "sys.menu.iframe", + name: "Iframe", + type: PermissionType.MENU, + route: "frame", + component: "/sys/others/iframe/index.tsx", + frameSrc: "https://ant.design/", + }, + ], + }, + { + id: "0941594969900756", + parentId: "", + label: "sys.menu.blank", + name: "Disabled", + icon: "ic_blank", + type: PermissionType.MENU, + route: "blank", + component: "/sys/others/blank.tsx", + }, +]; + +export const PERMISSION_LIST = [ + DASHBOARD_PERMISSION, + MANAGEMENT_PERMISSION, + COMPONENTS_PERMISSION, + FUNCTIONS_PERMISSION, + MENU_LEVEL_PERMISSION, + ERRORS_PERMISSION, + ...OTHERS_PERMISSION, +]; + +/** + * User role mock + */ +const ADMIN_ROLE = { + id: "4281707933534332", + name: "Admin", + label: "admin", + status: BasicStatus.ENABLE, + order: 1, + desc: "Super Admin", + permission: PERMISSION_LIST, +}; +const TEST_ROLE = { + id: "9931665660771476", + name: "Test", + label: "test", + status: BasicStatus.ENABLE, + order: 2, + desc: "test", + permission: [DASHBOARD_PERMISSION, COMPONENTS_PERMISSION, FUNCTIONS_PERMISSION], +}; +export const ROLE_LIST = [ADMIN_ROLE, TEST_ROLE]; + +/** + * User data mock + */ +export const DEFAULT_USER = { + id: "b34719e1-ce46-457e-9575-99505ecee828", + username: "admin", + email: faker.internet.email(), + avatar: faker.image.avatarGitHub(), + createdAt: faker.date.anytime(), + updatedAt: faker.date.recent(), + password: "1q2w3E*", + role: ADMIN_ROLE, + permissions: ADMIN_ROLE.permission, + desc: "", + homePath: "/", + token: "/", + realName: "", + userId: "", +}; +export const TEST_USER = { + id: "efaa20ea-4dc5-47ee-a200-8a899be29494", + username: "test", + password: "1q2w3E*", + email: faker.internet.email(), + avatar: faker.image.avatarGitHub(), + createdAt: faker.date.anytime(), + updatedAt: faker.date.recent(), + role: TEST_ROLE, + permissions: TEST_ROLE.permission, + desc: "", + homePath: "/", + token: "/", + realName: "", + userId: "", +}; +export const USER_LIST = [DEFAULT_USER, TEST_USER]; + +// * Hot update, updating user permissions, only effective in the development environment +if (import.meta.hot) { + import.meta.hot.accept((newModule) => { + if (!newModule) return; + + const { DEFAULT_USER, TEST_USER, PERMISSION_LIST } = newModule; + + const { + userInfo, + actions: { setUserInfo }, + } = useUserStore.getState(); + + if (!userInfo?.username) return; + + const newUserInfo = userInfo.username === DEFAULT_USER.username ? DEFAULT_USER : TEST_USER; + + setUserInfo(newUserInfo); + + console.log("[HMR] User permissions updated:", { + username: newUserInfo.username, + permissions: newUserInfo.permissions, + }); + }); +} diff --git a/apps/react-admin/src/_mock/handlers/_demo.js b/apps/react-admin/src/_mock/handlers/_demo.js new file mode 100644 index 000000000..b73a9c976 --- /dev/null +++ b/apps/react-admin/src/_mock/handlers/_demo.js @@ -0,0 +1,9 @@ +import { http, HttpResponse } from "msw"; + +import { DemoApi } from "@/api/services/demoService"; + +const mockTokenExpired = http.post(`/api${DemoApi.TOKEN_EXPIRED}`, () => { + return new HttpResponse(null, { status: 401 }); +}); + +export default [mockTokenExpired]; diff --git a/apps/react-admin/src/_mock/handlers/_org.js b/apps/react-admin/src/_mock/handlers/_org.js new file mode 100644 index 000000000..12892dc40 --- /dev/null +++ b/apps/react-admin/src/_mock/handlers/_org.js @@ -0,0 +1,14 @@ +import { http, HttpResponse } from "msw"; + +import { ORG_LIST } from "@/_mock/assets"; +import { OrgApi } from "@/api/services/orgService"; + +const orgList = http.get(`/api${OrgApi.Org}`, () => { + return HttpResponse.json({ + status: 0, + message: "", + data: ORG_LIST, + }); +}); + +export default [orgList]; diff --git a/apps/react-admin/src/_mock/handlers/_user.js b/apps/react-admin/src/_mock/handlers/_user.js new file mode 100644 index 000000000..8c764f9c7 --- /dev/null +++ b/apps/react-admin/src/_mock/handlers/_user.js @@ -0,0 +1,46 @@ +import { faker } from "@faker-js/faker"; +import { http, HttpResponse, delay } from "msw"; + +import { UserApi } from "@/api/services/userService"; + +import { USER_LIST } from "../assets"; + +const signIn = http.post(`/api${UserApi.SignIn}`, async ({ request }) => { + const { username, password } = await request.json(); + + const user = USER_LIST.find((item) => item.username === username); + + if (!user || user.password !== password) { + return HttpResponse.json({ + status: 10001, + message: "Incorrect username or password.", + }); + } + + return HttpResponse.json({ + status: 0, + message: "", + data: { + user, + accessToken: faker.string.uuid(), + refreshToken: faker.string.uuid(), + }, + }); +}); + +const userList = http.get("/api/user", async () => { + await delay(1000); + return HttpResponse.json( + Array.from({ length: 10 }).map(() => ({ + fullname: faker.person.fullName(), + email: faker.internet.email(), + avatar: faker.image.avatarGitHub(), + address: faker.location.streetAddress(), + })), + { + status: 200, + }, + ); +}); + +export default [signIn, userList]; diff --git a/apps/react-admin/src/_mock/index.js b/apps/react-admin/src/_mock/index.js new file mode 100644 index 000000000..c0961ce09 --- /dev/null +++ b/apps/react-admin/src/_mock/index.js @@ -0,0 +1,10 @@ +import { setupWorker } from "msw/browser"; + +import demoMockApi from "./handlers/_demo"; +import orgMockApi from "./handlers/_org"; +import userMockApi from "./handlers/_user"; + +const handlers = [...userMockApi, ...orgMockApi, ...demoMockApi]; +const worker = setupWorker(...handlers); + +export default worker; diff --git a/apps/react-admin/src/_mock/utils.js b/apps/react-admin/src/_mock/utils.js new file mode 100644 index 000000000..7b6b4d888 --- /dev/null +++ b/apps/react-admin/src/_mock/utils.js @@ -0,0 +1,9 @@ +import { faker } from "@faker-js/faker"; + +export const fakeAvatars = (count) => { + const result = []; + for (let index = 0; index < count; index += 1) { + result.push(faker.image.avatarGitHub()); + } + return result; +}; diff --git a/apps/react-admin/src/api/abp-core/abp.ts b/apps/react-admin/src/api/abp-core/abp.ts new file mode 100644 index 000000000..471ccc11d --- /dev/null +++ b/apps/react-admin/src/api/abp-core/abp.ts @@ -0,0 +1,26 @@ +import type { ApplicationConfigurationDto, ApplicationLocalizationDto } from "#/abp-core"; +import requestClient from "../request"; + +/** + * 获取应用程序配置信息 + */ +export function getConfigApi(options?: { + includeLocalizationResources?: boolean; +}): Promise { + return requestClient.get("/api/abp/application-configuration", { + params: options, + }); +} + +/** + * 获取应用程序语言 + * @returns 本地化配置 + */ +export function getLocalizationApi(options: { + cultureName: string; + onlyDynamics?: boolean; +}): Promise { + return requestClient.get("/api/abp/application-localization", { + params: options, + }); +} diff --git a/apps/react-admin/src/api/abp-core/index.ts b/apps/react-admin/src/api/abp-core/index.ts new file mode 100644 index 000000000..581df1d3a --- /dev/null +++ b/apps/react-admin/src/api/abp-core/index.ts @@ -0,0 +1,2 @@ +export * from "./abp"; +// export * from './menu'; diff --git a/apps/react-admin/src/api/abp-core/menu.ts b/apps/react-admin/src/api/abp-core/menu.ts new file mode 100644 index 000000000..b2fb90201 --- /dev/null +++ b/apps/react-admin/src/api/abp-core/menu.ts @@ -0,0 +1,9 @@ +// import type { RouteRecordStringComponent } from '@vben/types'; +// import requestClient from '../request'; + +/** + * 获取用户所有菜单 + */ +// export async function getAllMenusApi() { +// return requestClient.get('/menu/all'); +// } diff --git a/apps/react-admin/src/api/account/account.ts b/apps/react-admin/src/api/account/account.ts new file mode 100644 index 000000000..8710dd7f1 --- /dev/null +++ b/apps/react-admin/src/api/account/account.ts @@ -0,0 +1,28 @@ +import type { ListResultDto } from "#/abp-core"; +import type { + GetTwoFactorProvidersInput, + TwoFactorProvider, + SendEmailSigninCodeDto, + SendPhoneSigninCodeDto, +} from "#/account/account"; +import requestClient from "@/api/request"; + +/** + * Get available two-factor authentication providers + */ +export const getTwoFactorProvidersApi = (input: GetTwoFactorProvidersInput) => + requestClient.get>("/api/account/two-factor-providers", { + params: input, + }); + +/** + * Send sign-in verification email + */ +export const sendEmailSigninCodeApi = (input: SendEmailSigninCodeDto) => + requestClient.post("/api/account/email/send-signin-code", input); + +/** + * Send sign-in verification SMS + */ +export const sendPhoneSigninCodeApi = (input: SendPhoneSigninCodeDto) => + requestClient.post("/api/account/phone/send-signin-code", input); diff --git a/apps/react-admin/src/api/account/index.ts b/apps/react-admin/src/api/account/index.ts new file mode 100644 index 000000000..64a674984 --- /dev/null +++ b/apps/react-admin/src/api/account/index.ts @@ -0,0 +1,4 @@ +export * from "./token"; +export * from "./user"; +export * from "./my-session"; +export * from "./account"; diff --git a/apps/react-admin/src/api/account/my-session.ts b/apps/react-admin/src/api/account/my-session.ts new file mode 100644 index 000000000..03fddc84e --- /dev/null +++ b/apps/react-admin/src/api/account/my-session.ts @@ -0,0 +1,23 @@ +import type { IdentitySessionDto } from "#/management/identity/sessions"; +import type { PagedResultDto } from "#/abp-core"; +import requestClient from "@/api/request"; + +export interface GetMySessionsInput { + filter?: string; + maxResultCount?: number; + skipCount?: number; +} + +/** + * Get current user's sessions + */ +export const getSessionsApi = (input?: GetMySessionsInput) => + requestClient.get>("/api/account/my-profile/sessions", { + params: input, + }); + +/** + * Revoke a session + */ +export const revokeSessionApi = (sessionId: string) => + requestClient.delete(`/api/account/my-profile/sessions/${sessionId}/revoke`); diff --git a/apps/react-admin/src/api/account/profile.ts b/apps/react-admin/src/api/account/profile.ts new file mode 100644 index 000000000..221bb3761 --- /dev/null +++ b/apps/react-admin/src/api/account/profile.ts @@ -0,0 +1,68 @@ +import type { + ProfileDto, + UpdateProfileDto, + ChangePasswordInput, + TwoFactorEnabledDto, + AuthenticatorDto, + VerifyAuthenticatorCodeInput, + AuthenticatorRecoveryCodeDto, + SendEmailConfirmCodeDto, + ConfirmEmailInput, +} from "#/account/profile"; +import requestClient from "@/api/request"; + +/** + * Get profile information + */ +export const getApi = () => requestClient.get("/api/account/my-profile"); + +/** + * Update profile information + */ +export const updateApi = (input: UpdateProfileDto) => requestClient.put("/api/account/my-profile", input); + +/** + * Change password + */ +export const changePasswordApi = (input: ChangePasswordInput) => + requestClient.post("/api/account/my-profile/change-password", input); + +/** + * Get two-factor authentication status + */ +export const getTwoFactorEnabledApi = () => + requestClient.get("/api/account/my-profile/two-factor"); + +/** + * Set two-factor authentication status + */ +export const changeTwoFactorEnabledApi = (input: TwoFactorEnabledDto) => + requestClient.put("/api/account/my-profile/change-two-factor", input); + +/** + * Get authenticator configuration + */ +export const getAuthenticatorApi = () => requestClient.get("/api/account/my-profile/authenticator"); + +/** + * Verify authenticator code + */ +export const verifyAuthenticatorCodeApi = (input: VerifyAuthenticatorCodeInput) => + requestClient.post("/api/account/my-profile/verify-authenticator-code", input); + +/** + * Reset authenticator + */ +export const resetAuthenticatorApi = () => requestClient.post("/api/account/my-profile/reset-authenticator"); + +/** + * Send email confirmation link + */ +export const sendEmailConfirmLinkApi = (input: SendEmailConfirmCodeDto) => + requestClient.post("/api/account/my-profile/send-email-confirm-link", input); + +/** + * Confirm email + */ +export const confirmEmailApi = (input: ConfirmEmailInput) => + requestClient.put("/api/account/my-profile/confirm-email", input); diff --git a/apps/react-admin/src/api/account/token.ts b/apps/react-admin/src/api/account/token.ts new file mode 100644 index 000000000..7cc52222f --- /dev/null +++ b/apps/react-admin/src/api/account/token.ts @@ -0,0 +1,63 @@ +import type { OAuthTokenResult, PasswordTokenRequestModel, RefreshTokenRequestModel, TokenResult } from "#/account"; +import requestClient from "../request"; + +/** + * 用户登录 + * @param request 参数 + * @returns 用户token + */ +export async function loginApi(request: PasswordTokenRequestModel): Promise { + const clientId = import.meta.env.VITE_GLOB_CLIENT_ID; + const clientSecret = import.meta.env.VITE_GLOB_CLIENT_SECRET; + const scope = import.meta.env.VITE_GLOB_SCOPE; + const result = await requestClient.post( + "/connect/token", + { + client_id: clientId, + client_secret: clientSecret, + grant_type: "password", + password: request.password, + scope: scope, + username: request.username, + }, + { + headers: { + "Content-Type": "application/x-www-form-urlencoded", + }, + timeout: 30_000, + }, + ); + return { + accessToken: result.access_token, + expiresIn: result.expires_in, + refreshToken: result.refresh_token, + tokenType: result.token_type, + }; +} + +export async function refreshToken(request: RefreshTokenRequestModel): Promise { + const clientId = import.meta.env.VITE_GLOB_CLIENT_ID; + const clientSecret = import.meta.env.VITE_GLOB_CLIENT_SECRET; + const scope = import.meta.env.VITE_GLOB_SCOPE; + const result = await requestClient.post( + "/connect/token", + { + client_id: clientId, + client_secret: clientSecret, + grant_type: "refresh_token", + refresh_token: request.refreshToken, + scope: scope, + }, + { + headers: { + "Content-Type": "application/x-www-form-urlencoded", + }, + }, + ); + return { + accessToken: result.access_token, + expiresIn: result.expires_in, + refreshToken: result.refresh_token, + tokenType: result.token_type, + }; +} diff --git a/apps/react-admin/src/api/account/user.ts b/apps/react-admin/src/api/account/user.ts new file mode 100644 index 000000000..d72c325e2 --- /dev/null +++ b/apps/react-admin/src/api/account/user.ts @@ -0,0 +1,17 @@ +import type { OAuthUserInfo, UserInfo } from "#/account"; +import requestClient from "../request"; + +/** + * 获取用户信息 + */ +export async function getUserInfoApi(): Promise { + const result = await requestClient.get("/connect/userinfo"); + return { + ...result, + emailVerified: result.email_verified, + givenName: result.given_name, + phoneNumberVerified: result.phone_number_verified, + preferredUsername: result.preferred_username, + uniqueName: result.unique_name, + }; +} diff --git a/apps/react-admin/src/api/apiClient.ts b/apps/react-admin/src/api/apiClient.ts new file mode 100644 index 000000000..2d78e9d46 --- /dev/null +++ b/apps/react-admin/src/api/apiClient.ts @@ -0,0 +1,98 @@ +import axios, { type AxiosRequestConfig, type AxiosError, type AxiosResponse } from "axios"; + +import { t } from "@/locales/i18n"; +import userStore, { useUserToken } from "@/store/userStore"; + +import { toast } from "sonner"; +//TODO rm +// 创建 axios 实例 +const axiosInstance = axios.create({ + baseURL: import.meta.env.VITE_APP_BASE_API, + timeout: 50000, + headers: { "Content-Type": "application/json;charset=utf-8" }, +}); + +// 请求拦截 +axiosInstance.interceptors.request.use( + (config) => { + // 在请求被发送之前做些什么 + const { accessToken } = useUserToken(); + config.headers.Authorization = `${accessToken}`; + return config; + }, + (error) => { + // 请求错误时做些什么 + return Promise.reject(error); + }, +); + +// 响应拦截 +axiosInstance.interceptors.response.use( + (res: AxiosResponse) => { + const { data, status, headers } = res; + + if (headers._abpwrapresult === "true") { + const { code, result, message, details } = data; + const hasSuccess = data && Reflect.has(data, "code") && code === "0"; + if (hasSuccess) { + return result; + } + const content = details || message; + + throw new Error(content); + } + + if (status >= 200 && status < 400) { + return data; + } + + // 业务请求错误 + throw new Error(t("sys.api.apiRequestFailed")); + }, + (error: AxiosError) => { + const { response, message } = error || {}; + + const errMsg = response?.data?.message || message || t("sys.api.errorMessage"); + toast.error(errMsg, { + position: "top-center", + }); + + const status = response?.status; + if (status === 401) { + userStore.getState().actions.clearUserInfoAndToken(); + } + return Promise.reject(error); + }, +); + +class APIClient { + get(config: AxiosRequestConfig): Promise { + return this.request({ ...config, method: "GET" }); + } + + post(config: AxiosRequestConfig): Promise { + return this.request({ ...config, method: "POST" }); + } + + put(config: AxiosRequestConfig): Promise { + return this.request({ ...config, method: "PUT" }); + } + + delete(config: AxiosRequestConfig): Promise { + return this.request({ ...config, method: "DELETE" }); + } + + request(config: AxiosRequestConfig): Promise { + return new Promise((resolve, reject) => { + axiosInstance + .request>(config) + .then((res: AxiosResponse) => { + resolve(res as unknown as Promise); + }) + .catch((e: Error | AxiosError) => { + reject(e); + }); + }); + } +} +export default new APIClient(); diff --git a/apps/react-admin/src/api/gen/index.ts b/apps/react-admin/src/api/gen/index.ts new file mode 100644 index 000000000..eae885d0e --- /dev/null +++ b/apps/react-admin/src/api/gen/index.ts @@ -0,0 +1,3 @@ +// This file is auto-generated by @hey-api/openapi-ts +export * from "./sdk.gen"; +export * from "./types.gen"; diff --git a/apps/react-admin/src/api/gen/sdk.gen.ts b/apps/react-admin/src/api/gen/sdk.gen.ts new file mode 100644 index 000000000..17c8a751c --- /dev/null +++ b/apps/react-admin/src/api/gen/sdk.gen.ts @@ -0,0 +1,6212 @@ +// This file is auto-generated by @hey-api/openapi-ts + +import { createClient, createConfig, type OptionsLegacyParser, formDataBodySerializer } from "@hey-api/client-axios"; +import type { + AbpApiDefinitionGetData, + AbpApiDefinitionGetError, + AbpApiDefinitionGetResponse, + AbpApplicationConfigurationGetData, + AbpApplicationConfigurationGetError, + AbpApplicationConfigurationGetResponse, + AbpApplicationLocalizationGetData, + AbpApplicationLocalizationGetError, + AbpApplicationLocalizationGetResponse, + AbpTenantFindTenantByNameData, + AbpTenantFindTenantByNameError, + AbpTenantFindTenantByNameResponse, + AbpTenantFindTenantByIdData, + AbpTenantFindTenantByIdError, + AbpTenantFindTenantByIdResponse, + AccountRegisterData, + AccountRegisterError, + AccountRegisterResponse, + AccountResetPasswordData, + AccountResetPasswordError, + AccountResetPasswordResponse, + AccountSendPhoneSigninCodeData, + AccountSendPhoneSigninCodeError, + AccountSendPhoneSigninCodeResponse, + AccountSendEmailSigninCodeData, + AccountSendEmailSigninCodeError, + AccountSendEmailSigninCodeResponse, + AccountSendPhoneRegisterCodeData, + AccountSendPhoneRegisterCodeError, + AccountSendPhoneRegisterCodeResponse, + AccountSendPhoneResetPasswordCodeData, + AccountSendPhoneResetPasswordCodeError, + AccountSendPhoneResetPasswordCodeResponse, + AccountGetTwoFactorProvidersData, + AccountGetTwoFactorProvidersError, + AccountGetTwoFactorProvidersResponse, + AccountRegister1Data, + AccountRegister1Error, + AccountRegister1Response, + AccountSendPasswordResetCodeData, + AccountSendPasswordResetCodeError, + AccountSendPasswordResetCodeResponse, + AccountVerifyPasswordResetTokenData, + AccountVerifyPasswordResetTokenError, + AccountVerifyPasswordResetTokenResponse, + AccountResetPassword1Data, + AccountResetPassword1Error, + AccountResetPassword1Response, + AuditLogDeleteData, + AuditLogDeleteError, + AuditLogDeleteResponse, + AuditLogGetData, + AuditLogGetError, + AuditLogGetResponse, + AuditLogGetListData, + AuditLogGetListError, + AuditLogGetListResponse, + BackgroundJobActionAddActionData, + BackgroundJobActionAddActionError, + BackgroundJobActionAddActionResponse, + BackgroundJobActionGetActionsData, + BackgroundJobActionGetActionsError, + BackgroundJobActionGetActionsResponse, + BackgroundJobActionDeleteActionData, + BackgroundJobActionDeleteActionError, + BackgroundJobActionDeleteActionResponse, + BackgroundJobActionUpdateActionData, + BackgroundJobActionUpdateActionError, + BackgroundJobActionUpdateActionResponse, + BackgroundJobActionGetDefinitionsData, + BackgroundJobActionGetDefinitionsError, + BackgroundJobActionGetDefinitionsResponse, + BackgroundJobInfoCreateData, + BackgroundJobInfoCreateError, + BackgroundJobInfoCreateResponse, + BackgroundJobInfoGetListData, + BackgroundJobInfoGetListError, + BackgroundJobInfoGetListResponse, + BackgroundJobInfoDeleteData, + BackgroundJobInfoDeleteError, + BackgroundJobInfoDeleteResponse, + BackgroundJobInfoGetData, + BackgroundJobInfoGetError, + BackgroundJobInfoGetResponse, + BackgroundJobInfoUpdateData, + BackgroundJobInfoUpdateError, + BackgroundJobInfoUpdateResponse, + BackgroundJobInfoPauseData, + BackgroundJobInfoPauseError, + BackgroundJobInfoPauseResponse, + BackgroundJobInfoResumeData, + BackgroundJobInfoResumeError, + BackgroundJobInfoResumeResponse, + BackgroundJobInfoTriggerData, + BackgroundJobInfoTriggerError, + BackgroundJobInfoTriggerResponse, + BackgroundJobInfoStopData, + BackgroundJobInfoStopError, + BackgroundJobInfoStopResponse, + BackgroundJobInfoStartData, + BackgroundJobInfoStartError, + BackgroundJobInfoStartResponse, + BackgroundJobInfoBulkStopData, + BackgroundJobInfoBulkStopError, + BackgroundJobInfoBulkStopResponse, + BackgroundJobInfoBulkStartData, + BackgroundJobInfoBulkStartError, + BackgroundJobInfoBulkStartResponse, + BackgroundJobInfoBulkTriggerData, + BackgroundJobInfoBulkTriggerError, + BackgroundJobInfoBulkTriggerResponse, + BackgroundJobInfoBulkResumeData, + BackgroundJobInfoBulkResumeError, + BackgroundJobInfoBulkResumeResponse, + BackgroundJobInfoBulkPauseData, + BackgroundJobInfoBulkPauseError, + BackgroundJobInfoBulkPauseResponse, + BackgroundJobInfoBulkDeleteData, + BackgroundJobInfoBulkDeleteError, + BackgroundJobInfoBulkDeleteResponse, + BackgroundJobInfoGetDefinitionsData, + BackgroundJobInfoGetDefinitionsError, + BackgroundJobInfoGetDefinitionsResponse, + BackgroundJobInfoGetAvailableFieldsData, + BackgroundJobInfoGetAvailableFieldsError, + BackgroundJobInfoGetAvailableFieldsResponse, + BackgroundJobInfoSearchData, + BackgroundJobInfoSearchError, + BackgroundJobInfoSearchResponse, + BackgroundJobLogDeleteData, + BackgroundJobLogDeleteError, + BackgroundJobLogDeleteResponse, + BackgroundJobLogGetData, + BackgroundJobLogGetError, + BackgroundJobLogGetResponse, + BackgroundJobLogGetListData, + BackgroundJobLogGetListError, + BackgroundJobLogGetListResponse, + BackupHandleData, + BackupHandleError, + BackupHandleResponse, + BulkCancelHandleData, + BulkCancelHandleError, + BulkCancelHandleResponse, + BulkDeleteHandleData, + BulkDeleteHandleError, + BulkDeleteHandleResponse, + BulkRetryHandleData, + BulkRetryHandleError, + BulkRetryHandleResponse, + CacheGetKeysData, + CacheGetKeysError, + CacheGetKeysResponse, + CacheGetValueData, + CacheGetValueError, + CacheGetValueResponse, + CacheSetData, + CacheSetError, + CacheSetResponse, + CacheRefreshData, + CacheRefreshError, + CacheRefreshResponse, + CacheRemoveData, + CacheRemoveError, + CacheRemoveResponse, + CancelHandleData, + CancelHandleError, + CancelHandleResponse, + ChatGetMyGroupMessageData, + ChatGetMyGroupMessageError, + ChatGetMyGroupMessageResponse, + ChatGetMyChatMessageData, + ChatGetMyChatMessageError, + ChatGetMyChatMessageResponse, + ChatGetMyLastChatMessageData, + ChatGetMyLastChatMessageError, + ChatGetMyLastChatMessageResponse, + ChatSendMessageData, + ChatSendMessageError, + ChatSendMessageResponse, + ClaimChangeAvatarData, + ClaimChangeAvatarError, + ClaimChangeAvatarResponse, + ClaimTypeCreateData, + ClaimTypeCreateError, + ClaimTypeCreateResponse, + ClaimTypeGetListData, + ClaimTypeGetListError, + ClaimTypeGetListResponse, + ClaimTypeDeleteData, + ClaimTypeDeleteError, + ClaimTypeDeleteResponse, + ClaimTypeGetData, + ClaimTypeGetError, + ClaimTypeGetResponse, + ClaimTypeUpdateData, + ClaimTypeUpdateError, + ClaimTypeUpdateResponse, + ClaimTypeGetAllListData, + ClaimTypeGetAllListError, + ClaimTypeGetAllListResponse, + DataCreateData, + DataCreateError, + DataCreateResponse, + DataGetListData, + DataGetListError, + DataGetListResponse, + DataCreateItemData, + DataCreateItemError, + DataCreateItemResponse, + DataDeleteData, + DataDeleteError, + DataDeleteResponse, + DataGetData, + DataGetError, + DataGetResponse, + DataUpdateData, + DataUpdateError, + DataUpdateResponse, + DataDeleteItemData, + DataDeleteItemError, + DataDeleteItemResponse, + DataUpdateItemData, + DataUpdateItemError, + DataUpdateItemResponse, + DataGet1Data, + DataGet1Error, + DataGet1Response, + DataGetAllData, + DataGetAllError, + DataGetAllResponse, + DataMoveData, + DataMoveError, + DataMoveResponse, + DeleteHandleData, + DeleteHandleError, + DeleteHandleResponse, + GetHandleData, + GetHandleError, + GetHandleResponse, + DeleteHandle1Data, + DeleteHandle1Error, + DeleteHandle1Response, + GetHandle1Data, + GetHandle1Error, + GetHandle1Response, + DeleteByDefinitionHandleData, + DeleteByDefinitionHandleError, + DeleteByDefinitionHandleResponse, + DeleteByDefinitionAndVersionHandleData, + DeleteByDefinitionAndVersionHandleError, + DeleteByDefinitionAndVersionHandleResponse, + DispatchHandleData, + DispatchHandleError, + DispatchHandleResponse, + DispatchHandle1Data, + DispatchHandle1Error, + DispatchHandle1Response, + DispatchHandle2Data, + DispatchHandle2Error, + DispatchHandle2Response, + DispatchEndpointHandleData, + DispatchEndpointHandleError, + DispatchEndpointHandleResponse, + DispatchEndpointHandle1Data, + DispatchEndpointHandle1Error, + DispatchEndpointHandle1Response, + DynamicClaimsRefreshData, + DynamicClaimsRefreshError, + DynamicClaimsRefreshResponse, + EditionCreateData, + EditionCreateError, + EditionCreateResponse, + EditionGetListData, + EditionGetListError, + EditionGetListResponse, + EditionDeleteData, + EditionDeleteError, + EditionDeleteResponse, + EditionGetData, + EditionGetError, + EditionGetResponse, + EditionUpdateData, + EditionUpdateError, + EditionUpdateResponse, + EntityChangesGetData, + EntityChangesGetError, + EntityChangesGetResponse, + EntityChangesGetListData, + EntityChangesGetListError, + EntityChangesGetListResponse, + EntityChangesGetWithUsernameData, + EntityChangesGetWithUsernameError, + EntityChangesGetWithUsernameResponse, + EntityChangesGetWithUsername1Data, + EntityChangesGetWithUsername1Error, + EntityChangesGetWithUsername1Response, + EntityTypeInfoGetData, + EntityTypeInfoGetError, + EntityTypeInfoGetResponse, + EntityTypeInfoGetListData, + EntityTypeInfoGetListError, + EntityTypeInfoGetListResponse, + ExecuteHandleData, + ExecuteHandleError, + ExecuteHandleResponse, + ExecuteHandle1Data, + ExecuteHandle1Error, + ExecuteHandle1Response, + ExecuteHandle2Data, + ExecuteHandle2Error, + ExecuteHandle2Response, + ExportHandleData, + ExportHandleError, + ExportHandleResponse, + FeatureDefinitionCreateData, + FeatureDefinitionCreateError, + FeatureDefinitionCreateResponse, + FeatureDefinitionGetListData, + FeatureDefinitionGetListError, + FeatureDefinitionGetListResponse, + FeatureDefinitionDeleteData, + FeatureDefinitionDeleteError, + FeatureDefinitionDeleteResponse, + FeatureDefinitionGetData, + FeatureDefinitionGetError, + FeatureDefinitionGetResponse, + FeatureDefinitionUpdateData, + FeatureDefinitionUpdateError, + FeatureDefinitionUpdateResponse, + FeatureGroupDefinitionCreateData, + FeatureGroupDefinitionCreateError, + FeatureGroupDefinitionCreateResponse, + FeatureGroupDefinitionGetListData, + FeatureGroupDefinitionGetListError, + FeatureGroupDefinitionGetListResponse, + FeatureGroupDefinitionDeleteData, + FeatureGroupDefinitionDeleteError, + FeatureGroupDefinitionDeleteResponse, + FeatureGroupDefinitionGetData, + FeatureGroupDefinitionGetError, + FeatureGroupDefinitionGetResponse, + FeatureGroupDefinitionUpdateData, + FeatureGroupDefinitionUpdateError, + FeatureGroupDefinitionUpdateResponse, + FeaturesGetData, + FeaturesGetError, + FeaturesGetResponse, + FeaturesUpdateData, + FeaturesUpdateError, + FeaturesUpdateResponse, + FeaturesDeleteData, + FeaturesDeleteError, + FeaturesDeleteResponse, + FeedbackCreateData, + FeedbackCreateError, + FeedbackCreateResponse, + FeedbackGetListData, + FeedbackGetListError, + FeedbackGetListResponse, + FeedbackDeleteData, + FeedbackDeleteError, + FeedbackDeleteResponse, + FeedbackGetData, + FeedbackGetError, + FeedbackGetResponse, + FeedbackAttachmentGetData, + FeedbackAttachmentGetError, + FeedbackAttachmentGetResponse, + FeedbackAttachmentDeleteData, + FeedbackAttachmentDeleteError, + FeedbackAttachmentDeleteResponse, + FeedbackAttachmentUploadData, + FeedbackAttachmentUploadError, + FeedbackAttachmentUploadResponse, + GetHandle2Data, + GetHandle2Error, + GetHandle2Response, + GetHandle3Data, + GetHandle3Error, + GetHandle3Response, + GetHandle4Data, + GetHandle4Error, + GetHandle4Response, + GetHandle5Data, + GetHandle5Error, + GetHandle5Response, + GetHandle6Data, + GetHandle6Error, + GetHandle6Response, + GetHandle7Data, + GetHandle7Error, + GetHandle7Response, + GetByDefinitionAndVersionHandleData, + GetByDefinitionAndVersionHandleError, + GetByDefinitionAndVersionHandleResponse, + GetByVersionIdHandleData, + GetByVersionIdHandleError, + GetByVersionIdHandleResponse, + GroupGetData, + GroupGetError, + GroupGetResponse, + GroupSearchData, + GroupSearchError, + GroupSearchResponse, + HistoryHandleData, + HistoryHandleError, + HistoryHandleResponse, + IdentitySessionsGetSessionsData, + IdentitySessionsGetSessionsError, + IdentitySessionsGetSessionsResponse, + IdentitySessionsRevokeSessionData, + IdentitySessionsRevokeSessionError, + IdentitySessionsRevokeSessionResponse, + ImportHandleData, + ImportHandleError, + ImportHandleResponse, + LanguageGetByNameData, + LanguageGetByNameError, + LanguageGetByNameResponse, + LanguageDeleteData, + LanguageDeleteError, + LanguageDeleteResponse, + LanguageUpdateData, + LanguageUpdateError, + LanguageUpdateResponse, + LanguageCreateData, + LanguageCreateError, + LanguageCreateResponse, + LanguageGetListData, + LanguageGetListError, + LanguageGetListResponse, + LayoutCreateData, + LayoutCreateError, + LayoutCreateResponse, + LayoutGetListData, + LayoutGetListError, + LayoutGetListResponse, + LayoutDeleteData, + LayoutDeleteError, + LayoutDeleteResponse, + LayoutGetData, + LayoutGetError, + LayoutGetResponse, + LayoutUpdateData, + LayoutUpdateError, + LayoutUpdateResponse, + LayoutGetAllListData, + LayoutGetAllListError, + LayoutGetAllListResponse, + ListHandleData, + ListHandleError, + ListHandleResponse, + ListHandle1Data, + ListHandle1Error, + ListHandle1Response, + ListHandle2Data, + ListHandle2Error, + ListHandle2Response, + ListHandle3Data, + ListHandle3Error, + ListHandle3Response, + SaveHandleData, + SaveHandleError, + SaveHandleResponse, + ListHandle4Data, + ListHandle4Error, + ListHandle4Response, + ListHandle5Data, + ListHandle5Error, + ListHandle5Response, + ListHandle6Data, + ListHandle6Error, + ListHandle6Response, + ListHandle7Data, + ListHandle7Error, + ListHandle7Response, + PostHandleData, + PostHandleError, + PostHandleResponse, + UpdateHandleData, + UpdateHandleError, + UpdateHandleResponse, + ListAllHandleData, + ListAllHandleError, + ListAllHandleResponse, + ListByDefinitionVersionIdsHandleData, + ListByDefinitionVersionIdsHandleError, + ListByDefinitionVersionIdsHandleResponse, + ListByProviderHandleData, + ListByProviderHandleError, + ListByProviderHandleResponse, + LoggingGetData, + LoggingGetError, + LoggingGetResponse, + LoggingGetListData, + LoggingGetListError, + LoggingGetListResponse, + LoginLoginData, + LoginLoginError, + LoginLoginResponse, + LoginLogoutData, + LoginLogoutError, + LoginLogoutResponse, + LoginCheckPasswordData, + LoginCheckPasswordError, + LoginCheckPasswordResponse, + MenuGetCurrentUserMenuListData, + MenuGetCurrentUserMenuListError, + MenuGetCurrentUserMenuListResponse, + MenuGetData, + MenuGetError, + MenuGetResponse, + MenuUpdateData, + MenuUpdateError, + MenuUpdateResponse, + MenuDeleteData, + MenuDeleteError, + MenuDeleteResponse, + MenuGetAllData, + MenuGetAllError, + MenuGetAllResponse, + MenuGetListData, + MenuGetListError, + MenuGetListResponse, + MenuCreateData, + MenuCreateError, + MenuCreateResponse, + MenuSetUserMenusData, + MenuSetUserMenusError, + MenuSetUserMenusResponse, + MenuGetUserMenuListData, + MenuGetUserMenuListError, + MenuGetUserMenuListResponse, + MenuSetUserStartupData, + MenuSetUserStartupError, + MenuSetUserStartupResponse, + MenuGetUserMenuList1Data, + MenuGetUserMenuList1Error, + MenuGetUserMenuList1Response, + MenuSetRoleMenusData, + MenuSetRoleMenusError, + MenuSetRoleMenusResponse, + MenuGetRoleMenuListData, + MenuGetRoleMenuListError, + MenuGetRoleMenuListResponse, + MenuSetRoleStartupData, + MenuSetRoleStartupError, + MenuSetRoleStartupResponse, + MenuGetRoleMenuList1Data, + MenuGetRoleMenuList1Error, + MenuGetRoleMenuList1Response, + MyFeedbackGetMyFeedbacksData, + MyFeedbackGetMyFeedbacksError, + MyFeedbackGetMyFeedbacksResponse, + MyFriendCreateData, + MyFriendCreateError, + MyFriendCreateResponse, + MyFriendDeleteData, + MyFriendDeleteError, + MyFriendDeleteResponse, + MyFriendGetListData, + MyFriendGetListError, + MyFriendGetListResponse, + MyFriendAddRequestData, + MyFriendAddRequestError, + MyFriendAddRequestResponse, + MyFriendGetData, + MyFriendGetError, + MyFriendGetResponse, + MyFriendGetAllListData, + MyFriendGetAllListError, + MyFriendGetAllListResponse, + MyNotificationMarkReadStateData, + MyNotificationMarkReadStateError, + MyNotificationMarkReadStateResponse, + MyNotificationDeleteData, + MyNotificationDeleteError, + MyNotificationDeleteResponse, + MyNotificationGetData, + MyNotificationGetError, + MyNotificationGetResponse, + MyNotificationGetListData, + MyNotificationGetListError, + MyNotificationGetListResponse, + MySubscriptionGetAllListData, + MySubscriptionGetAllListError, + MySubscriptionGetAllListResponse, + MySubscriptionGetListData, + MySubscriptionGetListError, + MySubscriptionGetListResponse, + MySubscriptionSubscribeData, + MySubscriptionSubscribeError, + MySubscriptionSubscribeResponse, + MySubscriptionUnSubscribeData, + MySubscriptionUnSubscribeError, + MySubscriptionUnSubscribeResponse, + MySubscriptionIsSubscribedData, + MySubscriptionIsSubscribedError, + MySubscriptionIsSubscribedResponse, + NotificationSendData, + NotificationSendError, + NotificationSendResponse, + NotificationSend1Data, + NotificationSend1Error, + NotificationSend1Response, + NotificationGetAssignableNotifiersData, + NotificationGetAssignableNotifiersError, + NotificationGetAssignableNotifiersResponse, + NotificationGetAssignableTemplatesData, + NotificationGetAssignableTemplatesError, + NotificationGetAssignableTemplatesResponse, + NotificationDefinitionCreateData, + NotificationDefinitionCreateError, + NotificationDefinitionCreateResponse, + NotificationDefinitionGetListData, + NotificationDefinitionGetListError, + NotificationDefinitionGetListResponse, + NotificationDefinitionDeleteData, + NotificationDefinitionDeleteError, + NotificationDefinitionDeleteResponse, + NotificationDefinitionGetData, + NotificationDefinitionGetError, + NotificationDefinitionGetResponse, + NotificationDefinitionUpdateData, + NotificationDefinitionUpdateError, + NotificationDefinitionUpdateResponse, + NotificationGroupDefinitionCreateData, + NotificationGroupDefinitionCreateError, + NotificationGroupDefinitionCreateResponse, + NotificationGroupDefinitionGetListData, + NotificationGroupDefinitionGetListError, + NotificationGroupDefinitionGetListResponse, + NotificationGroupDefinitionDeleteData, + NotificationGroupDefinitionDeleteError, + NotificationGroupDefinitionDeleteResponse, + NotificationGroupDefinitionGetData, + NotificationGroupDefinitionGetError, + NotificationGroupDefinitionGetResponse, + NotificationGroupDefinitionUpdateData, + NotificationGroupDefinitionUpdateError, + NotificationGroupDefinitionUpdateResponse, + OpenIddictApplicationGetData, + OpenIddictApplicationGetError, + OpenIddictApplicationGetResponse, + OpenIddictApplicationUpdateData, + OpenIddictApplicationUpdateError, + OpenIddictApplicationUpdateResponse, + OpenIddictApplicationDeleteData, + OpenIddictApplicationDeleteError, + OpenIddictApplicationDeleteResponse, + OpenIddictApplicationGetListData, + OpenIddictApplicationGetListError, + OpenIddictApplicationGetListResponse, + OpenIddictApplicationCreateData, + OpenIddictApplicationCreateError, + OpenIddictApplicationCreateResponse, + OpenIddictAuthorizationDeleteData, + OpenIddictAuthorizationDeleteError, + OpenIddictAuthorizationDeleteResponse, + OpenIddictAuthorizationGetData, + OpenIddictAuthorizationGetError, + OpenIddictAuthorizationGetResponse, + OpenIddictAuthorizationGetListData, + OpenIddictAuthorizationGetListError, + OpenIddictAuthorizationGetListResponse, + OpenIddictScopeCreateData, + OpenIddictScopeCreateError, + OpenIddictScopeCreateResponse, + OpenIddictScopeGetListData, + OpenIddictScopeGetListError, + OpenIddictScopeGetListResponse, + OpenIddictScopeDeleteData, + OpenIddictScopeDeleteError, + OpenIddictScopeDeleteResponse, + OpenIddictScopeGetData, + OpenIddictScopeGetError, + OpenIddictScopeGetResponse, + OpenIddictScopeUpdateData, + OpenIddictScopeUpdateError, + OpenIddictScopeUpdateResponse, + OpenIddictTokenDeleteData, + OpenIddictTokenDeleteError, + OpenIddictTokenDeleteResponse, + OpenIddictTokenGetData, + OpenIddictTokenGetError, + OpenIddictTokenGetResponse, + OpenIddictTokenGetListData, + OpenIddictTokenGetListError, + OpenIddictTokenGetListResponse, + OrganizationUnitsCreateData, + OrganizationUnitsCreateError, + OrganizationUnitsCreateResponse, + OrganizationUnitsGetListData, + OrganizationUnitsGetListError, + OrganizationUnitsGetListResponse, + OrganizationUnitsDeleteData, + OrganizationUnitsDeleteError, + OrganizationUnitsDeleteResponse, + OrganizationUnitsGetData, + OrganizationUnitsGetError, + OrganizationUnitsGetResponse, + OrganizationUnitsUpdateData, + OrganizationUnitsUpdateError, + OrganizationUnitsUpdateResponse, + OrganizationUnitsFindChildrenData, + OrganizationUnitsFindChildrenError, + OrganizationUnitsFindChildrenResponse, + OrganizationUnitsGetRootData, + OrganizationUnitsGetRootError, + OrganizationUnitsGetRootResponse, + OrganizationUnitsGetLastChildOrNullData, + OrganizationUnitsGetLastChildOrNullError, + OrganizationUnitsGetLastChildOrNullResponse, + OrganizationUnitsGetAllListData, + OrganizationUnitsGetAllListError, + OrganizationUnitsGetAllListResponse, + OrganizationUnitsGetRoleNamesData, + OrganizationUnitsGetRoleNamesError, + OrganizationUnitsGetRoleNamesResponse, + OrganizationUnitsGetUnaddedRolesData, + OrganizationUnitsGetUnaddedRolesError, + OrganizationUnitsGetUnaddedRolesResponse, + OrganizationUnitsGetRolesData, + OrganizationUnitsGetRolesError, + OrganizationUnitsGetRolesResponse, + OrganizationUnitsAddRolesData, + OrganizationUnitsAddRolesError, + OrganizationUnitsAddRolesResponse, + OrganizationUnitsGetUnaddedUsersData, + OrganizationUnitsGetUnaddedUsersError, + OrganizationUnitsGetUnaddedUsersResponse, + OrganizationUnitsGetUsersData, + OrganizationUnitsGetUsersError, + OrganizationUnitsGetUsersResponse, + OrganizationUnitsAddUsersData, + OrganizationUnitsAddUsersError, + OrganizationUnitsAddUsersResponse, + OrganizationUnitsMoveData, + OrganizationUnitsMoveError, + OrganizationUnitsMoveResponse, + OrganizationUnitEntityRuleGetData, + OrganizationUnitEntityRuleGetError, + OrganizationUnitEntityRuleGetResponse, + OrganizationUnitEntityRuleCreateData, + OrganizationUnitEntityRuleCreateError, + OrganizationUnitEntityRuleCreateResponse, + OrganizationUnitEntityRuleUpdateData, + OrganizationUnitEntityRuleUpdateError, + OrganizationUnitEntityRuleUpdateResponse, + OssContainerCreateData, + OssContainerCreateError, + OssContainerCreateResponse, + OssContainerDeleteData, + OssContainerDeleteError, + OssContainerDeleteResponse, + OssContainerGetData, + OssContainerGetError, + OssContainerGetResponse, + OssContainerGetListData, + OssContainerGetListError, + OssContainerGetListResponse, + OssContainerGetObjectListData, + OssContainerGetObjectListError, + OssContainerGetObjectListResponse, + OssManagementSettingGetAllForCurrentTenantData, + OssManagementSettingGetAllForCurrentTenantError, + OssManagementSettingGetAllForCurrentTenantResponse, + OssManagementSettingGetAllForGlobalData, + OssManagementSettingGetAllForGlobalError, + OssManagementSettingGetAllForGlobalResponse, + OssObjectCreateData, + OssObjectCreateError, + OssObjectCreateResponse, + OssObjectDeleteData, + OssObjectDeleteError, + OssObjectDeleteResponse, + OssObjectGetData, + OssObjectGetError, + OssObjectGetResponse, + OssObjectUploadData, + OssObjectUploadError, + OssObjectUploadResponse, + OssObjectBulkDeleteData, + OssObjectBulkDeleteError, + OssObjectBulkDeleteResponse, + OssObjectGetContentData, + OssObjectGetContentError, + OssObjectGetContentResponse, + PackageCreateData, + PackageCreateError, + PackageCreateResponse, + PackageGetListData, + PackageGetListError, + PackageGetListResponse, + PackageDeleteData, + PackageDeleteError, + PackageDeleteResponse, + PackageGetData, + PackageGetError, + PackageGetResponse, + PackageUpdateData, + PackageUpdateError, + PackageUpdateResponse, + PackageUploadBlobData, + PackageUploadBlobError, + PackageUploadBlobResponse, + PackageRemoveBlobData, + PackageRemoveBlobError, + PackageRemoveBlobResponse, + PackageDownloadBlobData, + PackageDownloadBlobError, + PackageDownloadBlobResponse, + PackageGetLatestData, + PackageGetLatestError, + PackageGetLatestResponse, + PackageGetLatest1Data, + PackageGetLatest1Error, + PackageGetLatest1Response, + PermissionDefinitionCreateData, + PermissionDefinitionCreateError, + PermissionDefinitionCreateResponse, + PermissionDefinitionGetListData, + PermissionDefinitionGetListError, + PermissionDefinitionGetListResponse, + PermissionDefinitionDeleteData, + PermissionDefinitionDeleteError, + PermissionDefinitionDeleteResponse, + PermissionDefinitionGetData, + PermissionDefinitionGetError, + PermissionDefinitionGetResponse, + PermissionDefinitionUpdateData, + PermissionDefinitionUpdateError, + PermissionDefinitionUpdateResponse, + PermissionGroupDefinitionCreateData, + PermissionGroupDefinitionCreateError, + PermissionGroupDefinitionCreateResponse, + PermissionGroupDefinitionGetListData, + PermissionGroupDefinitionGetListError, + PermissionGroupDefinitionGetListResponse, + PermissionGroupDefinitionDeleteData, + PermissionGroupDefinitionDeleteError, + PermissionGroupDefinitionDeleteResponse, + PermissionGroupDefinitionGetData, + PermissionGroupDefinitionGetError, + PermissionGroupDefinitionGetResponse, + PermissionGroupDefinitionUpdateData, + PermissionGroupDefinitionUpdateError, + PermissionGroupDefinitionUpdateResponse, + PermissionsGetData, + PermissionsGetError, + PermissionsGetResponse, + PermissionsUpdateData, + PermissionsUpdateError, + PermissionsUpdateResponse, + PrivateFilesUploadData, + PrivateFilesUploadError, + PrivateFilesUploadResponse, + PrivateFilesDeleteData, + PrivateFilesDeleteError, + PrivateFilesDeleteResponse, + PrivateFilesUpload1Data, + PrivateFilesUpload1Error, + PrivateFilesUpload1Response, + PrivateFilesGetListData, + PrivateFilesGetListError, + PrivateFilesGetListResponse, + PrivateFilesGetData, + PrivateFilesGetError, + PrivateFilesGetResponse, + PrivateFilesGet1Data, + PrivateFilesGet1Error, + PrivateFilesGet1Response, + PrivateFilesGet2Data, + PrivateFilesGet2Error, + PrivateFilesGet2Response, + PrivateFilesGet3Data, + PrivateFilesGet3Error, + PrivateFilesGet3Response, + PrivateFilesGet4Data, + PrivateFilesGet4Error, + PrivateFilesGet4Response, + PrivateFilesGet5Data, + PrivateFilesGet5Error, + PrivateFilesGet5Response, + PrivateFilesGet6Data, + PrivateFilesGet6Error, + PrivateFilesGet6Response, + PrivateFilesGet7Data, + PrivateFilesGet7Error, + PrivateFilesGet7Response, + PrivateFilesGetShareListData, + PrivateFilesGetShareListError, + PrivateFilesGetShareListResponse, + PrivateFilesShareData, + PrivateFilesShareError, + PrivateFilesShareResponse, + ProfileGetSessionsData, + ProfileGetSessionsError, + ProfileGetSessionsResponse, + ProfileRevokeSessionData, + ProfileRevokeSessionError, + ProfileRevokeSessionResponse, + ProfileGetTwoFactorEnabledData, + ProfileGetTwoFactorEnabledError, + ProfileGetTwoFactorEnabledResponse, + ProfileChangeTwoFactorEnabledData, + ProfileChangeTwoFactorEnabledError, + ProfileChangeTwoFactorEnabledResponse, + ProfileSendChangePhoneNumberCodeData, + ProfileSendChangePhoneNumberCodeError, + ProfileSendChangePhoneNumberCodeResponse, + ProfileChangePhoneNumberData, + ProfileChangePhoneNumberError, + ProfileChangePhoneNumberResponse, + ProfileSendEmailConfirmLinkData, + ProfileSendEmailConfirmLinkError, + ProfileSendEmailConfirmLinkResponse, + ProfileConfirmEmailData, + ProfileConfirmEmailError, + ProfileConfirmEmailResponse, + ProfileGetAuthenticatorData, + ProfileGetAuthenticatorError, + ProfileGetAuthenticatorResponse, + ProfileVerifyAuthenticatorCodeData, + ProfileVerifyAuthenticatorCodeError, + ProfileVerifyAuthenticatorCodeResponse, + ProfileResetAuthenticatorData, + ProfileResetAuthenticatorError, + ProfileResetAuthenticatorResponse, + ProfileGetData, + ProfileGetError, + ProfileGetResponse, + ProfileUpdateData, + ProfileUpdateError, + ProfileUpdateResponse, + ProfileChangePasswordData, + ProfileChangePasswordError, + ProfileChangePasswordResponse, + PublicFilesUploadData, + PublicFilesUploadError, + PublicFilesUploadResponse, + PublicFilesDeleteData, + PublicFilesDeleteError, + PublicFilesDeleteResponse, + PublicFilesUpload1Data, + PublicFilesUpload1Error, + PublicFilesUpload1Response, + PublicFilesGetListData, + PublicFilesGetListError, + PublicFilesGetListResponse, + PublicFilesGetData, + PublicFilesGetError, + PublicFilesGetResponse, + PublicFilesGet1Data, + PublicFilesGet1Error, + PublicFilesGet1Response, + PublicFilesGet2Data, + PublicFilesGet2Error, + PublicFilesGet2Response, + PublicFilesGet3Data, + PublicFilesGet3Error, + PublicFilesGet3Response, + PublicFilesGet4Data, + PublicFilesGet4Error, + PublicFilesGet4Response, + PublicFilesGet5Data, + PublicFilesGet5Error, + PublicFilesGet5Response, + PublicFilesGet6Data, + PublicFilesGet6Error, + PublicFilesGet6Response, + PublicFilesGet7Data, + PublicFilesGet7Error, + PublicFilesGet7Response, + PublishHandleData, + PublishHandleError, + PublishHandleResponse, + ResourceGetByNameData, + ResourceGetByNameError, + ResourceGetByNameResponse, + ResourceDeleteData, + ResourceDeleteError, + ResourceDeleteResponse, + ResourceUpdateData, + ResourceUpdateError, + ResourceUpdateResponse, + ResourceCreateData, + ResourceCreateError, + ResourceCreateResponse, + ResourceGetListData, + ResourceGetListError, + ResourceGetListResponse, + RestoreHandleData, + RestoreHandleError, + RestoreHandleResponse, + RetractHandleData, + RetractHandleError, + RetractHandleResponse, + RetryHandleData, + RetryHandleError, + RetryHandleResponse, + RevertHandleData, + RevertHandleError, + RevertHandleResponse, + RoleGetOrganizationUnitsData, + RoleGetOrganizationUnitsError, + RoleGetOrganizationUnitsResponse, + RoleSetOrganizationUnitsData, + RoleSetOrganizationUnitsError, + RoleSetOrganizationUnitsResponse, + RoleRemoveOrganizationUnitsData, + RoleRemoveOrganizationUnitsError, + RoleRemoveOrganizationUnitsResponse, + RoleGetClaimsData, + RoleGetClaimsError, + RoleGetClaimsResponse, + RoleAddClaimData, + RoleAddClaimError, + RoleAddClaimResponse, + RoleUpdateClaimData, + RoleUpdateClaimError, + RoleUpdateClaimResponse, + RoleDeleteClaimData, + RoleDeleteClaimError, + RoleDeleteClaimResponse, + RoleGetAllListData, + RoleGetAllListError, + RoleGetAllListResponse, + RoleGetListData, + RoleGetListError, + RoleGetListResponse, + RoleCreateData, + RoleCreateError, + RoleCreateResponse, + RoleGetData, + RoleGetError, + RoleGetResponse, + RoleUpdateData, + RoleUpdateError, + RoleUpdateResponse, + RoleDeleteData, + RoleDeleteError, + RoleDeleteResponse, + RoleEntityRuleGetData, + RoleEntityRuleGetError, + RoleEntityRuleGetResponse, + RoleEntityRuleCreateData, + RoleEntityRuleCreateError, + RoleEntityRuleCreateResponse, + RoleEntityRuleUpdateData, + RoleEntityRuleUpdateError, + RoleEntityRuleUpdateResponse, + SecurityLogDeleteData, + SecurityLogDeleteError, + SecurityLogDeleteResponse, + SecurityLogGetData, + SecurityLogGetError, + SecurityLogGetResponse, + SecurityLogGetListData, + SecurityLogGetListError, + SecurityLogGetListResponse, + SettingSetCurrentTenantData, + SettingSetCurrentTenantError, + SettingSetCurrentTenantResponse, + SettingSetGlobalData, + SettingSetGlobalError, + SettingSetGlobalResponse, + SettingGetAllForGlobalData, + SettingGetAllForGlobalError, + SettingGetAllForGlobalResponse, + SettingGetAllForCurrentTenantData, + SettingGetAllForCurrentTenantError, + SettingGetAllForCurrentTenantResponse, + SettingSendTestEmailData, + SettingSendTestEmailError, + SettingSendTestEmailResponse, + SettingDefinitionCreateData, + SettingDefinitionCreateError, + SettingDefinitionCreateResponse, + SettingDefinitionGetListData, + SettingDefinitionGetListError, + SettingDefinitionGetListResponse, + SettingDefinitionDeleteOrRestoreData, + SettingDefinitionDeleteOrRestoreError, + SettingDefinitionDeleteOrRestoreResponse, + SettingDefinitionGetData, + SettingDefinitionGetError, + SettingDefinitionGetResponse, + SettingDefinitionUpdateData, + SettingDefinitionUpdateError, + SettingDefinitionUpdateResponse, + StaticFilesUploadData, + StaticFilesUploadError, + StaticFilesUploadResponse, + StaticFilesGetData, + StaticFilesGetError, + StaticFilesGetResponse, + StaticFilesGet1Data, + StaticFilesGet1Error, + StaticFilesGet1Response, + StaticFilesGet2Data, + StaticFilesGet2Error, + StaticFilesGet2Response, + StaticFilesGet3Data, + StaticFilesGet3Error, + StaticFilesGet3Response, + StaticFilesGet4Data, + StaticFilesGet4Error, + StaticFilesGet4Response, + StaticFilesGet5Data, + StaticFilesGet5Error, + StaticFilesGet5Response, + StaticFilesGet6Data, + StaticFilesGet6Error, + StaticFilesGet6Response, + StaticFilesGet7Data, + StaticFilesGet7Error, + StaticFilesGet7Response, + TenantGetData, + TenantGetError, + TenantGetResponse, + TenantUpdateData, + TenantUpdateError, + TenantUpdateResponse, + TenantDeleteData, + TenantDeleteError, + TenantDeleteResponse, + TenantGet1Data, + TenantGet1Error, + TenantGet1Response, + TenantGetListData, + TenantGetListError, + TenantGetListResponse, + TenantCreateData, + TenantCreateError, + TenantCreateResponse, + TenantGetConnectionStringData, + TenantGetConnectionStringError, + TenantGetConnectionStringResponse, + TenantDeleteConnectionStringData, + TenantDeleteConnectionStringError, + TenantDeleteConnectionStringResponse, + TenantGetConnectionString1Data, + TenantGetConnectionString1Error, + TenantGetConnectionString1Response, + TenantSetConnectionStringData, + TenantSetConnectionStringError, + TenantSetConnectionStringResponse, + TextSetTextData, + TextSetTextError, + TextSetTextResponse, + TextRestoreToDefaultData, + TextRestoreToDefaultError, + TextRestoreToDefaultResponse, + TextGetByCultureKeyData, + TextGetByCultureKeyError, + TextGetByCultureKeyResponse, + TextGetListData, + TextGetListError, + TextGetListResponse, + TextTemplateContentGetData, + TextTemplateContentGetError, + TextTemplateContentGetResponse, + TextTemplateContentGet1Data, + TextTemplateContentGet1Error, + TextTemplateContentGet1Response, + TextTemplateContentRestoreToDefaultData, + TextTemplateContentRestoreToDefaultError, + TextTemplateContentRestoreToDefaultResponse, + TextTemplateContentUpdateData, + TextTemplateContentUpdateError, + TextTemplateContentUpdateResponse, + TextTemplateDefinitionCreateData, + TextTemplateDefinitionCreateError, + TextTemplateDefinitionCreateResponse, + TextTemplateDefinitionGetListData, + TextTemplateDefinitionGetListError, + TextTemplateDefinitionGetListResponse, + TextTemplateDefinitionDeleteData, + TextTemplateDefinitionDeleteError, + TextTemplateDefinitionDeleteResponse, + TextTemplateDefinitionGetByNameData, + TextTemplateDefinitionGetByNameError, + TextTemplateDefinitionGetByNameResponse, + TextTemplateDefinitionUpdateData, + TextTemplateDefinitionUpdateError, + TextTemplateDefinitionUpdateResponse, + ThemeSettingGetData, + ThemeSettingGetError, + ThemeSettingGetResponse, + ThemeSettingChangeData, + ThemeSettingChangeError, + ThemeSettingChangeResponse, + TriggerHandleData, + TriggerHandleError, + TriggerHandleResponse, + TriggerEndpointHandleData, + TriggerEndpointHandleError, + TriggerEndpointHandleResponse, + TriggerEndpointHandle1Data, + TriggerEndpointHandle1Error, + TriggerEndpointHandle1Response, + UserGetOrganizationUnitsData, + UserGetOrganizationUnitsError, + UserGetOrganizationUnitsResponse, + UserSetOrganizationUnitsData, + UserSetOrganizationUnitsError, + UserSetOrganizationUnitsResponse, + UserRemoveOrganizationUnitsData, + UserRemoveOrganizationUnitsError, + UserRemoveOrganizationUnitsResponse, + UserGetClaimsData, + UserGetClaimsError, + UserGetClaimsResponse, + UserAddClaimData, + UserAddClaimError, + UserAddClaimResponse, + UserUpdateClaimData, + UserUpdateClaimError, + UserUpdateClaimResponse, + UserDeleteClaimData, + UserDeleteClaimError, + UserDeleteClaimResponse, + UserChangePasswordData, + UserChangePasswordError, + UserChangePasswordResponse, + UserChangeTwoFactorEnabledData, + UserChangeTwoFactorEnabledError, + UserChangeTwoFactorEnabledResponse, + UserLockData, + UserLockError, + UserLockResponse, + UserUnLockData, + UserUnLockError, + UserUnLockResponse, + UserGetData, + UserGetError, + UserGetResponse, + UserUpdateData, + UserUpdateError, + UserUpdateResponse, + UserDeleteData, + UserDeleteError, + UserDeleteResponse, + UserGetListData, + UserGetListError, + UserGetListResponse, + UserCreateData, + UserCreateError, + UserCreateResponse, + UserGetRolesData, + UserGetRolesError, + UserGetRolesResponse, + UserUpdateRolesData, + UserUpdateRolesError, + UserUpdateRolesResponse, + UserGetAssignableRolesData, + UserGetAssignableRolesError, + UserGetAssignableRolesResponse, + UserFindByUsernameData, + UserFindByUsernameError, + UserFindByUsernameResponse, + UserFindByEmailData, + UserFindByEmailError, + UserFindByEmailResponse, + UserFavoriteMenuCreateData, + UserFavoriteMenuCreateError, + UserFavoriteMenuCreateResponse, + UserFavoriteMenuGetListData, + UserFavoriteMenuGetListError, + UserFavoriteMenuGetListResponse, + UserFavoriteMenuUpdateData, + UserFavoriteMenuUpdateError, + UserFavoriteMenuUpdateResponse, + UserFavoriteMenuCreateMyFavoriteMenuData, + UserFavoriteMenuCreateMyFavoriteMenuError, + UserFavoriteMenuCreateMyFavoriteMenuResponse, + UserFavoriteMenuGetMyFavoriteMenuListData, + UserFavoriteMenuGetMyFavoriteMenuListError, + UserFavoriteMenuGetMyFavoriteMenuListResponse, + UserFavoriteMenuUpdateMyFavoriteMenuData, + UserFavoriteMenuUpdateMyFavoriteMenuError, + UserFavoriteMenuUpdateMyFavoriteMenuResponse, + UserFavoriteMenuDeleteData, + UserFavoriteMenuDeleteError, + UserFavoriteMenuDeleteResponse, + UserFavoriteMenuDeleteMyFavoriteMenuData, + UserFavoriteMenuDeleteMyFavoriteMenuError, + UserFavoriteMenuDeleteMyFavoriteMenuResponse, + UserGroupApplyJoinGroupData, + UserGroupApplyJoinGroupError, + UserGroupApplyJoinGroupResponse, + UserGroupGetGroupUsersData, + UserGroupGetGroupUsersError, + UserGroupGetGroupUsersResponse, + UserGroupGetMyGroupsData, + UserGroupGetMyGroupsError, + UserGroupGetMyGroupsResponse, + UserGroupGroupAcceptUserData, + UserGroupGroupAcceptUserError, + UserGroupGroupAcceptUserResponse, + UserGroupGroupRemoveUserData, + UserGroupGroupRemoveUserError, + UserGroupGroupRemoveUserResponse, + UserLookupFindByIdData, + UserLookupFindByIdError, + UserLookupFindByIdResponse, + UserLookupFindByUserNameData, + UserLookupFindByUserNameError, + UserLookupFindByUserNameResponse, + UserLookupSearchData, + UserLookupSearchError, + UserLookupSearchResponse, + UserLookupGetCountData, + UserLookupGetCountError, + UserLookupGetCountResponse, + UserSettingGetAllForCurrentUserData, + UserSettingGetAllForCurrentUserError, + UserSettingGetAllForCurrentUserResponse, + UserSettingSetCurrentUserData, + UserSettingSetCurrentUserError, + UserSettingSetCurrentUserResponse, + WebhookDefinitionCreateData, + WebhookDefinitionCreateError, + WebhookDefinitionCreateResponse, + WebhookDefinitionGetListData, + WebhookDefinitionGetListError, + WebhookDefinitionGetListResponse, + WebhookDefinitionDeleteData, + WebhookDefinitionDeleteError, + WebhookDefinitionDeleteResponse, + WebhookDefinitionGetData, + WebhookDefinitionGetError, + WebhookDefinitionGetResponse, + WebhookDefinitionUpdateData, + WebhookDefinitionUpdateError, + WebhookDefinitionUpdateResponse, + WebhookGroupDefinitionCreateData, + WebhookGroupDefinitionCreateError, + WebhookGroupDefinitionCreateResponse, + WebhookGroupDefinitionGetListData, + WebhookGroupDefinitionGetListError, + WebhookGroupDefinitionGetListResponse, + WebhookGroupDefinitionDeleteAysncData, + WebhookGroupDefinitionDeleteAysncError, + WebhookGroupDefinitionDeleteAysncResponse, + WebhookGroupDefinitionGetData, + WebhookGroupDefinitionGetError, + WebhookGroupDefinitionGetResponse, + WebhookGroupDefinitionUpdateData, + WebhookGroupDefinitionUpdateError, + WebhookGroupDefinitionUpdateResponse, + WebhookPublishPublishData, + WebhookPublishPublishError, + WebhookPublishPublishResponse, + WebhookSendRecordGetData, + WebhookSendRecordGetError, + WebhookSendRecordGetResponse, + WebhookSendRecordDeleteData, + WebhookSendRecordDeleteError, + WebhookSendRecordDeleteResponse, + WebhookSendRecordDeleteManyData, + WebhookSendRecordDeleteManyError, + WebhookSendRecordDeleteManyResponse, + WebhookSendRecordGetListData, + WebhookSendRecordGetListError, + WebhookSendRecordGetListResponse, + WebhookSendRecordResendData, + WebhookSendRecordResendError, + WebhookSendRecordResendResponse, + WebhookSendRecordResendManyData, + WebhookSendRecordResendManyError, + WebhookSendRecordResendManyResponse, + WebhookSubscriptionCreateData, + WebhookSubscriptionCreateError, + WebhookSubscriptionCreateResponse, + WebhookSubscriptionGetListData, + WebhookSubscriptionGetListError, + WebhookSubscriptionGetListResponse, + WebhookSubscriptionDeleteData, + WebhookSubscriptionDeleteError, + WebhookSubscriptionDeleteResponse, + WebhookSubscriptionGetData, + WebhookSubscriptionGetError, + WebhookSubscriptionGetResponse, + WebhookSubscriptionUpdateData, + WebhookSubscriptionUpdateError, + WebhookSubscriptionUpdateResponse, + WebhookSubscriptionDeleteManyData, + WebhookSubscriptionDeleteManyError, + WebhookSubscriptionDeleteManyResponse, + WebhookSubscriptionGetAllAvailableWebhooksData, + WebhookSubscriptionGetAllAvailableWebhooksError, + WebhookSubscriptionGetAllAvailableWebhooksResponse, +} from "./types.gen"; + +export const client = createClient(createConfig()); + +export const abpApiDefinitionGet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/abp/api-definition", + }); +}; + +export const abpApplicationConfigurationGet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + AbpApplicationConfigurationGetResponse, + AbpApplicationConfigurationGetError, + ThrowOnError + >({ + ...options, + url: "/api/abp/application-configuration", + }); +}; + +export const abpApplicationLocalizationGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + AbpApplicationLocalizationGetResponse, + AbpApplicationLocalizationGetError, + ThrowOnError + >({ + ...options, + url: "/api/abp/application-localization", + }); +}; + +export const abpTenantFindTenantByName = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + AbpTenantFindTenantByNameResponse, + AbpTenantFindTenantByNameError, + ThrowOnError + >({ + ...options, + url: "/api/abp/multi-tenancy/tenants/by-name/{name}", + }); +}; + +export const abpTenantFindTenantById = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/abp/multi-tenancy/tenants/by-id/{id}", + }); +}; + +export const accountRegister = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/phone/register", + }); +}; + +export const accountResetPassword = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/account/phone/reset-password", + }); +}; + +export const accountSendPhoneSigninCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + AccountSendPhoneSigninCodeResponse, + AccountSendPhoneSigninCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/phone/send-signin-code", + }); +}; + +export const accountSendEmailSigninCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + AccountSendEmailSigninCodeResponse, + AccountSendEmailSigninCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/email/send-signin-code", + }); +}; + +export const accountSendPhoneRegisterCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + AccountSendPhoneRegisterCodeResponse, + AccountSendPhoneRegisterCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/phone/send-register-code", + }); +}; + +export const accountSendPhoneResetPasswordCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + AccountSendPhoneResetPasswordCodeResponse, + AccountSendPhoneResetPasswordCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/phone/send-password-reset-code", + }); +}; + +export const accountGetTwoFactorProviders = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + AccountGetTwoFactorProvidersResponse, + AccountGetTwoFactorProvidersError, + ThrowOnError + >({ + ...options, + url: "/api/account/two-factor-providers", + }); +}; + +export const accountRegister1 = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/register", + }); +}; + +export const accountSendPasswordResetCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + AccountSendPasswordResetCodeResponse, + AccountSendPasswordResetCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/send-password-reset-code", + }); +}; + +export const accountVerifyPasswordResetToken = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + AccountVerifyPasswordResetTokenResponse, + AccountVerifyPasswordResetTokenError, + ThrowOnError + >({ + ...options, + url: "/api/account/verify-password-reset-token", + }); +}; + +export const accountResetPassword1 = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/reset-password", + }); +}; + +export const auditLogDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/auditing/audit-log/{id}", + }); +}; + +export const auditLogGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/audit-log/{id}", + }); +}; + +export const auditLogGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/audit-log", + }); +}; + +export const backgroundJobActionAddAction = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + BackgroundJobActionAddActionResponse, + BackgroundJobActionAddActionError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/actions/{jobId}", + }); +}; + +export const backgroundJobActionGetActions = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + BackgroundJobActionGetActionsResponse, + BackgroundJobActionGetActionsError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/actions/{jobId}", + }); +}; + +export const backgroundJobActionDeleteAction = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + BackgroundJobActionDeleteActionResponse, + BackgroundJobActionDeleteActionError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/actions/{id}", + }); +}; + +export const backgroundJobActionUpdateAction = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + BackgroundJobActionUpdateActionResponse, + BackgroundJobActionUpdateActionError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/actions/{id}", + }); +}; + +export const backgroundJobActionGetDefinitions = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + BackgroundJobActionGetDefinitionsResponse, + BackgroundJobActionGetDefinitionsError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/actions/definitions", + }); +}; + +export const backgroundJobInfoCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/task-management/background-jobs", + }); +}; + +export const backgroundJobInfoGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/task-management/background-jobs", + }, + ); +}; + +export const backgroundJobInfoDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + BackgroundJobInfoDeleteResponse, + BackgroundJobInfoDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/{id}", + }); +}; + +export const backgroundJobInfoGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/task-management/background-jobs/{id}", + }); +}; + +export const backgroundJobInfoUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/task-management/background-jobs/{id}", + }); +}; + +export const backgroundJobInfoPause = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/task-management/background-jobs/{id}/pause", + }); +}; + +export const backgroundJobInfoResume = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/task-management/background-jobs/{id}/resume", + }); +}; + +export const backgroundJobInfoTrigger = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put( + { + ...options, + url: "/api/task-management/background-jobs/{id}/trigger", + }, + ); +}; + +export const backgroundJobInfoStop = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/task-management/background-jobs/{id}/stop", + }); +}; + +export const backgroundJobInfoStart = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/task-management/background-jobs/{id}/start", + }); +}; + +export const backgroundJobInfoBulkStop = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + BackgroundJobInfoBulkStopResponse, + BackgroundJobInfoBulkStopError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/bulk-stop", + }); +}; + +export const backgroundJobInfoBulkStart = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + BackgroundJobInfoBulkStartResponse, + BackgroundJobInfoBulkStartError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/bulk-start", + }); +}; + +export const backgroundJobInfoBulkTrigger = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + BackgroundJobInfoBulkTriggerResponse, + BackgroundJobInfoBulkTriggerError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/bulk-trigger", + }); +}; + +export const backgroundJobInfoBulkResume = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + BackgroundJobInfoBulkResumeResponse, + BackgroundJobInfoBulkResumeError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/bulk-resume", + }); +}; + +export const backgroundJobInfoBulkPause = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + BackgroundJobInfoBulkPauseResponse, + BackgroundJobInfoBulkPauseError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/bulk-pause", + }); +}; + +export const backgroundJobInfoBulkDelete = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + BackgroundJobInfoBulkDeleteResponse, + BackgroundJobInfoBulkDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/bulk-delete", + }); +}; + +export const backgroundJobInfoGetDefinitions = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + BackgroundJobInfoGetDefinitionsResponse, + BackgroundJobInfoGetDefinitionsError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/definitions", + }); +}; + +export const backgroundJobInfoGetAvailableFields = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + BackgroundJobInfoGetAvailableFieldsResponse, + BackgroundJobInfoGetAvailableFieldsError, + ThrowOnError + >({ + ...options, + url: "/api/task-management/background-jobs/available-fields", + }); +}; + +export const backgroundJobInfoSearch = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/task-management/background-jobs/search", + }); +}; + +export const backgroundJobLogDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/task-management/background-jobs/logs/{id}", + }); +}; + +export const backgroundJobLogGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/task-management/background-jobs/logs/{id}", + }); +}; + +export const backgroundJobLogGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/task-management/background-jobs/logs", + }); +}; + +export const backupHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-definitions/backup", + }); +}; + +export const bulkCancelHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-instances/bulk/cancel", + }); +}; + +export const bulkDeleteHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/v{apiVersion}/workflow-instances/bulk", + }); +}; + +export const bulkRetryHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-instances/bulk/retry", + }); +}; + +export const cacheGetKeys = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/caching-management/cache/keys", + }); +}; + +export const cacheGetValue = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/caching-management/cache/value", + }); +}; + +export const cacheSet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/caching-management/cache/set", + }); +}; + +export const cacheRefresh = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/caching-management/cache/refresh", + }); +}; + +export const cacheRemove = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/caching-management/cache/remove", + }); +}; + +export const cancelHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-instances/{id}/cancel", + }); +}; + +export const chatGetMyGroupMessage = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/chat/group/messages", + }); +}; + +export const chatGetMyChatMessage = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/chat/my-messages", + }); +}; + +export const chatGetMyLastChatMessage = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/im/chat/my-last-messages", + }, + ); +}; + +export const chatSendMessage = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/im/chat/send-message", + }); +}; + +export const claimChangeAvatar = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/my-claim/change-avatar", + }); +}; + +export const claimTypeCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/identity/claim-types", + }); +}; + +export const claimTypeGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/claim-types", + }); +}; + +export const claimTypeDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/identity/claim-types/{id}", + }); +}; + +export const claimTypeGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/claim-types/{id}", + }); +}; + +export const claimTypeUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/claim-types/{id}", + }); +}; + +export const claimTypeGetAllList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/claim-types/actived-list", + }); +}; + +export const dataCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/datas", + }); +}; + +export const dataGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/datas", + }); +}; + +export const dataCreateItem = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/datas/{id}/items", + }); +}; + +export const dataDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/datas/{id}", + }); +}; + +export const dataGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/datas/{id}", + }); +}; + +export const dataUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/datas/{id}", + }); +}; + +export const dataDeleteItem = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/datas/{id}/items/{name}", + }); +}; + +export const dataUpdateItem = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/datas/{id}/items/{name}", + }); +}; + +export const dataGet1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/datas/by-name/{name}", + }); +}; + +export const dataGetAll = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/datas/all", + }); +}; + +export const dataMove = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/datas/{id}/move", + }); +}; + +export const deleteHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/v{apiVersion}/workflow-instances/{id}", + }); +}; + +export const getHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-instances/{id}", + }); +}; + +export const deleteHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/v{apiVersion}/webhook-definitions/{id}", + }); +}; + +export const getHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/webhook-definitions/{id}", + }); +}; + +export const deleteByDefinitionHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + DeleteByDefinitionHandleResponse, + DeleteByDefinitionHandleError, + ThrowOnError + >({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{definitionId}", + }); +}; + +export const deleteByDefinitionAndVersionHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + DeleteByDefinitionAndVersionHandleResponse, + DeleteByDefinitionAndVersionHandleError, + ThrowOnError + >({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{definitionId}/{versionOptions}", + }); +}; + +export const dispatchHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflows/{workflowDefinitionId}/dispatch", + }); +}; + +export const dispatchHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-instances/{workflowInstanceId}/dispatch", + }); +}; + +export const dispatchHandle2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/signals/{signalName}/dispatch", + }); +}; + +export const dispatchEndpointHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/signals/dispatch/{token}", + }); +}; + +export const dispatchEndpointHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/signals/dispatch/{token}", + }); +}; + +export const dynamicClaimsRefresh = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/dynamic-claims/refresh", + }); +}; + +export const editionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/saas/editions", + }); +}; + +export const editionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/saas/editions", + }); +}; + +export const editionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/saas/editions/{id}", + }); +}; + +export const editionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/saas/editions/{id}", + }); +}; + +export const editionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/saas/editions/{id}", + }); +}; + +export const entityChangesGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/entity-changes/{id}", + }); +}; + +export const entityChangesGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/entity-changes", + }); +}; + +export const entityChangesGetWithUsername = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + EntityChangesGetWithUsernameResponse, + EntityChangesGetWithUsernameError, + ThrowOnError + >({ + ...options, + url: "/api/auditing/entity-changes/with-username/{id}", + }); +}; + +export const entityChangesGetWithUsername1 = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + EntityChangesGetWithUsername1Response, + EntityChangesGetWithUsername1Error, + ThrowOnError + >({ + ...options, + url: "/api/auditing/entity-changes/with-username", + }); +}; + +export const entityTypeInfoGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/data-protection-management/entity-type-infos/{id}", + }); +}; + +export const entityTypeInfoGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/data-protection-management/entity-type-infos", + }); +}; + +export const executeHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflows/{workflowDefinitionId}/execute", + }); +}; + +export const executeHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-instances/{workflowInstanceId}/execute", + }); +}; + +export const executeHandle2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/signals/{signalName}/execute", + }); +}; + +export const exportHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{workflowDefinitionId}/{versionOptions}/export", + }); +}; + +export const featureDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/feature-management/definitions", + }); +}; + +export const featureDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/feature-management/definitions", + }, + ); +}; + +export const featureDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + FeatureDefinitionDeleteResponse, + FeatureDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/feature-management/definitions/{name}", + }); +}; + +export const featureDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/feature-management/definitions/{name}", + }); +}; + +export const featureDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/feature-management/definitions/{name}", + }); +}; + +export const featureGroupDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + FeatureGroupDefinitionCreateResponse, + FeatureGroupDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/feature-management/definitions/groups", + }); +}; + +export const featureGroupDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + FeatureGroupDefinitionGetListResponse, + FeatureGroupDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/feature-management/definitions/groups", + }); +}; + +export const featureGroupDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + FeatureGroupDefinitionDeleteResponse, + FeatureGroupDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/feature-management/definitions/groups/{name}", + }); +}; + +export const featureGroupDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + FeatureGroupDefinitionGetResponse, + FeatureGroupDefinitionGetError, + ThrowOnError + >({ + ...options, + url: "/api/feature-management/definitions/groups/{name}", + }); +}; + +export const featureGroupDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + FeatureGroupDefinitionUpdateResponse, + FeatureGroupDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/feature-management/definitions/groups/{name}", + }); +}; + +export const featuresGet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/feature-management/features", + }); +}; + +export const featuresUpdate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/feature-management/features", + }); +}; + +export const featuresDelete = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/feature-management/features", + }); +}; + +export const feedbackCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/feedbacks", + }); +}; + +export const feedbackGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/feedbacks", + }); +}; + +export const feedbackDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/feedbacks/{id}", + }); +}; + +export const feedbackGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/feedbacks/{id}", + }); +}; + +export const feedbackAttachmentGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/feedbacks/{FeedbackId}/attachments/{Name}", + }); +}; + +export const feedbackAttachmentDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + FeedbackAttachmentDeleteResponse, + FeedbackAttachmentDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/platform/feedbacks/{FeedbackId}/attachments/{Name}", + }); +}; + +export const feedbackAttachmentUpload = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + FeedbackAttachmentUploadResponse, + FeedbackAttachmentUploadError, + ThrowOnError + >({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/platform/feedbacks/attachments/upload", + }); +}; + +export const getHandle2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-registry/{id}/{versionOptions}", + }); +}; + +export const getHandle3 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-instances/{id}/execution-log", + }); +}; + +export const getHandle4 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/version", + }); +}; + +export const getHandle5 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/scripting/javascript/type-definitions/{workflowDefinitionId}", + }); +}; + +export const getHandle6 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/designer/runtime-select-list", + }); +}; + +export const getHandle7 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-instances/{workflowInstanceId}/activity-stats/{activityId}", + }); +}; + +export const getByDefinitionAndVersionHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + GetByDefinitionAndVersionHandleResponse, + GetByDefinitionAndVersionHandleError, + ThrowOnError + >({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{workflowDefinitionId}/{versionOptions}", + }); +}; + +export const getByVersionIdHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{versionId}", + }); +}; + +export const groupGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/groups/{groupId}", + }); +}; + +export const groupSearch = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/groups/search", + }); +}; + +export const historyHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{definitionId}/history", + }); +}; + +export const identitySessionsGetSessions = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + IdentitySessionsGetSessionsResponse, + IdentitySessionsGetSessionsError, + ThrowOnError + >({ + ...options, + url: "/api/identity/sessions", + }); +}; + +export const identitySessionsRevokeSession = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + IdentitySessionsRevokeSessionResponse, + IdentitySessionsRevokeSessionError, + ThrowOnError + >({ + ...options, + url: "/api/identity/sessions/{sessionId}/revoke", + }); +}; + +export const importHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/v{apiVersion}/workflow-definitions/{workflowDefinitionId}/import", + }); +}; + +export const languageGetByName = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/localization/languages/{name}", + }); +}; + +export const languageDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/localization/languages/{name}", + }); +}; + +export const languageUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/localization/languages/{name}", + }); +}; + +export const languageCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/localization/languages", + }); +}; + +export const languageGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/abp/localization/languages", + }); +}; + +export const layoutCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/layouts", + }); +}; + +export const layoutGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/layouts", + }); +}; + +export const layoutDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/layouts/{id}", + }); +}; + +export const layoutGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/layouts/{id}", + }); +}; + +export const layoutUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/layouts/{id}", + }); +}; + +export const layoutGetAllList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/layouts/all", + }); +}; + +export const listHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{version}/workflow-storage-providers", + }); +}; + +export const listHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{version}/workflow-providers", + }); +}; + +export const listHandle2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-instances", + }); +}; + +export const listHandle3 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-definitions", + }); +}; + +export const saveHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-definitions", + }); +}; + +export const listHandle4 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-channels", + }); +}; + +export const listHandle5 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/features", + }); +}; + +export const listHandle6 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{version}/activities", + }); +}; + +export const listHandle7 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/webhook-definitions", + }); +}; + +export const postHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/webhook-definitions", + }); +}; + +export const updateHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/v{apiVersion}/webhook-definitions", + }); +}; + +export const listAllHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-registry", + }); +}; + +export const listByDefinitionVersionIdsHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + ListByDefinitionVersionIdsHandleResponse, + ListByDefinitionVersionIdsHandleError, + ThrowOnError + >({ + ...options, + url: "/v{apiVersion}/workflow-registry/by-definition-version-ids", + }); +}; + +export const listByProviderHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/v{apiVersion}/workflow-registry/by-provider/{providerName}", + }); +}; + +export const loggingGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/logging/{id}", + }); +}; + +export const loggingGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/logging", + }); +}; + +export const loginLogin = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/login", + }); +}; + +export const loginLogout = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/account/logout", + }); +}; + +export const loginCheckPassword = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/check-password", + }); +}; + +export const menuGetCurrentUserMenuList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + MenuGetCurrentUserMenuListResponse, + MenuGetCurrentUserMenuListError, + ThrowOnError + >({ + ...options, + url: "/api/platform/menus/by-current-user", + }); +}; + +export const menuGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/{id}", + }); +}; + +export const menuUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/menus/{id}", + }); +}; + +export const menuDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/menus/{id}", + }); +}; + +export const menuGetAll = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/all", + }); +}; + +export const menuGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus", + }); +}; + +export const menuCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/menus", + }); +}; + +export const menuSetUserMenus = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/menus/by-user", + }); +}; + +export const menuGetUserMenuList = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/by-user", + }); +}; + +export const menuSetUserStartup = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/menus/startup/{id}/by-user", + }); +}; + +export const menuGetUserMenuList1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/by-user/{userId}/{framework}", + }); +}; + +export const menuSetRoleMenus = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/menus/by-role", + }); +}; + +export const menuGetRoleMenuList = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/by-role", + }); +}; + +export const menuSetRoleStartup = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/menus/startup/{id}/by-role", + }); +}; + +export const menuGetRoleMenuList1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/by-role/{role}/{framework}", + }); +}; + +export const myFeedbackGetMyFeedbacks = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/platform/my-feedbacks", + }, + ); +}; + +export const myFriendCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/im/my-friends", + }); +}; + +export const myFriendDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/im/my-friends", + }); +}; + +export const myFriendGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/my-friends", + }); +}; + +export const myFriendAddRequest = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/im/my-friends/add-request", + }); +}; + +export const myFriendGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/my-friends/{friendId}", + }); +}; + +export const myFriendGetAllList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/my-friends/all", + }); +}; + +export const myNotificationMarkReadState = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + MyNotificationMarkReadStateResponse, + MyNotificationMarkReadStateError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/my-notifilers/mark-read-state", + }); +}; + +export const myNotificationDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/notifications/my-notifilers/{id}", + }); +}; + +export const myNotificationGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/notifications/my-notifilers/{id}", + }); +}; + +export const myNotificationGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/notifications/my-notifilers", + }); +}; + +export const mySubscriptionGetAllList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/notifications/my-subscribes/all", + }, + ); +}; + +export const mySubscriptionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/notifications/my-subscribes", + }); +}; + +export const mySubscriptionSubscribe = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/notifications/my-subscribes", + }); +}; + +export const mySubscriptionUnSubscribe = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + MySubscriptionUnSubscribeResponse, + MySubscriptionUnSubscribeError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/my-subscribes", + }); +}; + +export const mySubscriptionIsSubscribed = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + MySubscriptionIsSubscribedResponse, + MySubscriptionIsSubscribedError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/my-subscribes/is-subscribed/{Name}", + }); +}; + +export const notificationSend = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/notifications/send", + }); +}; + +export const notificationSend1 = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/notifications/send/template", + }); +}; + +export const notificationGetAssignableNotifiers = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + NotificationGetAssignableNotifiersResponse, + NotificationGetAssignableNotifiersError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/assignables", + }); +}; + +export const notificationGetAssignableTemplates = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + NotificationGetAssignableTemplatesResponse, + NotificationGetAssignableTemplatesError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/assignable-templates", + }); +}; + +export const notificationDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + NotificationDefinitionCreateResponse, + NotificationDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/notifications", + }); +}; + +export const notificationDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + NotificationDefinitionGetListResponse, + NotificationDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/notifications", + }); +}; + +export const notificationDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + NotificationDefinitionDeleteResponse, + NotificationDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/notifications/{name}", + }); +}; + +export const notificationDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + NotificationDefinitionGetResponse, + NotificationDefinitionGetError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/notifications/{name}", + }); +}; + +export const notificationDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + NotificationDefinitionUpdateResponse, + NotificationDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/notifications/{name}", + }); +}; + +export const notificationGroupDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + NotificationGroupDefinitionCreateResponse, + NotificationGroupDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/groups", + }); +}; + +export const notificationGroupDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + NotificationGroupDefinitionGetListResponse, + NotificationGroupDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/groups", + }); +}; + +export const notificationGroupDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + NotificationGroupDefinitionDeleteResponse, + NotificationGroupDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/groups/{name}", + }); +}; + +export const notificationGroupDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + NotificationGroupDefinitionGetResponse, + NotificationGroupDefinitionGetError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/groups/{name}", + }); +}; + +export const notificationGroupDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + NotificationGroupDefinitionUpdateResponse, + NotificationGroupDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/notifications/definitions/groups/{name}", + }); +}; + +export const openIddictApplicationGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/openiddict/applications/{id}", + }, + ); +}; + +export const openIddictApplicationUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + OpenIddictApplicationUpdateResponse, + OpenIddictApplicationUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/applications/{id}", + }); +}; + +export const openIddictApplicationDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + OpenIddictApplicationDeleteResponse, + OpenIddictApplicationDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/applications/{id}", + }); +}; + +export const openIddictApplicationGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OpenIddictApplicationGetListResponse, + OpenIddictApplicationGetListError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/applications", + }); +}; + +export const openIddictApplicationCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + OpenIddictApplicationCreateResponse, + OpenIddictApplicationCreateError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/applications", + }); +}; + +export const openIddictAuthorizationDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + OpenIddictAuthorizationDeleteResponse, + OpenIddictAuthorizationDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/authorizations/{id}", + }); +}; + +export const openIddictAuthorizationGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OpenIddictAuthorizationGetResponse, + OpenIddictAuthorizationGetError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/authorizations/{id}", + }); +}; + +export const openIddictAuthorizationGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OpenIddictAuthorizationGetListResponse, + OpenIddictAuthorizationGetListError, + ThrowOnError + >({ + ...options, + url: "/api/openiddict/authorizations", + }); +}; + +export const openIddictScopeCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/openiddict/scopes", + }); +}; + +export const openIddictScopeGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/openiddict/scopes", + }); +}; + +export const openIddictScopeDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/openiddict/scopes/{id}", + }); +}; + +export const openIddictScopeGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/openiddict/scopes/{id}", + }); +}; + +export const openIddictScopeUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/openiddict/scopes/{id}", + }); +}; + +export const openIddictTokenDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/openiddict/tokens/{id}", + }); +}; + +export const openIddictTokenGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/openiddict/tokens/{id}", + }); +}; + +export const openIddictTokenGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/openiddict/tokens", + }); +}; + +export const organizationUnitsCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/identity/organization-units", + }); +}; + +export const organizationUnitsGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/identity/organization-units", + }, + ); +}; + +export const organizationUnitsDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + OrganizationUnitsDeleteResponse, + OrganizationUnitsDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}", + }); +}; + +export const organizationUnitsGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/organization-units/{id}", + }); +}; + +export const organizationUnitsUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/organization-units/{id}", + }); +}; + +export const organizationUnitsFindChildren = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsFindChildrenResponse, + OrganizationUnitsFindChildrenError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/find-children", + }); +}; + +export const organizationUnitsGetRoot = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/identity/organization-units/root-node", + }, + ); +}; + +export const organizationUnitsGetLastChildOrNull = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetLastChildOrNullResponse, + OrganizationUnitsGetLastChildOrNullError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/last-children", + }); +}; + +export const organizationUnitsGetAllList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetAllListResponse, + OrganizationUnitsGetAllListError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/all", + }); +}; + +export const organizationUnitsGetRoleNames = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetRoleNamesResponse, + OrganizationUnitsGetRoleNamesError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/role-names", + }); +}; + +export const organizationUnitsGetUnaddedRoles = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetUnaddedRolesResponse, + OrganizationUnitsGetUnaddedRolesError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/unadded-roles", + }); +}; + +export const organizationUnitsGetRoles = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetRolesResponse, + OrganizationUnitsGetRolesError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/roles", + }); +}; + +export const organizationUnitsAddRoles = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + OrganizationUnitsAddRolesResponse, + OrganizationUnitsAddRolesError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/roles", + }); +}; + +export const organizationUnitsGetUnaddedUsers = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetUnaddedUsersResponse, + OrganizationUnitsGetUnaddedUsersError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/unadded-users", + }); +}; + +export const organizationUnitsGetUsers = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitsGetUsersResponse, + OrganizationUnitsGetUsersError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/users", + }); +}; + +export const organizationUnitsAddUsers = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + OrganizationUnitsAddUsersResponse, + OrganizationUnitsAddUsersError, + ThrowOnError + >({ + ...options, + url: "/api/identity/organization-units/{id}/users", + }); +}; + +export const organizationUnitsMove = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/organization-units/{id}/move", + }); +}; + +export const organizationUnitEntityRuleGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OrganizationUnitEntityRuleGetResponse, + OrganizationUnitEntityRuleGetError, + ThrowOnError + >({ + ...options, + url: "/api/data-protection-management/entity-rule/organization-units", + }); +}; + +export const organizationUnitEntityRuleCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + OrganizationUnitEntityRuleCreateResponse, + OrganizationUnitEntityRuleCreateError, + ThrowOnError + >({ + ...options, + url: "/api/data-protection-management/entity-rule/organization-units", + }); +}; + +export const organizationUnitEntityRuleUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + OrganizationUnitEntityRuleUpdateResponse, + OrganizationUnitEntityRuleUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/data-protection-management/entity-rule/organization-units/{id}", + }); +}; + +export const ossContainerCreate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/oss-management/containes/{name}", + }); +}; + +export const ossContainerDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/oss-management/containes/{name}", + }); +}; + +export const ossContainerGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/oss-management/containes/{name}", + }); +}; + +export const ossContainerGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/oss-management/containes", + }); +}; + +export const ossContainerGetObjectList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OssContainerGetObjectListResponse, + OssContainerGetObjectListError, + ThrowOnError + >({ + ...options, + url: "/api/oss-management/containes/objects", + }); +}; + +export const ossManagementSettingGetAllForCurrentTenant = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OssManagementSettingGetAllForCurrentTenantResponse, + OssManagementSettingGetAllForCurrentTenantError, + ThrowOnError + >({ + ...options, + url: "/api/setting-management/oss-management/by-current-tenant", + }); +}; + +export const ossManagementSettingGetAllForGlobal = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + OssManagementSettingGetAllForGlobalResponse, + OssManagementSettingGetAllForGlobalError, + ThrowOnError + >({ + ...options, + url: "/api/setting-management/oss-management/by-global", + }); +}; + +export const ossObjectCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/oss-management/objects", + }); +}; + +export const ossObjectDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/oss-management/objects", + }); +}; + +export const ossObjectGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/oss-management/objects", + }); +}; + +export const ossObjectUpload = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/oss-management/objects/upload", + }); +}; + +export const ossObjectBulkDelete = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/oss-management/objects/bulk-delete", + }); +}; + +export const ossObjectGetContent = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/oss-management/objects/download", + }); +}; + +export const packageCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/packages", + }); +}; + +export const packageGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/packages", + }); +}; + +export const packageDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/packages/{id}", + }); +}; + +export const packageGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/packages/{id}", + }); +}; + +export const packageUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/packages/{id}", + }); +}; + +export const packageUploadBlob = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/platform/packages/{id}/blob", + }); +}; + +export const packageRemoveBlob = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/packages/{id}/blob/{Name}", + }); +}; + +export const packageDownloadBlob = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/packages/{id}/blob/{Name}", + }); +}; + +export const packageGetLatest = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/packages/{Name}/latest", + }); +}; + +export const packageGetLatest1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/packages/{Name}/latest/{Version}", + }); +}; + +export const permissionDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + PermissionDefinitionCreateResponse, + PermissionDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions", + }); +}; + +export const permissionDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + PermissionDefinitionGetListResponse, + PermissionDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions", + }); +}; + +export const permissionDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + PermissionDefinitionDeleteResponse, + PermissionDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/{name}", + }); +}; + +export const permissionDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/permission-management/definitions/{name}", + }); +}; + +export const permissionDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + PermissionDefinitionUpdateResponse, + PermissionDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/{name}", + }); +}; + +export const permissionGroupDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + PermissionGroupDefinitionCreateResponse, + PermissionGroupDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/groups", + }); +}; + +export const permissionGroupDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + PermissionGroupDefinitionGetListResponse, + PermissionGroupDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/groups", + }); +}; + +export const permissionGroupDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + PermissionGroupDefinitionDeleteResponse, + PermissionGroupDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/groups/{name}", + }); +}; + +export const permissionGroupDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + PermissionGroupDefinitionGetResponse, + PermissionGroupDefinitionGetError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/groups/{name}", + }); +}; + +export const permissionGroupDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + PermissionGroupDefinitionUpdateResponse, + PermissionGroupDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/permission-management/definitions/groups/{name}", + }); +}; + +export const permissionsGet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/permission-management/permissions", + }); +}; + +export const permissionsUpdate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/permission-management/permissions", + }); +}; + +export const privateFilesUpload = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/files/private", + }); +}; + +export const privateFilesDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/files/private", + }); +}; + +export const privateFilesUpload1 = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/files/private/upload", + }); +}; + +export const privateFilesGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/search", + }); +}; + +export const privateFilesGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/{Name}", + }); +}; + +export const privateFilesGet1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/{Name}/{Process}", + }); +}; + +export const privateFilesGet2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/p/{Path}/{Name}", + }); +}; + +export const privateFilesGet3 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/p/{Path}/{Name}/{Process}", + }); +}; + +export const privateFilesGet4 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/t/{TenantId}/{Name}", + }); +}; + +export const privateFilesGet5 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/t/{TenantId}/{Name}/{Process}", + }); +}; + +export const privateFilesGet6 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/t/{TenantId}/p/{Path}/{Name}", + }); +}; + +export const privateFilesGet7 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/private/t/{TenantId}/p/{Path}/{Name}/{Process}", + }); +}; + +export const privateFilesGetShareList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/files/private/share", + }, + ); +}; + +export const privateFilesShare = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/files/private/share", + }); +}; + +export const profileGetSessions = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/account/my-profile/sessions", + }); +}; + +export const profileRevokeSession = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/account/my-profile/sessions/{sessionId}/revoke", + }); +}; + +export const profileGetTwoFactorEnabled = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + ProfileGetTwoFactorEnabledResponse, + ProfileGetTwoFactorEnabledError, + ThrowOnError + >({ + ...options, + url: "/api/account/my-profile/two-factor", + }); +}; + +export const profileChangeTwoFactorEnabled = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + ProfileChangeTwoFactorEnabledResponse, + ProfileChangeTwoFactorEnabledError, + ThrowOnError + >({ + ...options, + url: "/api/account/my-profile/change-two-factor", + }); +}; + +export const profileSendChangePhoneNumberCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + ProfileSendChangePhoneNumberCodeResponse, + ProfileSendChangePhoneNumberCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/my-profile/send-phone-number-change-code", + }); +}; + +export const profileChangePhoneNumber = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put( + { + ...options, + url: "/api/account/my-profile/change-phone-number", + }, + ); +}; + +export const profileSendEmailConfirmLink = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + ProfileSendEmailConfirmLinkResponse, + ProfileSendEmailConfirmLinkError, + ThrowOnError + >({ + ...options, + url: "/api/account/my-profile/send-email-confirm-link", + }); +}; + +export const profileConfirmEmail = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/account/my-profile/confirm-email", + }); +}; + +export const profileGetAuthenticator = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/account/my-profile/authenticator", + }); +}; + +export const profileVerifyAuthenticatorCode = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + ProfileVerifyAuthenticatorCodeResponse, + ProfileVerifyAuthenticatorCodeError, + ThrowOnError + >({ + ...options, + url: "/api/account/my-profile/verify-authenticator-code", + }); +}; + +export const profileResetAuthenticator = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + ProfileResetAuthenticatorResponse, + ProfileResetAuthenticatorError, + ThrowOnError + >({ + ...options, + url: "/api/account/my-profile/reset-authenticator", + }); +}; + +export const profileGet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/account/my-profile", + }); +}; + +export const profileUpdate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/account/my-profile", + }); +}; + +export const profileChangePassword = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/account/my-profile/change-password", + }); +}; + +export const publicFilesUpload = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/files/public", + }); +}; + +export const publicFilesDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/files/public", + }); +}; + +export const publicFilesUpload1 = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/files/public/upload", + }); +}; + +export const publicFilesGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/search", + }); +}; + +export const publicFilesGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/{Name}", + }); +}; + +export const publicFilesGet1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/{Name}/{Process}", + }); +}; + +export const publicFilesGet2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/p/{Path}/{Name}", + }); +}; + +export const publicFilesGet3 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/p/{Path}/{Name}/{Process}", + }); +}; + +export const publicFilesGet4 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/t/{TenantId}/{Name}", + }); +}; + +export const publicFilesGet5 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/t/{TenantId}/{Name}/{Process}", + }); +}; + +export const publicFilesGet6 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/t/{TenantId}/p/{Path}/{Name}", + }); +}; + +export const publicFilesGet7 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/public/t/{TenantId}/p/{Path}/{Name}/{Process}", + }); +}; + +export const publishHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{workflowDefinitionId}/publish", + }); +}; + +export const resourceGetByName = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/localization/resources/{name}", + }); +}; + +export const resourceDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/localization/resources/{name}", + }); +}; + +export const resourceUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/localization/resources/{name}", + }); +}; + +export const resourceCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/localization/resources", + }); +}; + +export const resourceGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/abp/localization/resources", + }); +}; + +export const restoreHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/v{apiVersion}/workflow-definitions/restore", + }); +}; + +export const retractHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{workflowDefinitionId}/retract", + }); +}; + +export const retryHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-instances/{id}/retry", + }); +}; + +export const revertHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflow-definitions/{definitionId}/revert/{version}", + }); +}; + +export const roleGetOrganizationUnits = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/identity/roles/{id}/organization-units", + }, + ); +}; + +export const roleSetOrganizationUnits = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put( + { + ...options, + url: "/api/identity/roles/{id}/organization-units", + }, + ); +}; + +export const roleRemoveOrganizationUnits = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + RoleRemoveOrganizationUnitsResponse, + RoleRemoveOrganizationUnitsError, + ThrowOnError + >({ + ...options, + url: "/api/identity/roles/{id}/organization-units/{ouId}", + }); +}; + +export const roleGetClaims = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/roles/{id}/claims", + }); +}; + +export const roleAddClaim = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/identity/roles/{id}/claims", + }); +}; + +export const roleUpdateClaim = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/roles/{id}/claims", + }); +}; + +export const roleDeleteClaim = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/identity/roles/{id}/claims", + }); +}; + +export const roleGetAllList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/roles/all", + }); +}; + +export const roleGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/roles", + }); +}; + +export const roleCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/identity/roles", + }); +}; + +export const roleGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/roles/{id}", + }); +}; + +export const roleUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/roles/{id}", + }); +}; + +export const roleDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/identity/roles/{id}", + }); +}; + +export const roleEntityRuleGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/data-protection-management/entity-rule/roles", + }); +}; + +export const roleEntityRuleCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/data-protection-management/entity-rule/roles", + }); +}; + +export const roleEntityRuleUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/data-protection-management/entity-rule/roles/{id}", + }); +}; + +export const securityLogDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/auditing/security-log/{id}", + }); +}; + +export const securityLogGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/security-log/{id}", + }); +}; + +export const securityLogGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/auditing/security-log", + }); +}; + +export const settingSetCurrentTenant = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/setting-management/settings/change-current-tenant", + }); +}; + +export const settingSetGlobal = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/setting-management/settings/change-global", + }); +}; + +export const settingGetAllForGlobal = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/setting-management/settings/by-global", + }); +}; + +export const settingGetAllForCurrentTenant = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + SettingGetAllForCurrentTenantResponse, + SettingGetAllForCurrentTenantError, + ThrowOnError + >({ + ...options, + url: "/api/setting-management/settings/by-current-tenant", + }); +}; + +export const settingSendTestEmail = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/setting-management/settings/send-test-email", + }); +}; + +export const settingDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/setting-management/settings/definitions", + }); +}; + +export const settingDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/setting-management/settings/definitions", + }, + ); +}; + +export const settingDefinitionDeleteOrRestore = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + SettingDefinitionDeleteOrRestoreResponse, + SettingDefinitionDeleteOrRestoreError, + ThrowOnError + >({ + ...options, + url: "/api/setting-management/settings/definitions/{name}", + }); +}; + +export const settingDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/setting-management/settings/definitions/{name}", + }); +}; + +export const settingDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/setting-management/settings/definitions/{name}", + }); +}; + +export const staticFilesUpload = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + ...formDataBodySerializer, + headers: { + "Content-Type": null, + ...options?.headers, + }, + url: "/api/files/static", + }); +}; + +export const staticFilesGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/{Bucket}/{Name}", + }); +}; + +export const staticFilesGet1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/{Bucket}/{Name}/{Process}", + }); +}; + +export const staticFilesGet2 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/{Bucket}/p/{Path}/{Name}", + }); +}; + +export const staticFilesGet3 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/{Bucket}/p/{Path}/{Name}/{Process}", + }); +}; + +export const staticFilesGet4 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/t/{TenantId}/{Bucket}/{Name}", + }); +}; + +export const staticFilesGet5 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/t/{TenantId}/{Bucket}/{Name}/{Process}", + }); +}; + +export const staticFilesGet6 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/t/{TenantId}/{Bucket}/p/{Path}/{Name}", + }); +}; + +export const staticFilesGet7 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/files/static/t/{TenantId}/{Bucket}/p/{Path}/{Name}/{Process}", + }); +}; + +export const tenantGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/saas/tenants/{id}", + }); +}; + +export const tenantUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/saas/tenants/{id}", + }); +}; + +export const tenantDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/saas/tenants/{id}", + }); +}; + +export const tenantGet1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/saas/tenants/by-name/{name}", + }); +}; + +export const tenantGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/saas/tenants", + }); +}; + +export const tenantCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/saas/tenants", + }); +}; + +export const tenantGetConnectionString = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + TenantGetConnectionStringResponse, + TenantGetConnectionStringError, + ThrowOnError + >({ + ...options, + url: "/api/saas/tenants/{id}/connection-string/{name}", + }); +}; + +export const tenantDeleteConnectionString = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + TenantDeleteConnectionStringResponse, + TenantDeleteConnectionStringError, + ThrowOnError + >({ + ...options, + url: "/api/saas/tenants/{id}/connection-string/{name}", + }); +}; + +export const tenantGetConnectionString1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + TenantGetConnectionString1Response, + TenantGetConnectionString1Error, + ThrowOnError + >({ + ...options, + url: "/api/saas/tenants/{id}/connection-string", + }); +}; + +export const tenantSetConnectionString = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + TenantSetConnectionStringResponse, + TenantSetConnectionStringError, + ThrowOnError + >({ + ...options, + url: "/api/saas/tenants/{id}/connection-string", + }); +}; + +export const textSetText = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/localization/texts", + }); +}; + +export const textRestoreToDefault = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/localization/texts/restore-to-default", + }); +}; + +export const textGetByCultureKey = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/abp/localization/texts/by-culture-key", + }); +}; + +export const textGetList = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/abp/localization/texts", + }); +}; + +export const textTemplateContentGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/text-templating/templates/content/{Name}", + }); +}; + +export const textTemplateContentGet1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/text-templating/templates/content/{Culture}/{Name}", + }); +}; + +export const textTemplateContentRestoreToDefault = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + TextTemplateContentRestoreToDefaultResponse, + TextTemplateContentRestoreToDefaultError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/templates/content/{name}/restore-to-default", + }); +}; + +export const textTemplateContentUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + TextTemplateContentUpdateResponse, + TextTemplateContentUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/templates/content/{name}", + }); +}; + +export const textTemplateDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + TextTemplateDefinitionCreateResponse, + TextTemplateDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/template/definitions", + }); +}; + +export const textTemplateDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + TextTemplateDefinitionGetListResponse, + TextTemplateDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/template/definitions", + }); +}; + +export const textTemplateDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + TextTemplateDefinitionDeleteResponse, + TextTemplateDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/template/definitions/{name}", + }); +}; + +export const textTemplateDefinitionGetByName = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + TextTemplateDefinitionGetByNameResponse, + TextTemplateDefinitionGetByNameError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/template/definitions/{name}", + }); +}; + +export const textTemplateDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + TextTemplateDefinitionUpdateResponse, + TextTemplateDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/text-templating/template/definitions/{name}", + }); +}; + +export const themeSettingGet = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/theme/vue-vben-admin", + }); +}; + +export const themeSettingChange = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/theme/vue-vben-admin/change", + }); +}; + +export const triggerHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/v{apiVersion}/workflows/trigger", + }); +}; + +export const triggerEndpointHandle = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/signals/trigger/{token}", + }); +}; + +export const triggerEndpointHandle1 = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/signals/trigger/{token}", + }); +}; + +export const userGetOrganizationUnits = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/identity/users/{id}/organization-units", + }, + ); +}; + +export const userSetOrganizationUnits = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put( + { + ...options, + url: "/api/identity/users/{id}/organization-units", + }, + ); +}; + +export const userRemoveOrganizationUnits = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + UserRemoveOrganizationUnitsResponse, + UserRemoveOrganizationUnitsError, + ThrowOnError + >({ + ...options, + url: "/api/identity/users/{id}/organization-units/{ouId}", + }); +}; + +export const userGetClaims = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/{id}/claims", + }); +}; + +export const userAddClaim = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/identity/users/{id}/claims", + }); +}; + +export const userUpdateClaim = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/users/{id}/claims", + }); +}; + +export const userDeleteClaim = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/identity/users/{id}/claims", + }); +}; + +export const userChangePassword = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/users/change-password", + }); +}; + +export const userChangeTwoFactorEnabled = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + UserChangeTwoFactorEnabledResponse, + UserChangeTwoFactorEnabledError, + ThrowOnError + >({ + ...options, + url: "/api/identity/users/change-two-factor", + }); +}; + +export const userLock = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/users/{id}/lock/{seconds}", + }); +}; + +export const userUnLock = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/users/{id}/unlock", + }); +}; + +export const userGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/{id}", + }); +}; + +export const userUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/users/{id}", + }); +}; + +export const userDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/identity/users/{id}", + }); +}; + +export const userGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users", + }); +}; + +export const userCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/identity/users", + }); +}; + +export const userGetRoles = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/{id}/roles", + }); +}; + +export const userUpdateRoles = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/identity/users/{id}/roles", + }); +}; + +export const userGetAssignableRoles = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/assignable-roles", + }); +}; + +export const userFindByUsername = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/by-username/{userName}", + }); +}; + +export const userFindByEmail = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/by-email/{email}", + }); +}; + +export const userFavoriteMenuCreate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/platform/menus/favorites/{userId}", + }); +}; + +export const userFavoriteMenuGetList = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/platform/menus/favorites/{userId}", + }); +}; + +export const userFavoriteMenuUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/platform/menus/favorites/{userId}", + }); +}; + +export const userFavoriteMenuCreateMyFavoriteMenu = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + UserFavoriteMenuCreateMyFavoriteMenuResponse, + UserFavoriteMenuCreateMyFavoriteMenuError, + ThrowOnError + >({ + ...options, + url: "/api/platform/menus/favorites/my-favorite-menus", + }); +}; + +export const userFavoriteMenuGetMyFavoriteMenuList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + UserFavoriteMenuGetMyFavoriteMenuListResponse, + UserFavoriteMenuGetMyFavoriteMenuListError, + ThrowOnError + >({ + ...options, + url: "/api/platform/menus/favorites/my-favorite-menus", + }); +}; + +export const userFavoriteMenuUpdateMyFavoriteMenu = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + UserFavoriteMenuUpdateMyFavoriteMenuResponse, + UserFavoriteMenuUpdateMyFavoriteMenuError, + ThrowOnError + >({ + ...options, + url: "/api/platform/menus/favorites/my-favorite-menus", + }); +}; + +export const userFavoriteMenuDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete({ + ...options, + url: "/api/platform/menus/favorites/{userId}/{MenuId}", + }); +}; + +export const userFavoriteMenuDeleteMyFavoriteMenu = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + UserFavoriteMenuDeleteMyFavoriteMenuResponse, + UserFavoriteMenuDeleteMyFavoriteMenuError, + ThrowOnError + >({ + ...options, + url: "/api/platform/menus/favorites/my-favorite-menus/{MenuId}", + }); +}; + +export const userGroupApplyJoinGroup = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/im/user-groups/join", + }); +}; + +export const userGroupGetGroupUsers = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/user-groups", + }); +}; + +export const userGroupGetMyGroups = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/im/user-groups/me", + }); +}; + +export const userGroupGroupAcceptUser = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put( + { + ...options, + url: "/api/im/user-groups/accept", + }, + ); +}; + +export const userGroupGroupRemoveUser = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put( + { + ...options, + url: "/api/im/user-groups/remove", + }, + ); +}; + +export const userLookupFindById = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/lookup/{id}", + }); +}; + +export const userLookupFindByUserName = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/identity/users/lookup/by-username/{userName}", + }, + ); +}; + +export const userLookupSearch = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/lookup/search", + }); +}; + +export const userLookupGetCount = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/identity/users/lookup/count", + }); +}; + +export const userSettingGetAllForCurrentUser = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + UserSettingGetAllForCurrentUserResponse, + UserSettingGetAllForCurrentUserError, + ThrowOnError + >({ + ...options, + url: "/api/setting-management/settings/by-current-user", + }); +}; + +export const userSettingSetCurrentUser = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + UserSettingSetCurrentUserResponse, + UserSettingSetCurrentUserError, + ThrowOnError + >({ + ...options, + url: "/api/setting-management/settings/change-current-user", + }); +}; + +export const webhookDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/webhooks/definitions", + }); +}; + +export const webhookDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/webhooks/definitions", + }, + ); +}; + +export const webhookDefinitionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + WebhookDefinitionDeleteResponse, + WebhookDefinitionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/definitions/{name}", + }); +}; + +export const webhookDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/webhooks/definitions/{name}", + }); +}; + +export const webhookDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put({ + ...options, + url: "/api/webhooks/definitions/{name}", + }); +}; + +export const webhookGroupDefinitionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + WebhookGroupDefinitionCreateResponse, + WebhookGroupDefinitionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/definitions/groups", + }); +}; + +export const webhookGroupDefinitionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + WebhookGroupDefinitionGetListResponse, + WebhookGroupDefinitionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/definitions/groups", + }); +}; + +export const webhookGroupDefinitionDeleteAysnc = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + WebhookGroupDefinitionDeleteAysncResponse, + WebhookGroupDefinitionDeleteAysncError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/definitions/groups/{name}", + }); +}; + +export const webhookGroupDefinitionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + WebhookGroupDefinitionGetResponse, + WebhookGroupDefinitionGetError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/definitions/groups/{name}", + }); +}; + +export const webhookGroupDefinitionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + WebhookGroupDefinitionUpdateResponse, + WebhookGroupDefinitionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/definitions/groups/{name}", + }); +}; + +export const webhookPublishPublish = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/webhooks/publish", + }); +}; + +export const webhookSendRecordGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/webhooks/send-attempts/{id}", + }); +}; + +export const webhookSendRecordDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + WebhookSendRecordDeleteResponse, + WebhookSendRecordDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/send-attempts/{id}", + }); +}; + +export const webhookSendRecordDeleteMany = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + WebhookSendRecordDeleteManyResponse, + WebhookSendRecordDeleteManyError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/send-attempts/delete-many", + }); +}; + +export const webhookSendRecordGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get( + { + ...options, + url: "/api/webhooks/send-attempts", + }, + ); +}; + +export const webhookSendRecordResend = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).post({ + ...options, + url: "/api/webhooks/send-attempts/{id}/resend", + }); +}; + +export const webhookSendRecordResendMany = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + WebhookSendRecordResendManyResponse, + WebhookSendRecordResendManyError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/send-attempts/resend-many", + }); +}; + +export const webhookSubscriptionCreate = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).post< + WebhookSubscriptionCreateResponse, + WebhookSubscriptionCreateError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/subscriptions", + }); +}; + +export const webhookSubscriptionGetList = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + WebhookSubscriptionGetListResponse, + WebhookSubscriptionGetListError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/subscriptions", + }); +}; + +export const webhookSubscriptionDelete = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + WebhookSubscriptionDeleteResponse, + WebhookSubscriptionDeleteError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/subscriptions/{id}", + }); +}; + +export const webhookSubscriptionGet = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).get({ + ...options, + url: "/api/webhooks/subscriptions/{id}", + }); +}; + +export const webhookSubscriptionUpdate = ( + options: OptionsLegacyParser, +) => { + return (options?.client ?? client).put< + WebhookSubscriptionUpdateResponse, + WebhookSubscriptionUpdateError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/subscriptions/{id}", + }); +}; + +export const webhookSubscriptionDeleteMany = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).delete< + WebhookSubscriptionDeleteManyResponse, + WebhookSubscriptionDeleteManyError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/subscriptions/delete-many", + }); +}; + +export const webhookSubscriptionGetAllAvailableWebhooks = ( + options?: OptionsLegacyParser, +) => { + return (options?.client ?? client).get< + WebhookSubscriptionGetAllAvailableWebhooksResponse, + WebhookSubscriptionGetAllAvailableWebhooksError, + ThrowOnError + >({ + ...options, + url: "/api/webhooks/subscriptions/availables", + }); +}; diff --git a/apps/react-admin/src/api/gen/types.gen.ts b/apps/react-admin/src/api/gen/types.gen.ts new file mode 100644 index 000000000..9ee442ddb --- /dev/null +++ b/apps/react-admin/src/api/gen/types.gen.ts @@ -0,0 +1,13569 @@ +// This file is auto-generated by @hey-api/openapi-ts + +export type AbpLoginResult = { + result?: LoginResultType; + readonly description?: string | null; +}; + +export type ActionApiDescriptionModel = { + uniqueName?: string | null; + name?: string | null; + httpMethod?: string | null; + url?: string | null; + supportedVersions?: Array | null; + parametersOnMethod?: Array | null; + parameters?: Array | null; + returnValue?: ReturnValueApiDescriptionModel; + allowAnonymous?: boolean | null; + implementFrom?: string | null; +}; + +export type ActivityBlueprintModel = { + id?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + type?: string | null; + parentId?: string | null; + persistWorkflow?: boolean; + loadWorkflowContext?: boolean; + saveWorkflowContext?: boolean; + inputProperties?: Variables; + outputProperties?: Variables; + x?: number | null; + y?: number | null; +}; + +export type ActivityDefinition = { + activityId?: string | null; + type?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + x?: number | null; + y?: number | null; + persistWorkflow?: boolean; + loadWorkflowContext?: boolean; + saveWorkflowContext?: boolean; + properties?: Array | null; + propertyStorageProviders?: { + [key: string]: string; + } | null; +}; + +export type ActivityDefinitionProperty = { + name?: string | null; + syntax?: string | null; + expressions?: { + [key: string]: string; + } | null; +}; + +export type ActivityDescriptor = { + type?: string | null; + displayName?: string | null; + description?: string | null; + category?: string | null; + traits?: ActivityTraits; + outcomes?: Array | null; + /** + * @deprecated + */ + properties?: Array | null; + inputProperties?: Array | null; + outputProperties?: Array | null; + customAttributes?: { + [key: string]: unknown; + } | null; +}; + +export type ActivityEventCount = { + eventName?: string | null; + count?: number; +}; + +export type ActivityFault = { + message?: string | null; +}; + +export type ActivityInputDescriptor = { + name?: string | null; + type?: Type; + uiHint?: string | null; + label?: string | null; + hint?: string | null; + options?: unknown; + category?: string | null; + order?: number; + defaultValue?: unknown; + defaultSyntax?: string | null; + supportedSyntaxes?: Array | null; + isReadOnly?: boolean | null; + isBrowsable?: boolean | null; + isDesignerCritical?: boolean; + defaultWorkflowStorageProvider?: string | null; + disableWorkflowProviderSelection?: boolean; + considerValuesAsOutcomes?: boolean; +}; + +export type ActivityOutputDescriptor = { + name?: string | null; + type?: Type; + hint?: string | null; + isBrowsable?: boolean | null; + defaultWorkflowStorageProvider?: string | null; + disableWorkflowProviderSelection?: boolean; +}; + +export type ActivityScope = { + activityId?: string | null; + variables?: Variables; +}; + +export type ActivityStats = { + eventCounts?: Array | null; + fault?: ActivityFault; + averageExecutionTime?: Duration; + fastestExecutionTime?: Duration; + slowestExecutionTime?: Duration; + lastExecutedAt?: Instant; +}; + +export enum ActivityTraits { + Action = 1, + Trigger = 2, + Job = 4, +} + +export type ApiVersion = { + groupVersion?: string | null; + readonly majorVersion?: number | null; + readonly minorVersion?: number | null; + readonly status?: string | null; +}; + +export type ApplicationApiDescriptionModel = { + modules?: { + [key: string]: ModuleApiDescriptionModel; + } | null; + types?: { + [key: string]: TypeApiDescriptionModel; + } | null; +}; + +export type ApplicationAuthConfigurationDto = { + grantedPolicies?: { + [key: string]: boolean; + } | null; +}; + +export type ApplicationConfigurationDto = { + localization?: ApplicationLocalizationConfigurationDto; + auth?: ApplicationAuthConfigurationDto; + setting?: ApplicationSettingConfigurationDto; + currentUser?: CurrentUserDto; + features?: ApplicationFeatureConfigurationDto; + globalFeatures?: ApplicationGlobalFeatureConfigurationDto; + multiTenancy?: MultiTenancyInfoDto; + currentTenant?: CurrentTenantDto; + timing?: TimingDto; + clock?: ClockDto; + objectExtensions?: ObjectExtensionsDto; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type ApplicationFeatureConfigurationDto = { + values?: { + [key: string]: string | null; + } | null; +}; + +export type ApplicationGlobalFeatureConfigurationDto = { + enabledFeatures?: Array | null; +}; + +export type ApplicationLocalizationConfigurationDto = { + values?: { + [key: string]: { + [key: string]: string; + }; + } | null; + resources?: { + [key: string]: ApplicationLocalizationResourceDto; + } | null; + languages?: Array | null; + currentCulture?: CurrentCultureDto; + defaultResourceName?: string | null; + languagesMap?: { + [key: string]: Array; + } | null; + languageFilesMap?: { + [key: string]: Array; + } | null; +}; + +export type ApplicationLocalizationDto = { + resources?: { + [key: string]: ApplicationLocalizationResourceDto; + } | null; + currentCulture?: CurrentCultureDto; +}; + +export type ApplicationLocalizationResourceDto = { + texts?: { + [key: string]: string; + } | null; + baseResources?: Array | null; +}; + +export type ApplicationSettingConfigurationDto = { + values?: { + [key: string]: string | null; + } | null; +}; + +export type Assembly = { + readonly definedTypes?: Array | null; + readonly exportedTypes?: Array | null; + /** + * @deprecated + */ + readonly codeBase?: string | null; + entryPoint?: MethodInfo; + readonly fullName?: string | null; + readonly imageRuntimeVersion?: string | null; + readonly isDynamic?: boolean; + readonly location?: string | null; + readonly reflectionOnly?: boolean; + readonly isCollectible?: boolean; + readonly isFullyTrusted?: boolean; + readonly customAttributes?: Array | null; + /** + * @deprecated + */ + readonly escapedCodeBase?: string | null; + manifestModule?: Module; + readonly modules?: Array | null; + /** + * @deprecated + */ + readonly globalAssemblyCache?: boolean; + readonly hostContext?: number; + securityRuleSet?: SecurityRuleSet; +}; + +export type AuditLogActionDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + serviceName?: string | null; + methodName?: string | null; + parameters?: string | null; + executionTime?: string; + executionDuration?: number; +}; + +export type AuditLogDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + applicationName?: string | null; + userId?: string | null; + userName?: string | null; + tenantId?: string | null; + tenantName?: string | null; + impersonatorUserId?: string | null; + impersonatorTenantId?: string | null; + executionTime?: string; + executionDuration?: number; + clientIpAddress?: string | null; + clientName?: string | null; + clientId?: string | null; + correlationId?: string | null; + browserInfo?: string | null; + httpMethod?: string | null; + url?: string | null; + exceptions?: string | null; + comments?: string | null; + httpStatusCode?: number | null; + entityChanges?: Array | null; + actions?: Array | null; +}; + +export type AuthenticatorDto = { + isAuthenticated?: boolean; + sharedKey?: string | null; + authenticatorUri?: string | null; +}; + +export type AuthenticatorRecoveryCodeDto = { + recoveryCodes?: Array | null; +}; + +export type BackgroundJobActionCreateDto = { + isEnabled?: boolean; + paramters?: { + [key: string]: unknown; + } | null; + name: string; +}; + +export type BackgroundJobActionDefinitionDto = { + name?: string | null; + type?: JobActionType; + displayName?: string | null; + description?: string | null; + paramters?: Array | null; +}; + +export type BackgroundJobActionDto = { + id?: string; + jobId?: string | null; + name?: string | null; + isEnabled?: boolean; + paramters?: { + [key: string]: unknown; + } | null; +}; + +export type BackgroundJobActionParamterDto = { + name?: string | null; + required?: boolean; + displayName?: string | null; + description?: string | null; +}; + +export type BackgroundJobActionUpdateDto = { + isEnabled?: boolean; + paramters?: { + [key: string]: unknown; + } | null; +}; + +export type BackgroundJobDefinitionDto = { + name?: string | null; + displayName?: string | null; + description?: string | null; + paramters?: Array | null; +}; + +export type BackgroundJobInfoBatchInput = { + jobIds?: Array | null; +}; + +export type BackgroundJobInfoCreateDto = { + isEnabled?: boolean; + args?: { + [key: string]: unknown; + } | null; + description?: string | null; + jobType?: JobType; + cron?: string | null; + maxTryCount?: number; + maxCount?: number; + interval?: number; + priority?: JobPriority; + lockTimeOut?: number; + name: string; + group: string; + type: string; + nodeName?: string | null; + beginTime: string; + endTime?: string | null; + source?: JobSource; +}; + +export type BackgroundJobInfoDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string | null; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + concurrencyStamp?: string | null; + name?: string | null; + group?: string | null; + type?: string | null; + result?: string | null; + args?: { + [key: string]: unknown; + } | null; + status?: JobStatus; + description?: string | null; + beginTime?: string; + endTime?: string | null; + lastRunTime?: string | null; + nextRunTime?: string | null; + jobType?: JobType; + cron?: string | null; + triggerCount?: number; + tryCount?: number; + maxTryCount?: number; + maxCount?: number; + isAbandoned?: boolean; + isEnabled?: boolean; + interval?: number; + priority?: JobPriority; + source?: JobSource; + lockTimeOut?: number; +}; + +export type BackgroundJobInfoUpdateDto = { + isEnabled?: boolean; + args?: { + [key: string]: unknown; + } | null; + description?: string | null; + jobType?: JobType; + cron?: string | null; + maxTryCount?: number; + maxCount?: number; + interval?: number; + priority?: JobPriority; + lockTimeOut?: number; + concurrencyStamp?: string | null; +}; + +export type BackgroundJobLogDto = { + id?: number; + jobName?: string | null; + jobGroup?: string | null; + jobType?: string | null; + message?: string | null; + runTime?: string; + exception?: string | null; +}; + +export type BackgroundJobParamterDto = { + name?: string | null; + required?: boolean; + displayName?: string | null; + description?: string | null; +}; + +export type BeforeMiniStateDto = { + menuCollapsed?: boolean | null; + menuSplit?: boolean | null; + menuMode?: string | null; + menuType?: string | null; +}; + +export type BlockingActivity = { + activityId?: string | null; + activityType?: string | null; + tag?: string | null; +}; + +export type BulkCancelWorkflowsRequest = { + workflowInstanceIds?: Array | null; +}; + +export type BulkDeleteOssObjectInput = { + bucket: string; + path?: string | null; + objects: Array; +}; + +export type BulkDeleteWorkflowsRequest = { + workflowInstanceIds?: Array | null; +}; + +export type BulkRetryWorkflowsRequest = { + workflowInstanceIds?: Array | null; +}; + +export type CacheKeysDto = { + nextMarker?: string | null; + keys?: Array | null; +}; + +export type CacheRefreshInput = { + key: string; + absoluteExpiration?: string | null; + slidingExpiration?: string | null; +}; + +export type CacheSetInput = { + key: string; + value?: string | null; + absoluteExpiration?: string | null; + slidingExpiration?: string | null; +}; + +export type CacheValueDto = { + type?: string | null; + size?: number; + expiration?: string | null; + values?: { + [key: string]: unknown; + } | null; +}; + +export enum CallingConventions { + Standard = 1, + VarArgs = 2, + Any = 3, + HasThis = 32, + ExplicitThis = 64, +} + +export type ChangeAvatarInput = { + avatarUrl?: string | null; +}; + +export type ChangePasswordInput = { + currentPassword?: string | null; + newPassword: string; +}; + +export type ChangePhoneNumberInput = { + newPhoneNumber: string; + code: string; +}; + +export type ChatMessage = { + tenantId?: string | null; + groupId?: string | null; + messageId?: string | null; + formUserId?: string; + formUserName?: string | null; + toUserId?: string | null; + content?: string | null; + sendTime?: string; + isAnonymous?: boolean; + messageType?: MessageType; + source?: MessageSourceType; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type ChatMessageSendResultDto = { + messageId?: string | null; +}; + +export type ClockDto = { + kind?: string | null; +}; + +export type CollectedWorkflow = { + workflowInstanceId?: string | null; + workflowInstance?: WorkflowInstance; + activityId?: string | null; +}; + +export type ConfirmEmailInput = { + confirmToken: string; +}; + +export type ConnectionDefinition = { + sourceActivityId?: string | null; + targetActivityId?: string | null; + outcome?: string | null; +}; + +export type ConnectionModel = { + sourceActivityId?: string | null; + targetActivityId?: string | null; + outcome?: string | null; +}; + +export type ConstructorInfo = { + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + attributes?: MethodAttributes; + methodImplementationFlags?: MethodImplAttributes; + callingConvention?: CallingConventions; + readonly isAbstract?: boolean; + readonly isConstructor?: boolean; + readonly isFinal?: boolean; + readonly isHideBySig?: boolean; + readonly isSpecialName?: boolean; + readonly isStatic?: boolean; + readonly isVirtual?: boolean; + readonly isAssembly?: boolean; + readonly isFamily?: boolean; + readonly isFamilyAndAssembly?: boolean; + readonly isFamilyOrAssembly?: boolean; + readonly isPrivate?: boolean; + readonly isPublic?: boolean; + readonly isConstructedGenericMethod?: boolean; + readonly isGenericMethod?: boolean; + readonly isGenericMethodDefinition?: boolean; + readonly containsGenericParameters?: boolean; + methodHandle?: RuntimeMethodHandle; + readonly isSecurityCritical?: boolean; + readonly isSecuritySafeCritical?: boolean; + readonly isSecurityTransparent?: boolean; + memberType?: MemberTypes; +}; + +export type ControllerApiDescriptionModel = { + controllerName?: string | null; + controllerGroupName?: string | null; + isRemoteService?: boolean; + isIntegrationService?: boolean; + apiVersion?: string | null; + type?: string | null; + interfaces?: Array | null; + actions?: { + [key: string]: ActionApiDescriptionModel; + } | null; +}; + +export type ControllerInterfaceApiDescriptionModel = { + type?: string | null; + name?: string | null; + methods?: Array | null; +}; + +export type CurrentCultureDto = { + displayName?: string | null; + englishName?: string | null; + threeLetterIsoLanguageName?: string | null; + twoLetterIsoLanguageName?: string | null; + isRightToLeft?: boolean; + cultureName?: string | null; + name?: string | null; + nativeName?: string | null; + dateTimeFormat?: DateTimeFormatDto; +}; + +export type CurrentTenantDto = { + id?: string | null; + name?: string | null; + isAvailable?: boolean; +}; + +export type CurrentUserDto = { + isAuthenticated?: boolean; + id?: string | null; + tenantId?: string | null; + impersonatorUserId?: string | null; + impersonatorTenantId?: string | null; + impersonatorUserName?: string | null; + impersonatorTenantName?: string | null; + userName?: string | null; + name?: string | null; + surName?: string | null; + email?: string | null; + emailVerified?: boolean; + phoneNumber?: string | null; + phoneNumberVerified?: boolean; + roles?: Array | null; + sessionId?: string | null; +}; + +export type CustomAttributeData = { + attributeType?: Type; + constructor?: ConstructorInfo; + readonly constructorArguments?: Array | null; + readonly namedArguments?: Array | null; +}; + +export type CustomAttributeNamedArgument = { + memberInfo?: MemberInfo; + typedValue?: CustomAttributeTypedArgument; + readonly memberName?: string | null; + readonly isField?: boolean; +}; + +export type CustomAttributeTypedArgument = { + argumentType?: Type; + value?: unknown; +}; + +export type DataAccessFilterGroup = { + groups?: Array | null; + rules?: Array | null; + logic?: DataAccessFilterLogic; +}; + +export enum DataAccessFilterLogic { + And = 0, + Or = 1, +} + +export enum DataAccessFilterOperate { + Equal = 1, + NotEqual = 2, + Less = 3, + LessOrEqual = 4, + Greater = 5, + GreaterOrEqual = 6, + StartsWith = 7, + EndsWith = 8, + Contains = 9, + NotContains = 10, +} + +export type DataAccessFilterRule = { + field?: string | null; + value?: unknown; + operate?: DataAccessFilterOperate; + isLeft?: boolean; +}; + +export enum DataAccessOperation { + Read = 0, + Write = 1, + Delete = 2, +} + +export type DataCreateDto = { + name: string; + displayName: string; + description?: string | null; + parentId?: string | null; +}; + +export type DataDto = { + id?: string; + name?: string | null; + code?: string | null; + displayName?: string | null; + description?: string | null; + parentId?: string | null; + items?: Array | null; +}; + +export type DataItemCreateDto = { + displayName: string; + defaultValue?: string | null; + description?: string | null; + allowBeNull?: boolean; + valueType?: ValueType; + name: string; +}; + +export type DataItemDto = { + id?: string; + name?: string | null; + displayName?: string | null; + defaultValue?: string | null; + description?: string | null; + allowBeNull?: boolean; + valueType?: ValueType; +}; + +export type DataItemUpdateDto = { + displayName: string; + defaultValue?: string | null; + description?: string | null; + allowBeNull?: boolean; + valueType?: ValueType; +}; + +export type DataMoveDto = { + parentId?: string | null; +}; + +export type DataUpdateDto = { + name: string; + displayName: string; + description?: string | null; +}; + +export type DateTimeFormatDto = { + calendarAlgorithmType?: string | null; + dateTimeFormatLong?: string | null; + shortDatePattern?: string | null; + fullDateTimePattern?: string | null; + dateSeparator?: string | null; + shortTimePattern?: string | null; + longTimePattern?: string | null; +}; + +export type DispatchSignalRequest = { + workflowInstanceId?: string | null; + correlationId?: string | null; + input?: unknown; +}; + +export type DispatchSignalResponse = { + startedWorkflows?: Array | null; +}; + +export type DispatchWorkflowDefinitionRequestModel = { + activityId?: string | null; + correlationId?: string | null; + contextId?: string | null; + input?: unknown; +}; + +export type DispatchWorkflowDefinitionResponseModel = { + workflowInstanceId?: string | null; + activityId?: string | null; +}; + +export type DispatchWorkflowInstanceRequestModel = { + activityId?: string | null; + input?: WorkflowInput; +}; + +export type DispatchWorkflowInstanceResponseModel = { + [key: string]: unknown; +}; + +export type Duration = { + readonly days?: number; + readonly nanosecondOfDay?: number; + readonly hours?: number; + readonly minutes?: number; + readonly seconds?: number; + readonly milliseconds?: number; + readonly subsecondTicks?: number; + readonly subsecondNanoseconds?: number; + readonly bclCompatibleTicks?: number; + readonly totalDays?: number; + readonly totalHours?: number; + readonly totalMinutes?: number; + readonly totalSeconds?: number; + readonly totalMilliseconds?: number; + readonly totalTicks?: number; + readonly totalNanoseconds?: number; +}; + +export enum DynamicComparison { + Equal = 0, + NotEqual = 1, + LessThan = 2, + LessThanOrEqual = 3, + GreaterThan = 4, + GreaterThanOrEqual = 5, + StartsWith = 6, + NotStartsWith = 7, + EndsWith = 8, + NotEndsWith = 9, + Contains = 10, + NotContains = 11, + Null = 12, + NotNull = 13, +} + +export enum DynamicLogic { + And = 0, + Or = 1, +} + +export type DynamicParamter = { + field: string; + logic?: DynamicLogic; + comparison?: DynamicComparison; + value?: unknown; + type?: string | null; +}; + +export type DynamicParamterDto = { + name?: string | null; + description?: string | null; + type?: string | null; + javaScriptType?: string | null; + availableComparator?: Array | null; + options?: Array | null; +}; + +export type DynamicQueryable = { + paramters?: Array | null; +}; + +export type EditionCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + displayName: string; +}; + +export type EditionDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + displayName?: string | null; + concurrencyStamp?: string | null; +}; + +export type EditionUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + displayName: string; + concurrencyStamp?: string | null; +}; + +export type EntityChangeDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + changeTime?: string; + changeType?: EntityChangeType; + entityTenantId?: string | null; + entityId?: string | null; + entityTypeFullName?: string | null; + propertyChanges?: Array | null; +}; + +export enum EntityChangeType { + Created = 0, + Updated = 1, + Deleted = 2, +} + +export type EntityChangeWithUsernameDto = { + entityChange?: EntityChangeDto; + userName?: string | null; +}; + +export type EntityExtensionDto = { + properties?: { + [key: string]: ExtensionPropertyDto; + } | null; + configuration?: { + [key: string]: unknown; + } | null; +}; + +export type EntityPropertyChangeDto = { + id?: string; + newValue?: string | null; + originalValue?: string | null; + propertyName?: string | null; + propertyTypeFullName?: string | null; +}; + +export type EntityPropertyInfoDto = { + id?: string; + name?: string | null; + displayName?: string | null; + typeFullName?: string | null; + valueRange?: Array | null; +}; + +export type EntityTypeInfoDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + name?: string | null; + displayName?: string | null; + typeFullName?: string | null; + isAuditEnabled?: boolean; + properties?: Array | null; +}; + +export enum EventAttributes { + None = 0, + SpecialName = 512, + RTSpecialName = 1024, +} + +export type EventInfo = { + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + memberType?: MemberTypes; + attributes?: EventAttributes; + readonly isSpecialName?: boolean; + addMethod?: MethodInfo; + removeMethod?: MethodInfo; + raiseMethod?: MethodInfo; + readonly isMulticast?: boolean; + eventHandlerType?: Type; +}; + +export type ExecuteSignalRequest = { + workflowInstanceId?: string | null; + correlationId?: string | null; + input?: unknown; +}; + +export type ExecuteSignalResponse = { + startedWorkflows?: Array | null; +}; + +export type ExecuteWorkflowDefinitionRequestModel = { + activityId?: string | null; + correlationId?: string | null; + contextId?: string | null; + input?: unknown; +}; + +export type ExecuteWorkflowDefinitionResponseModel = { + executed?: boolean; + activityId?: string | null; + workflowInstance?: WorkflowInstance; +}; + +export type ExecuteWorkflowInstanceRequest = { + workflowInstanceId?: string | null; + activityId?: string | null; + input?: WorkflowInput; +}; + +export type ExecuteWorkflowInstanceResponseModel = { + executed?: boolean; + activityId?: string | null; + workflowInstance?: WorkflowInstance; +}; + +export type ExtensionEnumDto = { + fields?: Array | null; + localizationResource?: string | null; +}; + +export type ExtensionEnumFieldDto = { + name?: string | null; + value?: unknown; +}; + +export type ExtensionPropertyApiCreateDto = { + isAvailable?: boolean; +}; + +export type ExtensionPropertyApiDto = { + onGet?: ExtensionPropertyApiGetDto; + onCreate?: ExtensionPropertyApiCreateDto; + onUpdate?: ExtensionPropertyApiUpdateDto; +}; + +export type ExtensionPropertyApiGetDto = { + isAvailable?: boolean; +}; + +export type ExtensionPropertyApiUpdateDto = { + isAvailable?: boolean; +}; + +export type ExtensionPropertyAttributeDto = { + typeSimple?: string | null; + config?: { + [key: string]: unknown; + } | null; +}; + +export type ExtensionPropertyDto = { + type?: string | null; + typeSimple?: string | null; + displayName?: LocalizableStringDto; + api?: ExtensionPropertyApiDto; + ui?: ExtensionPropertyUiDto; + attributes?: Array | null; + configuration?: { + [key: string]: unknown; + } | null; + defaultValue?: unknown; +}; + +export type ExtensionPropertyUiDto = { + onTable?: ExtensionPropertyUiTableDto; + onCreateForm?: ExtensionPropertyUiFormDto; + onEditForm?: ExtensionPropertyUiFormDto; + lookup?: ExtensionPropertyUiLookupDto; +}; + +export type ExtensionPropertyUiFormDto = { + isVisible?: boolean; +}; + +export type ExtensionPropertyUiLookupDto = { + url?: string | null; + resultListPropertyName?: string | null; + displayPropertyName?: string | null; + valuePropertyName?: string | null; + filterParamName?: string | null; +}; + +export type ExtensionPropertyUiTableDto = { + isVisible?: boolean; +}; + +export type FeatureDefinitionCreateDto = { + displayName: string; + parentName?: string | null; + description?: string | null; + defaultValue?: string | null; + isVisibleToClients?: boolean; + isAvailableToHost?: boolean; + allowedProviders?: Array | null; + valueType: string; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + groupName: string; +}; + +export type FeatureDefinitionDto = { + groupName?: string | null; + name?: string | null; + parentName?: string | null; + displayName?: string | null; + description?: string | null; + defaultValue?: string | null; + isVisibleToClients?: boolean; + isAvailableToHost?: boolean; + isStatic?: boolean; + allowedProviders?: Array | null; + valueType?: string | null; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type FeatureDefinitionUpdateDto = { + displayName: string; + parentName?: string | null; + description?: string | null; + defaultValue?: string | null; + isVisibleToClients?: boolean; + isAvailableToHost?: boolean; + allowedProviders?: Array | null; + valueType: string; + extraProperties?: { + [key: string]: unknown; + } | null; + concurrencyStamp?: string | null; +}; + +export type FeatureDto = { + name?: string | null; + displayName?: string | null; + value?: string | null; + provider?: FeatureProviderDto; + description?: string | null; + valueType?: IStringValueType; + depth?: number; + parentName?: string | null; +}; + +export type FeatureGroupDefinitionCreateDto = { + displayName: string; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; +}; + +export type FeatureGroupDefinitionDto = { + name?: string | null; + displayName?: string | null; + isStatic?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type FeatureGroupDefinitionUpdateDto = { + displayName: string; + extraProperties?: { + [key: string]: unknown; + } | null; + concurrencyStamp?: string | null; +}; + +export type FeatureGroupDto = { + name?: string | null; + displayName?: string | null; + features?: Array | null; +}; + +export type FeatureProviderDto = { + name?: string | null; + key?: string | null; +}; + +export type FeedbackAttachmentDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + name?: string | null; + url?: string | null; + size?: number; +}; + +export type FeedbackAttachmentTempFileCreateDto = { + path?: string | null; + id?: string | null; +}; + +export type FeedbackAttachmentTempFileDto = { + path?: string | null; + id?: string | null; + size?: number; +}; + +export type FeedbackCommentDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + content?: string | null; +}; + +export type FeedbackCreateDto = { + content: string; + category: string; + attachments?: Array | null; +}; + +export type FeedbackDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + content?: string | null; + category?: string | null; + status?: FeedbackStatus; + comments?: Array | null; + attachments?: Array | null; +}; + +export enum FeedbackStatus { + Created = 1, + InProgress = 2, + Closed = 3, + Resolved = 4, +} + +export enum FieldAttributes { + PrivateScope = 0, + Private = 1, + FamANDAssem = 2, + Assembly = 3, + Family = 4, + FamORAssem = 5, + Public = 6, + FieldAccessMask = 7, + Static = 16, + InitOnly = 32, + Literal = 64, + NotSerialized = 128, + HasFieldRVA = 256, + SpecialName = 512, + RTSpecialName = 1024, + HasFieldMarshal = 4096, + PinvokeImpl = 8192, + HasDefault = 32768, + ReservedMask = 38144, +} + +export type FieldInfo = { + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + memberType?: MemberTypes; + attributes?: FieldAttributes; + fieldType?: Type; + readonly isInitOnly?: boolean; + readonly isLiteral?: boolean; + /** + * @deprecated + */ + readonly isNotSerialized?: boolean; + readonly isPinvokeImpl?: boolean; + readonly isSpecialName?: boolean; + readonly isStatic?: boolean; + readonly isAssembly?: boolean; + readonly isFamily?: boolean; + readonly isFamilyAndAssembly?: boolean; + readonly isFamilyOrAssembly?: boolean; + readonly isPrivate?: boolean; + readonly isPublic?: boolean; + readonly isSecurityCritical?: boolean; + readonly isSecuritySafeCritical?: boolean; + readonly isSecurityTransparent?: boolean; + fieldHandle?: RuntimeFieldHandle; +}; + +export type FileShareDto = { + url?: string | null; + maxAccessCount?: number; + expirationTime?: string | null; +}; + +export type FileShareInput = { + name: string; + path?: string | null; + maxAccessCount?: number; + expirationTime?: string | null; + roles?: Array | null; + users?: Array | null; +}; + +export type FindTenantResultDto = { + success?: boolean; + tenantId?: string | null; + name?: string | null; + normalizedName?: string | null; + isActive?: boolean; +}; + +export enum GenericParameterAttributes { + None = 0, + Covariant = 1, + Contravariant = 2, + VarianceMask = 3, + ReferenceTypeConstraint = 4, + NotNullableValueTypeConstraint = 8, + DefaultConstructorConstraint = 16, + SpecialConstraintMask = 28, +} + +export type GetFeatureListResultDto = { + groups?: Array | null; +}; + +export type GetListByDynamicQueryableInput = { + maxResultCount?: number; + skipCount?: number; + sorting?: string | null; + queryable: DynamicQueryable; +}; + +export type GetPermissionListResultDto = { + entityDisplayName?: string | null; + groups?: Array | null; +}; + +export type Group = { + id?: string | null; + name?: string | null; + avatarUrl?: string | null; + allowAnonymous?: boolean; + allowSendMessage?: boolean; + maxUserLength?: number; + groupUserCount?: number; +}; + +export type GroupAcceptUserDto = { + userId: string; + groupId: number; + allowAccept?: boolean; + rejectReason?: string | null; +}; + +export type GroupRemoveUserDto = { + userId: string; + groupId: number; +}; + +export type GroupUserCard = { + tenantId?: string | null; + userId?: string; + userName?: string | null; + avatarUrl?: string | null; + nickName?: string | null; + age?: number; + sex?: Sex; + sign?: string | null; + description?: string | null; + birthday?: string | null; + online?: boolean; + groupId?: number; + isAdmin?: boolean; + isSuperAdmin?: boolean; +}; + +export type HeaderSettingDto = { + bgColor?: string | null; + fixed?: boolean; + show?: boolean; + theme?: string | null; + showFullScreen?: boolean; + useLockPage?: boolean; + showDoc?: boolean; + showNotice?: boolean; + showSearch?: boolean; +}; + +export enum HttpStatusCode { + Continue = 100, + SwitchingProtocols = 101, + Processing = 102, + EarlyHints = 103, + OK = 200, + Created = 201, + Accepted = 202, + NonAuthoritativeInformation = 203, + NoContent = 204, + ResetContent = 205, + PartialContent = 206, + MultiStatus = 207, + AlreadyReported = 208, + IMUsed = 226, + MultipleChoices = 300, + Ambiguous = 301, + MovedPermanently = 302, + Moved = 303, + Found = 304, + Redirect = 305, + SeeOther = 306, + RedirectMethod = 307, + NotModified = 308, + UseProxy = 400, + Unused = 401, + TemporaryRedirect = 402, + RedirectKeepVerb = 403, + PermanentRedirect = 404, + BadRequest = 405, + Unauthorized = 406, + PaymentRequired = 407, + Forbidden = 408, + NotFound = 409, + MethodNotAllowed = 410, + NotAcceptable = 411, + ProxyAuthenticationRequired = 412, + RequestTimeout = 413, + Conflict = 414, + Gone = 415, + LengthRequired = 416, + PreconditionFailed = 417, + RequestEntityTooLarge = 421, + RequestUriTooLong = 422, + UnsupportedMediaType = 423, + RequestedRangeNotSatisfiable = 424, + ExpectationFailed = 426, + MisdirectedRequest = 428, + UnprocessableEntity = 429, + UnprocessableContent = 431, + Locked = 451, + FailedDependency = 500, + UpgradeRequired = 501, + PreconditionRequired = 502, + TooManyRequests = 503, + RequestHeaderFieldsTooLarge = 504, + UnavailableForLegalReasons = 505, + InternalServerError = 506, + NotImplemented = 507, + BadGateway = 508, + ServiceUnavailable = 510, + GatewayTimeout = 511, +} + +export type IanaTimeZone = { + timeZoneName?: string | null; +}; + +export type IBookmark = { + [key: string]: unknown; +}; + +export type ICustomAttributeProvider = { + [key: string]: unknown; +}; + +export type IdentityClaimDto = { + id?: string; + claimType?: string | null; + claimValue?: string | null; +}; + +export type IdentityClaimTypeCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + required?: boolean; + regex?: string | null; + regexDescription?: string | null; + description?: string | null; + name: string; + isStatic?: boolean; + valueType?: IdentityClaimValueType; +}; + +export type IdentityClaimTypeDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + name?: string | null; + required?: boolean; + isStatic?: boolean; + regex?: string | null; + regexDescription?: string | null; + description?: string | null; + valueType?: IdentityClaimValueType; +}; + +export type IdentityClaimTypeUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + required?: boolean; + regex?: string | null; + regexDescription?: string | null; + description?: string | null; +}; + +export enum IdentityClaimValueType { + String = 0, + Int = 1, + Boolean = 2, + DateTime = 3, +} + +export type IdentityRoleAddOrRemoveOrganizationUnitDto = { + organizationUnitIds: Array; +}; + +export type IdentityRoleClaimCreateDto = { + claimType: string; + claimValue: string; +}; + +export type IdentityRoleClaimUpdateDto = { + claimType: string; + claimValue: string; + newClaimValue: string; +}; + +export type IdentityRoleCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + isDefault?: boolean; + isPublic?: boolean; +}; + +export type IdentityRoleDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + name?: string | null; + isDefault?: boolean; + isStatic?: boolean; + isPublic?: boolean; + concurrencyStamp?: string | null; +}; + +export type IdentityRoleUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + isDefault?: boolean; + isPublic?: boolean; + concurrencyStamp?: string | null; +}; + +export type IdentitySessionDto = { + id?: string; + sessionId?: string | null; + device?: string | null; + deviceInfo?: string | null; + userId?: string; + clientId?: string | null; + ipAddresses?: string | null; + signedIn?: string; + lastAccessed?: string | null; +}; + +export type IdentitySessionDto_1 = { + id?: string; + sessionId?: string | null; + device?: string | null; + deviceInfo?: string | null; + clientId?: string | null; + ipAddresses?: string | null; + signedIn?: string; + lastAccessed?: string | null; +}; + +export type IdentityUserClaimCreateDto = { + claimType: string; + claimValue?: string | null; +}; + +export type IdentityUserClaimUpdateDto = { + claimType: string; + claimValue?: string | null; + newClaimValue?: string | null; +}; + +export type IdentityUserCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + userName: string; + name?: string | null; + surname?: string | null; + email: string; + phoneNumber?: string | null; + isActive?: boolean; + lockoutEnabled?: boolean; + roleNames?: Array | null; + password: string; +}; + +export type IdentityUserDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + isDeleted?: boolean; + deleterId?: string | null; + deletionTime?: string | null; + tenantId?: string | null; + userName?: string | null; + name?: string | null; + surname?: string | null; + email?: string | null; + emailConfirmed?: boolean; + phoneNumber?: string | null; + phoneNumberConfirmed?: boolean; + isActive?: boolean; + lockoutEnabled?: boolean; + accessFailedCount?: number; + lockoutEnd?: string | null; + concurrencyStamp?: string | null; + entityVersion?: number; + lastPasswordChangeTime?: string | null; +}; + +export type IdentityUserOrganizationUnitUpdateDto = { + organizationUnitIds: Array; +}; + +export type IdentityUserSetPasswordInput = { + password: string; +}; + +export type IdentityUserUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + userName: string; + name?: string | null; + surname?: string | null; + email: string; + phoneNumber?: string | null; + isActive?: boolean; + lockoutEnabled?: boolean; + roleNames?: Array | null; + password?: string | null; + concurrencyStamp?: string | null; +}; + +export type IdentityUserUpdateRolesDto = { + roleNames: Array; +}; + +export type Instant = { + [key: string]: unknown; +}; + +export type IntellisenseContext = { + activityTypeName?: string | null; + propertyName?: string | null; +}; + +export type InterfaceMethodApiDescriptionModel = { + name?: string | null; + parametersOnMethod?: Array | null; + returnValue?: ReturnValueApiDescriptionModel; +}; + +export type IntPtr = { + [key: string]: unknown; +}; + +export type IOutputFormatter = { + [key: string]: unknown; +}; + +export type IRemoteStreamContent = { + readonly fileName?: string | null; + readonly contentType?: string | null; + readonly contentLength?: number | null; +}; + +export type IStringValueType = { + readonly name?: string | null; + readonly properties?: { + [key: string]: unknown; + } | null; + validator?: IValueValidator; +}; + +export type IValueValidator = { + readonly name?: string | null; + readonly properties?: { + [key: string]: unknown; + } | null; +}; + +export enum JobActionType { + Successed = 0, + Completed = 1, + Failed = -1, +} + +export enum JobPriority { + Low = 5, + BelowNormal = 10, + Normal = 15, + AboveNormal = 20, + High = 25, +} + +export enum JobSource { + User = 0, + System = 10, + None = -1, +} + +export enum JobStatus { + Completed = 0, + Queuing = 5, + Running = 10, + FailedRetry = 15, + Paused = 20, + Stopped = 30, + None = -1, +} + +export enum JobType { + Once = 0, + Period = 1, + Persistent = 2, +} + +export type JToken = Array; + +export type LanguageCreateDto = { + displayName: string; + cultureName: string; + uiCultureName?: string | null; +}; + +export type LanguageDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + cultureName?: string | null; + uiCultureName?: string | null; + displayName?: string | null; + twoLetterISOLanguageName?: string | null; +}; + +export type LanguageDto_1 = { + cultureName?: string | null; + uiCultureName?: string | null; + displayName?: string | null; + twoLetterISOLanguageName?: string | null; +}; + +export type LanguageInfo = { + cultureName?: string | null; + uiCultureName?: string | null; + displayName?: string | null; + readonly twoLetterISOLanguageName?: string | null; +}; + +export type LanguageUpdateDto = { + displayName: string; +}; + +export type LastChatMessage = { + avatarUrl?: string | null; + object?: string | null; + tenantId?: string | null; + groupId?: string | null; + messageId?: string | null; + formUserId?: string; + formUserName?: string | null; + toUserId?: string | null; + content?: string | null; + sendTime?: string; + readonly isAnonymous?: boolean; + messageType?: MessageType; + source?: MessageSourceType; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type LayoutCreateDto = { + name: string; + displayName: string; + description?: string | null; + path: string; + redirect?: string | null; + dataId?: string; + framework: string; +}; + +export type LayoutDto = { + id?: string; + path?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + redirect?: string | null; + meta?: { + [key: string]: unknown; + } | null; + framework?: string | null; + dataId?: string; +}; + +export enum LayoutKind { + Sequential = 0, + Explicit = 2, + Auto = 3, +} + +export type LayoutUpdateDto = { + name: string; + displayName: string; + description?: string | null; + path: string; + redirect?: string | null; +}; + +export type ListResultDtoOfBackgroundJobActionDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfBackgroundJobActionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfBackgroundJobDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfDataDto = { + items?: Array | null; +}; + +export type ListResultDtoOfDynamicParamterDto = { + items?: Array | null; +}; + +export type ListResultDtoOfEntityChangeWithUsernameDto = { + items?: Array | null; +}; + +export type ListResultDtoOfFeatureDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfFeatureGroupDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfGroup = { + items?: Array | null; +}; + +export type ListResultDtoOfIdentityClaimDto = { + items?: Array | null; +}; + +export type ListResultDtoOfIdentityClaimTypeDto = { + items?: Array | null; +}; + +export type ListResultDtoOfIdentityRoleDto = { + items?: Array | null; +}; + +export type ListResultDtoOfLanguageDto = { + items?: Array | null; +}; + +export type ListResultDtoOfLastChatMessage = { + items?: Array | null; +}; + +export type ListResultDtoOfLayoutDto = { + items?: Array | null; +}; + +export type ListResultDtoOfMenuDto = { + items?: Array | null; +}; + +export type ListResultDtoOfMyFileShareDto = { + items?: Array | null; +}; + +export type ListResultDtoOfNameValue = { + items?: Array | null; +}; + +export type ListResultDtoOfNotificationDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfNotificationGroupDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfNotificationGroupDto = { + items?: Array | null; +}; + +export type ListResultDtoOfNotificationTemplateDto = { + items?: Array | null; +}; + +export type ListResultDtoOfOrganizationUnitDto = { + items?: Array | null; +}; + +export type ListResultDtoOfOssObjectDto = { + items?: Array | null; +}; + +export type ListResultDtoOfPermissionDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfPermissionGroupDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfResourceDto = { + items?: Array | null; +}; + +export type ListResultDtoOfSettingDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfString = { + items?: Array | null; +}; + +export type ListResultDtoOfTenantConnectionStringDto = { + items?: Array | null; +}; + +export type ListResultDtoOfTextDifferenceDto = { + items?: Array | null; +}; + +export type ListResultDtoOfTextTemplateDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfUserData = { + items?: Array | null; +}; + +export type ListResultDtoOfUserFavoriteMenuDto = { + items?: Array | null; +}; + +export type ListResultDtoOfUserFriend = { + items?: Array | null; +}; + +export type ListResultDtoOfUserSubscreNotificationDto = { + items?: Array | null; +}; + +export type ListResultDtoOfWebhookAvailableGroupDto = { + items?: Array | null; +}; + +export type ListResultDtoOfWebhookDefinitionDto = { + items?: Array | null; +}; + +export type ListResultDtoOfWebhookGroupDefinitionDto = { + items?: Array | null; +}; + +export type LocalizableStringDto = { + name?: string | null; + resource?: string | null; +}; + +export type LogDto = { + timeStamp?: string; + level?: LogLevel; + message?: string | null; + fields?: LogFieldDto; + exceptions?: Array | null; +}; + +export type LogExceptionDto = { + depth?: number; + class?: string | null; + message?: string | null; + source?: string | null; + stackTrace?: string | null; + hResult?: number; + helpURL?: string | null; +}; + +export type LogFieldDto = { + id?: string | null; + machineName?: string | null; + environment?: string | null; + application?: string | null; + context?: string | null; + actionId?: string | null; + actionName?: string | null; + requestId?: string | null; + requestPath?: string | null; + connectionId?: string | null; + correlationId?: string | null; + clientId?: string | null; + userId?: string | null; + processId?: number; + threadId?: number; +}; + +export enum LoginResultType { + Success = 1, + InvalidUserNameOrPassword = 2, + NotAllowed = 3, + LockedOut = 4, + RequiresTwoFactor = 5, +} + +export enum LogLevel { + Trace = 0, + Debug = 1, + Information = 2, + Warning = 3, + Error = 4, + Critical = 5, + None = 6, +} + +export type MemberInfo = { + memberType?: MemberTypes; + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; +}; + +export enum MemberTypes { + Constructor = 1, + Event = 2, + Field = 4, + Method = 8, + Property = 16, + TypeInfo = 32, + Custom = 64, + NestedType = 128, + All = 191, +} + +export type MenuCreateDto = { + parentId?: string | null; + name: string; + displayName: string; + description?: string | null; + path: string; + redirect?: string | null; + component: string; + isPublic?: boolean; + meta?: { + [key: string]: unknown; + } | null; + layoutId: string; +}; + +export type MenuDto = { + id?: string; + path?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + redirect?: string | null; + meta?: { + [key: string]: unknown; + } | null; + code?: string | null; + component?: string | null; + framework?: string | null; + parentId?: string | null; + layoutId?: string; + isPublic?: boolean; + startup?: boolean; +}; + +export type MenuSettingDto = { + bgColor?: string | null; + fixed?: boolean; + collapsed?: boolean; + canDrag?: boolean; + show?: boolean; + hidden?: boolean; + split?: boolean; + menuWidth?: number; + mode?: string | null; + type?: string | null; + theme?: string | null; + topMenuAlign?: string | null; + trigger?: string | null; + accordion?: boolean; + closeMixSidebarOnChange?: boolean; + collapsedShowTitle?: boolean; + mixSideTrigger?: string | null; + mixSideFixed?: boolean; +}; + +export type MenuUpdateDto = { + parentId?: string | null; + name: string; + displayName: string; + description?: string | null; + path: string; + redirect?: string | null; + component: string; + isPublic?: boolean; + meta?: { + [key: string]: unknown; + } | null; +}; + +export enum MessageSourceType { + User = 0, + System = 10, +} + +export enum MessageState { + Send = 0, + Read = 1, + ReCall = 10, + Failed = 50, + BackTo = 100, +} + +export enum MessageType { + Text = 0, + Image = 10, + Link = 20, + Video = 30, + Voice = 40, + File = 50, + Notifier = 100, +} + +export enum MethodAttributes { + PrivateScope = 0, + ReuseSlot = 1, + Private = 2, + FamANDAssem = 3, + Assembly = 4, + Family = 5, + FamORAssem = 6, + Public = 7, + MemberAccessMask = 8, + UnmanagedExport = 16, + Static = 32, + Final = 64, + Virtual = 128, + HideBySig = 256, + NewSlot = 512, + VtableLayoutMask = 1024, + CheckAccessOnOverride = 2048, + Abstract = 4096, + SpecialName = 8192, + RTSpecialName = 16384, + PinvokeImpl = 32768, + HasSecurity = 53248, +} + +export type MethodBase = { + memberType?: MemberTypes; + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + attributes?: MethodAttributes; + methodImplementationFlags?: MethodImplAttributes; + callingConvention?: CallingConventions; + readonly isAbstract?: boolean; + readonly isConstructor?: boolean; + readonly isFinal?: boolean; + readonly isHideBySig?: boolean; + readonly isSpecialName?: boolean; + readonly isStatic?: boolean; + readonly isVirtual?: boolean; + readonly isAssembly?: boolean; + readonly isFamily?: boolean; + readonly isFamilyAndAssembly?: boolean; + readonly isFamilyOrAssembly?: boolean; + readonly isPrivate?: boolean; + readonly isPublic?: boolean; + readonly isConstructedGenericMethod?: boolean; + readonly isGenericMethod?: boolean; + readonly isGenericMethodDefinition?: boolean; + readonly containsGenericParameters?: boolean; + methodHandle?: RuntimeMethodHandle; + readonly isSecurityCritical?: boolean; + readonly isSecuritySafeCritical?: boolean; + readonly isSecurityTransparent?: boolean; +}; + +export enum MethodImplAttributes { + IL = 0, + Managed = 1, + Native = 2, + OPTIL = 3, + CodeTypeMask = 4, + Runtime = 8, + ManagedMask = 16, + Unmanaged = 32, + NoInlining = 64, + ForwardRef = 128, + Synchronized = 256, + NoOptimization = 512, + PreserveSig = 4096, + AggressiveInlining = 65535, +} + +export type MethodInfo = { + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + attributes?: MethodAttributes; + methodImplementationFlags?: MethodImplAttributes; + callingConvention?: CallingConventions; + readonly isAbstract?: boolean; + readonly isConstructor?: boolean; + readonly isFinal?: boolean; + readonly isHideBySig?: boolean; + readonly isSpecialName?: boolean; + readonly isStatic?: boolean; + readonly isVirtual?: boolean; + readonly isAssembly?: boolean; + readonly isFamily?: boolean; + readonly isFamilyAndAssembly?: boolean; + readonly isFamilyOrAssembly?: boolean; + readonly isPrivate?: boolean; + readonly isPublic?: boolean; + readonly isConstructedGenericMethod?: boolean; + readonly isGenericMethod?: boolean; + readonly isGenericMethodDefinition?: boolean; + readonly containsGenericParameters?: boolean; + methodHandle?: RuntimeMethodHandle; + readonly isSecurityCritical?: boolean; + readonly isSecuritySafeCritical?: boolean; + readonly isSecurityTransparent?: boolean; + memberType?: MemberTypes; + returnParameter?: ParameterInfo; + returnType?: Type; + returnTypeCustomAttributes?: ICustomAttributeProvider; +}; + +export type MethodParameterApiDescriptionModel = { + name?: string | null; + typeAsString?: string | null; + type?: string | null; + typeSimple?: string | null; + isOptional?: boolean; + defaultValue?: unknown; +}; + +export type Module = { + assembly?: Assembly; + readonly fullyQualifiedName?: string | null; + readonly name?: string | null; + readonly mdStreamVersion?: number; + readonly moduleVersionId?: string; + readonly scopeName?: string | null; + moduleHandle?: ModuleHandle; + readonly customAttributes?: Array | null; + readonly metadataToken?: number; +}; + +export type ModuleApiDescriptionModel = { + rootPath?: string | null; + remoteServiceName?: string | null; + controllers?: { + [key: string]: ControllerApiDescriptionModel; + } | null; +}; + +export type ModuleExtensionDto = { + entities?: { + [key: string]: EntityExtensionDto; + } | null; + configuration?: { + [key: string]: unknown; + } | null; +}; + +export type ModuleHandle = { + readonly mdStreamVersion?: number; +}; + +export type MultiTabsSettingDto = { + cache?: boolean; + show?: boolean; + showQuick?: boolean; + canDrag?: boolean; + showRedo?: boolean; + showFold?: boolean; +}; + +export type MultiTenancyInfoDto = { + isEnabled?: boolean; +}; + +export enum MultiTenancySides { + Tenant = 1, + Host = 2, + Both = 3, +} + +export type MyFileShareDto = { + name?: string | null; + path?: string | null; + roles?: Array | null; + users?: Array | null; + mD5?: string | null; + url?: string | null; + accessCount?: number; + maxAccessCount?: number; + expirationTime?: string; +}; + +export type MyFriendAddRequestDto = { + friendId: string; + remarkName?: string | null; +}; + +export type MyFriendCreateDto = { + friendId: string; +}; + +export type NameValue = { + name?: string | null; + value?: string | null; +}; + +export enum NotificationContentType { + Text = 0, + Html = 1, + Markdown = 2, + Json = 3, +} + +export type NotificationData = { + readonly type?: string | null; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type NotificationDefinitionCreateDto = { + template?: string | null; + displayName: string; + description?: string | null; + allowSubscriptionToClients?: boolean; + notificationLifetime?: NotificationLifetime; + notificationType?: NotificationType; + contentType?: NotificationContentType; + providers?: Array | null; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + groupName: string; +}; + +export type NotificationDefinitionDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name?: string | null; + isStatic?: boolean; + groupName?: string | null; + displayName?: string | null; + description?: string | null; + allowSubscriptionToClients?: boolean | null; + notificationLifetime?: NotificationLifetime; + notificationType?: NotificationType; + contentType?: NotificationContentType; + providers?: Array | null; + template?: string | null; +}; + +export type NotificationDefinitionUpdateDto = { + template?: string | null; + displayName: string; + description?: string | null; + allowSubscriptionToClients?: boolean; + notificationLifetime?: NotificationLifetime; + notificationType?: NotificationType; + contentType?: NotificationContentType; + providers?: Array | null; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type NotificationDto = { + name?: string | null; + displayName?: string | null; + description?: string | null; + lifetime?: NotificationLifetime; + type?: NotificationType; + contentType?: NotificationContentType; +}; + +export type NotificationGroupDefinitionCreateDto = { + displayName: string; + description?: string | null; + allowSubscriptionToClients?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; +}; + +export type NotificationGroupDefinitionDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + isStatic?: boolean; + allowSubscriptionToClients?: boolean; +}; + +export type NotificationGroupDefinitionUpdateDto = { + displayName: string; + description?: string | null; + allowSubscriptionToClients?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type NotificationGroupDto = { + name?: string | null; + displayName?: string | null; + notifications?: Array | null; +}; + +export enum NotificationLifetime { + Persistent = 0, + OnlyOne = 1, +} + +export type NotificationMarkReadStateInput = { + idList: Array; + state?: NotificationReadState; +}; + +export enum NotificationReadState { + Read = 0, + UnRead = 1, +} + +export type NotificationSendDto = { + name: string; + data?: { + [key: string]: unknown; + } | null; + culture?: string | null; + toUsers?: Array | null; + severity?: NotificationSeverity; +}; + +export enum NotificationSeverity { + Success = 0, + Info = 10, + Warn = 20, + Error = 30, + Fatal = 40, +} + +export type NotificationTemplateDto = { + name?: string | null; + description?: string | null; + title?: string | null; + content?: string | null; + culture?: string | null; +}; + +export type NotificationTemplateSendDto = { + name: string; + data?: { + [key: string]: unknown; + } | null; + culture?: string | null; + toUsers?: Array | null; + severity?: NotificationSeverity; +}; + +export enum NotificationType { + Application = 0, + System = 10, + User = 20, + ServiceCallback = 30, +} + +export type ObjectExtensionsDto = { + modules?: { + [key: string]: ModuleExtensionDto; + } | null; + enums?: { + [key: string]: ExtensionEnumDto; + } | null; +}; + +export type OkObjectResult = { + value?: unknown; + formatters?: Array | null; + contentTypes?: Array | null; + declaredType?: Type; + statusCode?: number | null; +}; + +export type OpenIddictApplicationCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + clientSecret?: string | null; + clientType?: string | null; + consentType?: string | null; + displayName?: string | null; + displayNames?: { + [key: string]: string; + } | null; + endpoints?: Array | null; + grantTypes?: Array | null; + responseTypes?: Array | null; + scopes?: Array | null; + postLogoutRedirectUris?: Array | null; + properties?: { + [key: string]: string; + } | null; + redirectUris?: Array | null; + requirements?: Array | null; + applicationType?: string | null; + clientUri?: string | null; + logoUri?: string | null; + clientId: string; +}; + +export type OpenIddictApplicationDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + clientId?: string | null; + clientType?: string | null; + consentType?: string | null; + displayName?: string | null; + displayNames?: { + [key: string]: string; + } | null; + endpoints?: Array | null; + grantTypes?: Array | null; + responseTypes?: Array | null; + scopes?: Array | null; + postLogoutRedirectUris?: Array | null; + properties?: { + [key: string]: string; + } | null; + redirectUris?: Array | null; + requirements?: Array | null; + applicationType?: string | null; + clientUri?: string | null; + logoUri?: string | null; + settings?: string | null; + jsonWebKeySet?: string | null; + concurrencyStamp?: string | null; +}; + +export type OpenIddictApplicationUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + clientSecret?: string | null; + clientType?: string | null; + consentType?: string | null; + displayName?: string | null; + displayNames?: { + [key: string]: string; + } | null; + endpoints?: Array | null; + grantTypes?: Array | null; + responseTypes?: Array | null; + scopes?: Array | null; + postLogoutRedirectUris?: Array | null; + properties?: { + [key: string]: string; + } | null; + redirectUris?: Array | null; + requirements?: Array | null; + applicationType?: string | null; + clientUri?: string | null; + logoUri?: string | null; + concurrencyStamp?: string | null; +}; + +export type OpenIddictAuthorizationDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + concurrencyStamp?: string | null; + applicationId?: string | null; + creationDate?: string | null; + properties?: { + [key: string]: string; + } | null; + scopes?: Array | null; + status?: string | null; + subject?: string | null; + type?: string | null; +}; + +export type OpenIddictScopeCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + description?: string | null; + descriptions?: { + [key: string]: string; + } | null; + displayName?: string | null; + displayNames?: { + [key: string]: string; + } | null; + name: string; + properties?: { + [key: string]: string; + } | null; + resources?: Array | null; +}; + +export type OpenIddictScopeDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + concurrencyStamp?: string | null; + description?: string | null; + descriptions?: { + [key: string]: string; + } | null; + displayName?: string | null; + displayNames?: { + [key: string]: string; + } | null; + name?: string | null; + properties?: { + [key: string]: string; + } | null; + resources?: Array | null; +}; + +export type OpenIddictScopeUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + description?: string | null; + descriptions?: { + [key: string]: string; + } | null; + displayName?: string | null; + displayNames?: { + [key: string]: string; + } | null; + name: string; + properties?: { + [key: string]: string; + } | null; + resources?: Array | null; + concurrencyStamp?: string | null; +}; + +export type OpenIddictTokenDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + concurrencyStamp?: string | null; + applicationId?: string | null; + authorizationId?: string | null; + creationDate?: string | null; + expirationDate?: string | null; + payload?: string | null; + properties?: string | null; + redemptionDate?: string | null; + referenceId?: string | null; + status?: string | null; + subject?: string | null; + type?: string | null; +}; + +export type OptionDto = { + name?: string | null; + value?: string | null; +}; + +export type OrganizationUnitAddRoleDto = { + roleIds: Array; +}; + +export type OrganizationUnitAddUserDto = { + userIds: Array; +}; + +export type OrganizationUnitCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + displayName: string; + parentId?: string | null; +}; + +export type OrganizationUnitDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + parentId?: string | null; + code?: string | null; + displayName?: string | null; +}; + +export type OrganizationUnitEntityRuleCreateDto = { + isEnabled?: boolean; + operation: DataAccessOperation; + filterGroup: DataAccessFilterGroup; + allowProperties?: Array | null; + entityTypeId: string; + orgId: string; + orgCode: string; +}; + +export type OrganizationUnitEntityRuleDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + tenantId?: string | null; + isEnabled?: boolean; + operation?: DataAccessOperation; + filterGroup?: DataAccessFilterGroup; + entityTypeId?: string; + entityTypeFullName?: string | null; + allowProperties?: Array | null; + orgId?: string; + orgCode?: string | null; +}; + +export type OrganizationUnitEntityRuleUpdateDto = { + isEnabled?: boolean; + operation: DataAccessOperation; + filterGroup: DataAccessFilterGroup; + allowProperties?: Array | null; +}; + +export type OrganizationUnitMoveDto = { + parentId?: string | null; +}; + +export type OrganizationUnitUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + displayName?: string | null; +}; + +export type OssContainerDto = { + name?: string | null; + size?: number; + creationDate?: string; + lastModifiedDate?: string | null; + metadata?: { + [key: string]: string; + } | null; +}; + +export type OssContainersResultDto = { + prefix?: string | null; + marker?: string | null; + nextMarker?: string | null; + maxKeys?: number; + containers?: Array | null; +}; + +export type OssObjectDto = { + isFolder?: boolean; + path?: string | null; + name?: string | null; + size?: number; + mD5?: string | null; + creationDate?: string | null; + lastModifiedDate?: string | null; + metadata?: { + [key: string]: string; + } | null; +}; + +export type OssObjectsResultDto = { + bucket?: string | null; + prefix?: string | null; + delimiter?: string | null; + marker?: string | null; + nextMarker?: string | null; + maxKeys?: number; + objects?: Array | null; +}; + +export type PackageBlobDto = { + id?: number; + creationTime?: string; + creatorId?: string | null; + name?: string | null; + url?: string | null; + size?: number | null; + summary?: string | null; + createdAt?: string; + updatedAt?: string | null; + license?: string | null; + authors?: string | null; + shA256?: string | null; + contentType?: string | null; + downloadCount?: number; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type PackageCreateDto = { + note: string; + description?: string | null; + forceUpdate?: boolean; + authors?: string | null; + level?: PackageLevel; + name: string; + version: string; +}; + +export type PackageDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + concurrencyStamp?: string | null; + name?: string | null; + note?: string | null; + version?: string | null; + description?: string | null; + forceUpdate?: boolean; + authors?: string | null; + level?: PackageLevel; + blobs?: Array | null; +}; + +export enum PackageLevel { + Resource = 0, + Full = 1, + None = -1, +} + +export type PackageUpdateDto = { + note: string; + description?: string | null; + forceUpdate?: boolean; + authors?: string | null; + level?: PackageLevel; + concurrencyStamp?: string | null; +}; + +export type PagedListOfWorkflowBlueprintModel = { + items?: Array | null; + page?: number | null; + pageSize?: number | null; + totalCount?: number; +}; + +export type PagedListOfWorkflowBlueprintSummaryModel = { + items?: Array | null; + page?: number | null; + pageSize?: number | null; + totalCount?: number; +}; + +export type PagedListOfWorkflowDefinitionSummaryModel = { + items?: Array | null; + page?: number | null; + pageSize?: number | null; + totalCount?: number; +}; + +export type PagedListOfWorkflowExecutionLogRecord = { + items?: Array | null; + page?: number | null; + pageSize?: number | null; + totalCount?: number; +}; + +export type PagedListOfWorkflowInstanceSummaryModel = { + items?: Array | null; + page?: number | null; + pageSize?: number | null; + totalCount?: number; +}; + +export type PagedResultDtoOfAuditLogDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfBackgroundJobInfoDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfBackgroundJobLogDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfChatMessage = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfDataDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfEditionDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfEntityChangeDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfEntityTypeInfoDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfFeedbackDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfGroup = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfGroupUserCard = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfIdentityClaimTypeDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfIdentityRoleDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfIdentitySessionDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfIdentitySessionDto_1 = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfIdentityUserDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfLayoutDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfLogDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfMenuDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfOpenIddictApplicationDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfOpenIddictAuthorizationDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfOpenIddictScopeDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfOpenIddictTokenDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfOrganizationUnitDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfPackageDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfSecurityLogDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfTenantDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfUserFriend = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfUserNotificationDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfUserSubscreNotificationDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfWebhookSendRecordDto = { + items?: Array | null; + totalCount?: number; +}; + +export type PagedResultDtoOfWebhookSubscriptionDto = { + items?: Array | null; + totalCount?: number; +}; + +export type ParameterApiDescriptionModel = { + nameOnMethod?: string | null; + name?: string | null; + jsonName?: string | null; + type?: string | null; + typeSimple?: string | null; + isOptional?: boolean; + defaultValue?: unknown; + constraintTypes?: Array | null; + bindingSourceId?: string | null; + descriptorName?: string | null; +}; + +export enum ParameterAttributes { + None = 0, + In = 1, + Out = 2, + Lcid = 4, + Retval = 8, + Optional = 16, + HasDefault = 4096, + HasFieldMarshal = 8192, + Reserved3 = 16384, + Reserved4 = 32768, + ReservedMask = 61440, +} + +export type ParameterInfo = { + attributes?: ParameterAttributes; + member?: MemberInfo; + readonly name?: string | null; + parameterType?: Type; + readonly position?: number; + readonly isIn?: boolean; + readonly isLcid?: boolean; + readonly isOptional?: boolean; + readonly isOut?: boolean; + readonly isRetval?: boolean; + readonly defaultValue?: unknown; + readonly rawDefaultValue?: unknown; + readonly hasDefaultValue?: boolean; + readonly customAttributes?: Array | null; + readonly metadataToken?: number; +}; + +export type ParamterOptionDto = { + key?: string | null; + value?: unknown; +}; + +export type PermissionDefinitionCreateDto = { + displayName: string; + parentName?: string | null; + isEnabled?: boolean; + multiTenancySide?: MultiTenancySides; + providers?: Array | null; + stateCheckers?: string | null; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + groupName: string; +}; + +export type PermissionDefinitionDto = { + name?: string | null; + parentName?: string | null; + displayName?: string | null; + groupName?: string | null; + isEnabled?: boolean; + isStatic?: boolean; + multiTenancySide?: MultiTenancySides; + providers?: Array | null; + stateCheckers?: string | null; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type PermissionDefinitionUpdateDto = { + displayName: string; + parentName?: string | null; + isEnabled?: boolean; + multiTenancySide?: MultiTenancySides; + providers?: Array | null; + stateCheckers?: string | null; + extraProperties?: { + [key: string]: unknown; + } | null; + concurrencyStamp?: string | null; +}; + +export type PermissionGrantInfoDto = { + name?: string | null; + displayName?: string | null; + parentName?: string | null; + isGranted?: boolean; + allowedProviders?: Array | null; + grantedProviders?: Array | null; +}; + +export type PermissionGroupDefinitionCreateDto = { + displayName: string; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; +}; + +export type PermissionGroupDefinitionDto = { + name?: string | null; + displayName?: string | null; + isStatic?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type PermissionGroupDefinitionUpdateDto = { + displayName: string; + extraProperties?: { + [key: string]: unknown; + } | null; + concurrencyStamp?: string | null; +}; + +export type PermissionGroupDto = { + name?: string | null; + displayName?: string | null; + displayNameKey?: string | null; + displayNameResource?: string | null; + permissions?: Array | null; +}; + +export type PhoneRegisterDto = { + phoneNumber: string; + name?: string | null; + userName?: string | null; + emailAddress?: string | null; + password: string; + code: string; +}; + +export type PhoneResetPasswordDto = { + phoneNumber: string; + newPassword: string; + code: string; +}; + +export type ProblemDetails = { + type?: string | null; + title?: string | null; + status?: number | null; + detail?: string | null; + instance?: string | null; + [key: string]: (unknown | string | number) | undefined; +}; + +export type ProfileDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + userName?: string | null; + email?: string | null; + name?: string | null; + surname?: string | null; + phoneNumber?: string | null; + isExternal?: boolean; + hasPassword?: boolean; + concurrencyStamp?: string | null; +}; + +export type ProjectConfigDto = { + permissionCacheType?: number; + showSettingButton?: boolean; + showDarkModeToggle?: boolean; + settingButtonPosition?: string | null; + permissionMode?: string | null; + sessionTimeoutProcessing?: number; + grayMode?: boolean; + colorWeak?: boolean; + themeColor?: string | null; + fullContent?: boolean; + contentMode?: string | null; + showLogo?: boolean; + showFooter?: boolean; + headerSetting?: HeaderSettingDto; + menuSetting?: MenuSettingDto; + multiTabsSetting?: MultiTabsSettingDto; + transitionSetting?: TransitionSettingDto; + openKeepAlive?: boolean; + lockTime?: number; + showBreadCrumb?: boolean; + showBreadCrumbIcon?: boolean; + useErrorHandle?: boolean; + useOpenBackTop?: boolean; + canEmbedIFramePage?: boolean; + closeMessageOnSwitch?: boolean; + removeAllHttpPending?: boolean; +}; + +export type PropertyApiDescriptionModel = { + name?: string | null; + jsonName?: string | null; + type?: string | null; + typeSimple?: string | null; + isRequired?: boolean; + minLength?: number | null; + maxLength?: number | null; + minimum?: string | null; + maximum?: string | null; + regex?: string | null; +}; + +export enum PropertyAttributes { + None = 0, + SpecialName = 512, + RTSpecialName = 1024, + HasDefault = 4096, + Reserved2 = 8192, + Reserved3 = 16384, + Reserved4 = 32768, + ReservedMask = 62464, +} + +export type PropertyInfo = { + readonly name?: string | null; + declaringType?: Type; + reflectedType?: Type; + module?: Module; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + memberType?: MemberTypes; + propertyType?: Type; + attributes?: PropertyAttributes; + readonly isSpecialName?: boolean; + readonly canRead?: boolean; + readonly canWrite?: boolean; + getMethod?: MethodInfo; + setMethod?: MethodInfo; +}; + +export type ProviderInfoDto = { + providerName?: string | null; + providerKey?: string | null; +}; + +export type RegisterDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + userName: string; + emailAddress: string; + password: string; + appName: string; +}; + +export type RemoteServiceErrorInfo = { + code?: string | null; + message?: string | null; + details?: string | null; + data?: { + [key: string]: unknown; + } | null; + validationErrors?: Array | null; +}; + +export type RemoteServiceErrorResponse = { + error?: RemoteServiceErrorInfo; +}; + +export type RemoteServiceValidationErrorInfo = { + message?: string | null; + members?: Array | null; +}; + +export type ResetPasswordDto = { + userId?: string; + resetToken: string; + password: string; +}; + +export type ResourceCreateDto = { + enable?: boolean; + displayName?: string | null; + description?: string | null; + defaultCultureName?: string | null; + name: string; +}; + +export type ResourceDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + enable?: boolean; + name?: string | null; + displayName?: string | null; + description?: string | null; + defaultCultureName?: string | null; +}; + +export type ResourceDto_1 = { + name?: string | null; + displayName?: string | null; + description?: string | null; +}; + +export type ResourceUpdateDto = { + enable?: boolean; + displayName?: string | null; + description?: string | null; + defaultCultureName?: string | null; +}; + +export type RetryWorkflowRequest = { + runImmediately?: boolean; +}; + +export type ReturnValueApiDescriptionModel = { + type?: string | null; + typeSimple?: string | null; +}; + +export type RoleEntityRuleCreateDto = { + isEnabled?: boolean; + operation: DataAccessOperation; + filterGroup: DataAccessFilterGroup; + allowProperties?: Array | null; + entityTypeId: string; + roleId: string; + roleName: string; +}; + +export type RoleEntityRuleDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + tenantId?: string | null; + isEnabled?: boolean; + operation?: DataAccessOperation; + filterGroup?: DataAccessFilterGroup; + entityTypeId?: string; + entityTypeFullName?: string | null; + allowProperties?: Array | null; + roleId?: string; + roleName?: string | null; +}; + +export type RoleEntityRuleUpdateDto = { + isEnabled?: boolean; + operation: DataAccessOperation; + filterGroup: DataAccessFilterGroup; + allowProperties?: Array | null; +}; + +export type RoleMenuInput = { + roleName: string; + menuIds: Array; +}; + +export type RoleMenuStartupInput = { + roleName: string; +}; + +export type RuntimeFieldHandle = { + value?: IntPtr; +}; + +export type RuntimeMethodHandle = { + value?: IntPtr; +}; + +export type RuntimeSelectListContextHolder = { + providerTypeName?: string | null; + context?: unknown; +}; + +export type RuntimeTypeHandle = { + value?: IntPtr; +}; + +export type SaveWebhookDefinitionRequest = { + id?: string | null; + path: string; + name: string; + description?: string | null; + payloadTypeName?: string | null; + isEnabled?: boolean; +}; + +export type SaveWorkflowDefinitionRequest = { + workflowDefinitionId?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + tag?: string | null; + channel?: string | null; + variables?: string | null; + contextOptions?: WorkflowContextOptions; + isSingleton?: boolean; + persistenceBehavior?: WorkflowPersistenceBehavior; + deleteCompletedInstances?: boolean; + publish?: boolean; + activities?: Array | null; + connections?: Array | null; + customAttributes?: string | null; +}; + +export type ScheduledActivity = { + activityId?: string | null; + input?: unknown; +}; + +export type SecurityLogDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + applicationName?: string | null; + identity?: string | null; + action?: string | null; + userId?: string | null; + userName?: string | null; + tenantName?: string | null; + clientId?: string | null; + correlationId?: string | null; + clientIpAddress?: string | null; + browserInfo?: string | null; + creationTime?: string; +}; + +export enum SecurityRuleSet { + None = 0, + Level1 = 1, + Level2 = 2, +} + +export type SendChangePhoneNumberCodeInput = { + newPhoneNumber: string; +}; + +export type SendEmailConfirmCodeDto = { + email: string; + appName: string; + returnUrl?: string | null; + returnUrlHash?: string | null; +}; + +export type SendEmailSigninCodeDto = { + emailAddress: string; +}; + +export type SendPasswordResetCodeDto = { + email: string; + appName: string; + returnUrl?: string | null; + returnUrlHash?: string | null; +}; + +export type SendPhoneRegisterCodeDto = { + phoneNumber: string; +}; + +export type SendPhoneResetPasswordCodeDto = { + phoneNumber: string; +}; + +export type SendPhoneSigninCodeDto = { + phoneNumber: string; +}; + +export type SendTestEmailInput = { + emailAddress: string; +}; + +export type SetTextInput = { + resourceName: string; + key: string; + cultureName: string; + value?: string | null; +}; + +export type SettingDefinitionCreateDto = { + displayName: string; + description?: string | null; + defaultValue?: string | null; + isVisibleToClients?: boolean; + providers?: Array | null; + isInherited?: boolean; + isEncrypted?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; +}; + +export type SettingDefinitionDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + defaultValue?: string | null; + isVisibleToClients?: boolean; + providers?: Array | null; + isInherited?: boolean; + isEncrypted?: boolean; + isStatic?: boolean; +}; + +export type SettingDefinitionUpdateDto = { + displayName: string; + description?: string | null; + defaultValue?: string | null; + isVisibleToClients?: boolean; + providers?: Array | null; + isInherited?: boolean; + isEncrypted?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type SettingDetailsDto = { + name?: string | null; + displayName?: string | null; + description?: string | null; + value?: string | null; + defaultValue?: string | null; + isEncrypted?: boolean; + valueType?: ValueType_1; + slot?: string | null; + options?: Array | null; + providers?: Array | null; + requiredFeatures?: Array | null; + requiredPermissions?: Array | null; +}; + +export type SettingDto = { + displayName?: string | null; + description?: string | null; + details?: Array | null; +}; + +export type SettingGroupDto = { + displayName?: string | null; + description?: string | null; + settings?: Array | null; +}; + +export type SettingGroupResult = { + readonly items?: Array | null; +}; + +export enum Sex { + Male = 0, + Female = 1, + Other = 2, +} + +export type SimpleException = { + type?: Type; + message?: string | null; + stackTrace?: string | null; + innerException?: SimpleException; + data?: { + [key: string]: unknown; + } | null; +}; + +export enum SortBy { + Ascending = 0, + Descending = 1, +} + +export type StructLayoutAttribute = { + readonly typeId?: unknown; + value?: LayoutKind; +}; + +export type SubscriptionsGetByNameDto = { + name: string; +}; + +export type TenantConnectionStringCreateOrUpdate = { + name: string; + value: string; +}; + +export type TenantConnectionStringDto = { + name?: string | null; + value?: string | null; +}; + +export type TenantCreateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + isActive?: boolean; + editionId?: string | null; + enableTime?: string | null; + disableTime?: string | null; + adminEmailAddress: string; + adminPassword: string; + useSharedDatabase?: boolean; + defaultConnectionString?: string | null; + connectionStrings?: { + [key: string]: string; + } | null; +}; + +export type TenantDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + name?: string | null; + normalizedName?: string | null; + editionId?: string | null; + editionName?: string | null; + isActive?: boolean; + enableTime?: string | null; + disableTime?: string | null; + concurrencyStamp?: string | null; +}; + +export type TenantUpdateDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name: string; + isActive?: boolean; + editionId?: string | null; + enableTime?: string | null; + disableTime?: string | null; + concurrencyStamp?: string | null; +}; + +export type TextDifferenceDto = { + cultureName?: string | null; + key?: string | null; + value?: string | null; + resourceName?: string | null; + targetCultureName?: string | null; + targetValue?: string | null; +}; + +export type TextDto = { + key?: string | null; + value?: string | null; + cultureName?: string | null; + resourceName?: string | null; +}; + +export type TextTemplateContentDto = { + name?: string | null; + content?: string | null; + culture?: string | null; +}; + +export type TextTemplateContentUpdateDto = { + culture?: string | null; + content: string; +}; + +export type TextTemplateDefinitionCreateDto = { + displayName: string; + defaultCultureName?: string | null; + localizationResourceName?: string | null; + isInlineLocalized?: boolean; + isLayout?: boolean; + layout?: string | null; + renderEngine?: string | null; + name: string; +}; + +export type TextTemplateDefinitionDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + name?: string | null; + displayName?: string | null; + defaultCultureName?: string | null; + localizationResourceName?: string | null; + renderEngine?: string | null; + isInlineLocalized?: boolean; + isLayout?: boolean; + layout?: string | null; + isStatic?: boolean; + concurrencyStamp?: string | null; +}; + +export type TextTemplateDefinitionUpdateDto = { + displayName: string; + defaultCultureName?: string | null; + localizationResourceName?: string | null; + isInlineLocalized?: boolean; + isLayout?: boolean; + layout?: string | null; + renderEngine?: string | null; + concurrencyStamp?: string | null; +}; + +export type TextTemplateRestoreInput = { + culture?: string | null; +}; + +export type ThemeSettingDto = { + darkMode?: string | null; + projectConfig?: ProjectConfigDto; + beforeMiniInfo?: BeforeMiniStateDto; +}; + +export type TimeSpan = { + ticks?: number; + readonly days?: number; + readonly hours?: number; + readonly milliseconds?: number; + readonly microseconds?: number; + readonly nanoseconds?: number; + readonly minutes?: number; + readonly seconds?: number; + readonly totalDays?: number; + readonly totalHours?: number; + readonly totalMilliseconds?: number; + readonly totalMicroseconds?: number; + readonly totalNanoseconds?: number; + readonly totalMinutes?: number; + readonly totalSeconds?: number; +}; + +export type TimeZone = { + iana?: IanaTimeZone; + windows?: WindowsTimeZone; +}; + +export type TimingDto = { + timeZone?: TimeZone; +}; + +export type TransitionSettingDto = { + enable?: boolean; + basicTransition?: string | null; + openPageLoading?: boolean; + openNProgress?: boolean; +}; + +export type TriggerWorkflowsRequestModel = { + activityType?: string | null; + bookmark?: IBookmark; + correlationId?: string | null; + workflowInstanceId?: string | null; + contextId?: string | null; + input?: unknown; + dispatch?: boolean; +}; + +export type TwoFactorEnabledDto = { + enabled?: boolean; +}; + +export type TwoFactorEnabledDto_1 = { + enabled?: boolean; +}; + +export type Type = { + readonly name?: string | null; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + readonly isInterface?: boolean; + memberType?: MemberTypes; + readonly namespace?: string | null; + readonly assemblyQualifiedName?: string | null; + readonly fullName?: string | null; + assembly?: Assembly; + module?: Module; + readonly isNested?: boolean; + declaringType?: Type; + declaringMethod?: MethodBase; + reflectedType?: Type; + underlyingSystemType?: Type; + readonly isTypeDefinition?: boolean; + readonly isArray?: boolean; + readonly isByRef?: boolean; + readonly isPointer?: boolean; + readonly isConstructedGenericType?: boolean; + readonly isGenericParameter?: boolean; + readonly isGenericTypeParameter?: boolean; + readonly isGenericMethodParameter?: boolean; + readonly isGenericType?: boolean; + readonly isGenericTypeDefinition?: boolean; + readonly isSZArray?: boolean; + readonly isVariableBoundArray?: boolean; + readonly isByRefLike?: boolean; + readonly isFunctionPointer?: boolean; + readonly isUnmanagedFunctionPointer?: boolean; + readonly hasElementType?: boolean; + readonly genericTypeArguments?: Array | null; + readonly genericParameterPosition?: number; + genericParameterAttributes?: GenericParameterAttributes; + attributes?: TypeAttributes; + readonly isAbstract?: boolean; + readonly isImport?: boolean; + readonly isSealed?: boolean; + readonly isSpecialName?: boolean; + readonly isClass?: boolean; + readonly isNestedAssembly?: boolean; + readonly isNestedFamANDAssem?: boolean; + readonly isNestedFamily?: boolean; + readonly isNestedFamORAssem?: boolean; + readonly isNestedPrivate?: boolean; + readonly isNestedPublic?: boolean; + readonly isNotPublic?: boolean; + readonly isPublic?: boolean; + readonly isAutoLayout?: boolean; + readonly isExplicitLayout?: boolean; + readonly isLayoutSequential?: boolean; + readonly isAnsiClass?: boolean; + readonly isAutoClass?: boolean; + readonly isUnicodeClass?: boolean; + readonly isCOMObject?: boolean; + readonly isContextful?: boolean; + readonly isEnum?: boolean; + readonly isMarshalByRef?: boolean; + readonly isPrimitive?: boolean; + readonly isValueType?: boolean; + readonly isSignatureType?: boolean; + readonly isSecurityCritical?: boolean; + readonly isSecuritySafeCritical?: boolean; + readonly isSecurityTransparent?: boolean; + structLayoutAttribute?: StructLayoutAttribute; + typeInitializer?: ConstructorInfo; + typeHandle?: RuntimeTypeHandle; + readonly guid?: string; + baseType?: Type; + /** + * @deprecated + */ + readonly isSerializable?: boolean; + readonly containsGenericParameters?: boolean; + readonly isVisible?: boolean; +}; + +export type TypeApiDescriptionModel = { + baseType?: string | null; + isEnum?: boolean; + enumNames?: Array | null; + enumValues?: Array | null; + genericArguments?: Array | null; + properties?: Array | null; +}; + +export enum TypeAttributes { + NotPublic = 0, + AutoLayout = 1, + AnsiClass = 2, + Class = 3, + Public = 4, + NestedPublic = 5, + NestedPrivate = 6, + NestedFamily = 7, + NestedAssembly = 8, + NestedFamANDAssem = 16, + VisibilityMask = 24, + NestedFamORAssem = 32, + SequentialLayout = 128, + ExplicitLayout = 256, + LayoutMask = 1024, + Interface = 2048, + ClassSemanticsMask = 4096, + Abstract = 8192, + Sealed = 16384, + SpecialName = 65536, + RTSpecialName = 131072, + Import = 196608, + Serializable = 262144, + WindowsRuntime = 264192, + UnicodeClass = 1048576, + AutoClass = 12582912, +} + +export type TypeInfo = { + readonly name?: string | null; + readonly customAttributes?: Array | null; + readonly isCollectible?: boolean; + readonly metadataToken?: number; + readonly isInterface?: boolean; + memberType?: MemberTypes; + readonly namespace?: string | null; + readonly assemblyQualifiedName?: string | null; + readonly fullName?: string | null; + assembly?: Assembly; + module?: Module; + readonly isNested?: boolean; + declaringType?: Type; + declaringMethod?: MethodBase; + reflectedType?: Type; + underlyingSystemType?: Type; + readonly isTypeDefinition?: boolean; + readonly isArray?: boolean; + readonly isByRef?: boolean; + readonly isPointer?: boolean; + readonly isConstructedGenericType?: boolean; + readonly isGenericParameter?: boolean; + readonly isGenericTypeParameter?: boolean; + readonly isGenericMethodParameter?: boolean; + readonly isGenericType?: boolean; + readonly isGenericTypeDefinition?: boolean; + readonly isSZArray?: boolean; + readonly isVariableBoundArray?: boolean; + readonly isByRefLike?: boolean; + readonly isFunctionPointer?: boolean; + readonly isUnmanagedFunctionPointer?: boolean; + readonly hasElementType?: boolean; + readonly genericTypeArguments?: Array | null; + readonly genericParameterPosition?: number; + genericParameterAttributes?: GenericParameterAttributes; + attributes?: TypeAttributes; + readonly isAbstract?: boolean; + readonly isImport?: boolean; + readonly isSealed?: boolean; + readonly isSpecialName?: boolean; + readonly isClass?: boolean; + readonly isNestedAssembly?: boolean; + readonly isNestedFamANDAssem?: boolean; + readonly isNestedFamily?: boolean; + readonly isNestedFamORAssem?: boolean; + readonly isNestedPrivate?: boolean; + readonly isNestedPublic?: boolean; + readonly isNotPublic?: boolean; + readonly isPublic?: boolean; + readonly isAutoLayout?: boolean; + readonly isExplicitLayout?: boolean; + readonly isLayoutSequential?: boolean; + readonly isAnsiClass?: boolean; + readonly isAutoClass?: boolean; + readonly isUnicodeClass?: boolean; + readonly isCOMObject?: boolean; + readonly isContextful?: boolean; + readonly isEnum?: boolean; + readonly isMarshalByRef?: boolean; + readonly isPrimitive?: boolean; + readonly isValueType?: boolean; + readonly isSignatureType?: boolean; + readonly isSecurityCritical?: boolean; + readonly isSecuritySafeCritical?: boolean; + readonly isSecurityTransparent?: boolean; + structLayoutAttribute?: StructLayoutAttribute; + typeInitializer?: ConstructorInfo; + typeHandle?: RuntimeTypeHandle; + readonly guid?: string; + baseType?: Type; + /** + * @deprecated + */ + readonly isSerializable?: boolean; + readonly containsGenericParameters?: boolean; + readonly isVisible?: boolean; + readonly genericTypeParameters?: Array | null; + readonly declaredConstructors?: Array | null; + readonly declaredEvents?: Array | null; + readonly declaredFields?: Array | null; + readonly declaredMembers?: Array | null; + readonly declaredMethods?: Array | null; + readonly declaredNestedTypes?: Array | null; + readonly declaredProperties?: Array | null; + readonly implementedInterfaces?: Array | null; +}; + +export type UpdateFeatureDto = { + name?: string | null; + value?: string | null; +}; + +export type UpdateFeaturesDto = { + features?: Array | null; +}; + +export type UpdatePermissionDto = { + name?: string | null; + isGranted?: boolean; +}; + +export type UpdatePermissionsDto = { + permissions?: Array | null; +}; + +export type UpdateProfileDto = { + readonly extraProperties?: { + [key: string]: unknown; + } | null; + userName?: string | null; + email?: string | null; + name?: string | null; + surname?: string | null; + phoneNumber?: string | null; + concurrencyStamp?: string | null; +}; + +export type UpdateSettingDto = { + name: string; + value?: string | null; +}; + +export type UpdateSettingsDto = { + settings?: Array | null; +}; + +export type UserData = { + id?: string; + tenantId?: string | null; + userName?: string | null; + name?: string | null; + surname?: string | null; + isActive?: boolean; + email?: string | null; + emailConfirmed?: boolean; + phoneNumber?: string | null; + phoneNumberConfirmed?: boolean; + readonly extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type UserFavoriteMenuCreateDto = { + menuId: string; + color?: string | null; + aliasName?: string | null; + icon?: string | null; + framework: string; +}; + +export type UserFavoriteMenuDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + lastModificationTime?: string | null; + lastModifierId?: string | null; + menuId?: string; + userId?: string; + aliasName?: string | null; + color?: string | null; + framework?: string | null; + name?: string | null; + displayName?: string | null; + path?: string | null; + icon?: string | null; +}; + +export type UserFavoriteMenuUpdateDto = { + menuId: string; + color?: string | null; + aliasName?: string | null; + icon?: string | null; + concurrencyStamp?: string | null; +}; + +export type UserFriend = { + tenantId?: string | null; + userId?: string; + userName?: string | null; + avatarUrl?: string | null; + nickName?: string | null; + age?: number; + sex?: Sex; + sign?: string | null; + description?: string | null; + birthday?: string | null; + online?: boolean; + friendId?: string; + black?: boolean; + specialFocus?: boolean; + dontDisturb?: boolean; + remarkName?: string | null; +}; + +export type UserIdentifier = { + userId?: string; + userName?: string | null; +}; + +export type UserJoinGroupDto = { + groupId: number; + joinInfo: string; +}; + +export type UserLoginInfo = { + userNameOrEmailAddress: string; + password: string; + rememberMe?: boolean; +}; + +export type UserMenuInput = { + userId: string; + menuIds: Array; +}; + +export type UserMenuStartupInput = { + userId?: string; +}; + +export type UserNotificationDto = { + name?: string | null; + id?: string | null; + data?: NotificationData; + creationTime?: string; + type?: NotificationType; + lifetime?: NotificationLifetime; + severity?: NotificationSeverity; + state?: NotificationReadState; + contentType?: NotificationContentType; +}; + +export type UserSubscreNotificationDto = { + name?: string | null; +}; + +export type UserSubscriptionsResult = { + isSubscribed?: boolean; +}; + +export enum ValueType { + String = 0, + Numeic = 1, + Boolean = 2, + Date = 3, + DateTime = 4, + Array = 5, + Object = 6, +} + +export enum ValueType_1 { + String = 0, + Number = 1, + Boolean = 2, + Date = 3, + Array = 4, + Option = 5, + Object = 10, +} + +export type Variables = { + readonly data?: { + [key: string]: unknown; + } | null; +}; + +export type VerifyAuthenticatorCodeInput = { + authenticatorCode: string; +}; + +export type VerifyPasswordResetTokenInput = { + userId?: string; + resetToken: string; +}; + +export type VersionOptions = { + readonly isLatest?: boolean; + readonly isLatestOrPublished?: boolean; + readonly isPublished?: boolean; + readonly isDraft?: boolean; + readonly allVersions?: boolean; + readonly version?: number; +}; + +export type WebhookAvailableDto = { + name?: string | null; + displayName?: string | null; + description?: string | null; +}; + +export type WebhookAvailableGroupDto = { + name?: string | null; + displayName?: string | null; + webhooks?: Array | null; +}; + +export type WebhookDefinition = { + id?: string | null; + tenantId?: string | null; + name?: string | null; + path?: string | null; + description?: string | null; + payloadTypeName?: string | null; + isEnabled?: boolean; +}; + +export type WebhookDefinitionCreateDto = { + displayName: string; + description?: string | null; + isEnabled?: boolean; + requiredFeatures?: Array | null; + extraProperties?: { + [key: string]: unknown; + } | null; + groupName: string; + name: string; +}; + +export type WebhookDefinitionDto = { + groupName?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + isEnabled?: boolean; + isStatic?: boolean; + requiredFeatures?: Array | null; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type WebhookDefinitionUpdateDto = { + displayName: string; + description?: string | null; + isEnabled?: boolean; + requiredFeatures?: Array | null; + extraProperties?: { + [key: string]: unknown; + } | null; + concurrencyStamp?: string | null; +}; + +export type WebhookEventRecordDto = { + id?: string; + tenantId?: string | null; + webhookName?: string | null; + data?: string | null; + creationTime?: string; +}; + +export type WebhookGroupDefinitionCreateDto = { + displayName: string; + extraProperties?: { + [key: string]: unknown; + } | null; + name: string; +}; + +export type WebhookGroupDefinitionDto = { + name?: string | null; + displayName?: string | null; + isStatic?: boolean; + extraProperties?: { + [key: string]: unknown; + } | null; +}; + +export type WebhookGroupDefinitionUpdateDto = { + displayName: string; + extraProperties?: { + [key: string]: unknown; + } | null; + concurrencyStamp?: string | null; +}; + +export type WebhookPublishInput = { + webhookName: string; + data: string; + sendExactSameData?: boolean; + header?: WebhooksHeaderInput; + tenantIds?: Array | null; +}; + +export type WebhookSendRecordDeleteManyInput = { + recordIds?: Array | null; +}; + +export type WebhookSendRecordDto = { + id?: string; + tenantId?: string | null; + webhookEventId?: string; + webhookSubscriptionId?: string; + response?: string | null; + responseStatusCode?: HttpStatusCode; + creationTime?: string; + lastModificationTime?: string | null; + sendExactSameData?: boolean; + requestHeaders?: { + [key: string]: string; + } | null; + responseHeaders?: { + [key: string]: string; + } | null; + webhookEvent?: WebhookEventRecordDto; +}; + +export type WebhookSendRecordResendManyInput = { + recordIds?: Array | null; +}; + +export type WebhooksHeaderInput = { + useOnlyGivenHeaders?: boolean; + headers?: { + [key: string]: string; + } | null; +}; + +export type WebhookSubscriptionCreateInput = { + webhookUri: string; + secret?: string | null; + description?: string | null; + timeoutDuration?: number | null; + isActive?: boolean; + tenantId?: string | null; + webhooks?: Array | null; + headers?: { + [key: string]: string; + } | null; +}; + +export type WebhookSubscriptionDeleteManyInput = { + recordIds?: Array | null; +}; + +export type WebhookSubscriptionDto = { + id?: string; + creationTime?: string; + creatorId?: string | null; + tenantId?: string | null; + webhookUri?: string | null; + secret?: string | null; + isActive?: boolean; + description?: string | null; + webhooks?: Array | null; + headers?: { + [key: string]: string; + } | null; + concurrencyStamp?: string | null; + timeoutDuration?: number | null; +}; + +export type WebhookSubscriptionUpdateInput = { + webhookUri: string; + secret?: string | null; + description?: string | null; + timeoutDuration?: number | null; + isActive?: boolean; + tenantId?: string | null; + webhooks?: Array | null; + headers?: { + [key: string]: string; + } | null; + concurrencyStamp?: string | null; +}; + +export type WindowsTimeZone = { + timeZoneId?: string | null; +}; + +export type WorkflowBlueprintModel = { + id?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + type?: string | null; + parentId?: string | null; + persistWorkflow?: boolean; + loadWorkflowContext?: boolean; + saveWorkflowContext?: boolean; + inputProperties?: Variables; + outputProperties?: Variables; + x?: number | null; + y?: number | null; + activities?: Array | null; + connections?: Array | null; + version?: number; + tenantId?: string | null; + isSingleton?: boolean; + isEnabled?: boolean; + isPublished?: boolean; + isLatest?: boolean; + isDisabled?: boolean; + variables?: Variables; + contextOptions?: WorkflowContextOptions; + persistenceBehavior?: WorkflowPersistenceBehavior; + deleteCompletedInstances?: boolean; + customAttributes?: Variables; +}; + +export type WorkflowBlueprintSummaryModel = { + id?: string | null; + versionId?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + version?: number; + tenantId?: string | null; + isSingleton?: boolean; + isPublished?: boolean; + isLatest?: boolean; + isDisabled?: boolean; +}; + +export enum WorkflowContextFidelity { + Burst = 0, + Activity = 1, +} + +export type WorkflowContextOptions = { + contextType?: Type; + contextFidelity?: WorkflowContextFidelity; +}; + +export type WorkflowDefinition = { + id?: string | null; + definitionId?: string | null; + readonly versionId?: string | null; + tenantId?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + channel?: string | null; + version?: number; + variables?: Variables; + customAttributes?: Variables; + contextOptions?: WorkflowContextOptions; + isSingleton?: boolean; + persistenceBehavior?: WorkflowPersistenceBehavior; + deleteCompletedInstances?: boolean; + isPublished?: boolean; + isLatest?: boolean; + tag?: string | null; + createdAt?: Instant; + activities?: Array | null; + connections?: Array | null; +}; + +export enum WorkflowDefinitionOrderBy { + Name = 0, + Description = 1, + CreatedAt = 2, +} + +export type WorkflowDefinitionSummaryModel = { + id?: string | null; + definitionId?: string | null; + tenantId?: string | null; + name?: string | null; + displayName?: string | null; + description?: string | null; + version?: number; + isSingleton?: boolean; + persistenceBehavior?: WorkflowPersistenceBehavior; + isPublished?: boolean; + isLatest?: boolean; + customAttributes?: Variables; + createdAt?: Instant; +}; + +export type WorkflowDefinitionVersionModel = { + id?: string | null; + definitionId?: string | null; + version?: number; + isLatest?: boolean; + isPublished?: boolean; + createdAt?: Instant; +}; + +export type WorkflowExecutionLogRecord = { + id?: string | null; + readonly tenantId?: string | null; + workflowInstanceId?: string | null; + activityId?: string | null; + activityType?: string | null; + timestamp?: Instant; + eventName?: string | null; + message?: string | null; + source?: string | null; + data?: { + [key: string]: JToken; + } | null; +}; + +export type WorkflowFault = { + exception?: SimpleException; + message?: string | null; + faultedActivityId?: string | null; + activityInput?: unknown; + resuming?: boolean; +}; + +export type WorkflowInput = { + input?: unknown; + storageProviderName?: string | null; +}; + +export type WorkflowInputReference = { + providerName?: string | null; +}; + +export type WorkflowInstance = { + id?: string | null; + definitionId?: string | null; + definitionVersionId?: string | null; + tenantId?: string | null; + version?: number; + workflowStatus?: WorkflowStatus; + correlationId?: string | null; + contextType?: string | null; + contextId?: string | null; + name?: string | null; + createdAt?: Instant; + lastExecutedAt?: Instant; + finishedAt?: Instant; + cancelledAt?: Instant; + faultedAt?: Instant; + variables?: Variables; + input?: WorkflowInputReference; + output?: WorkflowOutputReference; + activityData?: { + [key: string]: { + [key: string]: unknown; + }; + } | null; + metadata?: { + [key: string]: unknown; + } | null; + blockingActivities?: Array | null; + fault?: WorkflowFault; + faults?: Array | null; + scheduledActivities?: Array | null; + scopes?: Array | null; + currentActivity?: ScheduledActivity; + lastExecutedActivityId?: string | null; +}; + +export enum WorkflowInstanceOrderBy { + Started = 0, + LastExecuted = 1, + Finished = 2, +} + +export type WorkflowInstanceSummaryModel = { + id?: string | null; + definitionId?: string | null; + definitionVersionId?: string | null; + tenantId?: string | null; + version?: number; + workflowStatus?: WorkflowStatus; + correlationId?: string | null; + contextType?: string | null; + contextId?: string | null; + name?: string | null; + createdAt?: Instant; + lastExecutedAt?: Instant; + finishedAt?: Instant; + cancelledAt?: Instant; + faultedAt?: Instant; + metadata?: { + [key: string]: unknown; + } | null; +}; + +export type WorkflowOutputReference = { + providerName?: string | null; + activityId?: string | null; +}; + +export enum WorkflowPersistenceBehavior { + Suspended = 0, + WorkflowBurst = 1, + WorkflowPassCompleted = 2, + ActivityExecuted = 3, +} + +export type WorkflowProviderDescriptor = { + name?: string | null; + displayName?: string | null; +}; + +export enum WorkflowStatus { + Idle = 0, + Running = 1, + Finished = 2, + Suspended = 3, + Faulted = 4, + Cancelled = 5, +} + +export type WorkflowStorageDescriptor = { + name?: string | null; + displayName?: string | null; +}; + +export type WrapResult = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: unknown; +}; + +export type WrapResultOfAbpLoginResult = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: AbpLoginResult; +}; + +export type WrapResultOfApplicationConfigurationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ApplicationConfigurationDto; +}; + +export type WrapResultOfApplicationLocalizationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ApplicationLocalizationDto; +}; + +export type WrapResultOfAuditLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: AuditLogDto; +}; + +export type WrapResultOfAuthenticatorDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: AuthenticatorDto; +}; + +export type WrapResultOfAuthenticatorRecoveryCodeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: AuthenticatorRecoveryCodeDto; +}; + +export type WrapResultOfBackgroundJobActionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: BackgroundJobActionDto; +}; + +export type WrapResultOfBackgroundJobInfoDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: BackgroundJobInfoDto; +}; + +export type WrapResultOfBackgroundJobLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: BackgroundJobLogDto; +}; + +export type WrapResultOfBoolean = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: boolean; +}; + +export type WrapResultOfCacheKeysDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: CacheKeysDto; +}; + +export type WrapResultOfCacheValueDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: CacheValueDto; +}; + +export type WrapResultOfChatMessageSendResultDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ChatMessageSendResultDto; +}; + +export type WrapResultOfDataDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: DataDto; +}; + +export type WrapResultOfEditionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: EditionDto; +}; + +export type WrapResultOfEntityChangeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: EntityChangeDto; +}; + +export type WrapResultOfEntityChangeWithUsernameDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: EntityChangeWithUsernameDto; +}; + +export type WrapResultOfEntityTypeInfoDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: EntityTypeInfoDto; +}; + +export type WrapResultOfFeatureDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: FeatureDefinitionDto; +}; + +export type WrapResultOfFeatureGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: FeatureGroupDefinitionDto; +}; + +export type WrapResultOfFeedbackAttachmentTempFileDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: FeedbackAttachmentTempFileDto; +}; + +export type WrapResultOfFeedbackDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: FeedbackDto; +}; + +export type WrapResultOfFileShareDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: FileShareDto; +}; + +export type WrapResultOfFindTenantResultDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: FindTenantResultDto; +}; + +export type WrapResultOfGetFeatureListResultDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: GetFeatureListResultDto; +}; + +export type WrapResultOfGetPermissionListResultDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: GetPermissionListResultDto; +}; + +export type WrapResultOfGroup = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: Group; +}; + +export type WrapResultOfIdentityClaimTypeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: IdentityClaimTypeDto; +}; + +export type WrapResultOfIdentityRoleDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: IdentityRoleDto; +}; + +export type WrapResultOfIdentityUserDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: IdentityUserDto; +}; + +export type WrapResultOfInt64 = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: number; +}; + +export type WrapResultOfLanguageDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: LanguageDto; +}; + +export type WrapResultOfLayoutDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: LayoutDto; +}; + +export type WrapResultOfListResultDtoOfBackgroundJobActionDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfBackgroundJobActionDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfBackgroundJobActionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfBackgroundJobActionDto; +}; + +export type WrapResultOfListResultDtoOfBackgroundJobDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfBackgroundJobDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfDataDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfDataDto; +}; + +export type WrapResultOfListResultDtoOfDynamicParamterDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfDynamicParamterDto; +}; + +export type WrapResultOfListResultDtoOfEntityChangeWithUsernameDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfEntityChangeWithUsernameDto; +}; + +export type WrapResultOfListResultDtoOfFeatureDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfFeatureDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfFeatureGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfFeatureGroupDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfGroup = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfGroup; +}; + +export type WrapResultOfListResultDtoOfIdentityClaimDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfIdentityClaimDto; +}; + +export type WrapResultOfListResultDtoOfIdentityClaimTypeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfIdentityClaimTypeDto; +}; + +export type WrapResultOfListResultDtoOfIdentityRoleDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfIdentityRoleDto; +}; + +export type WrapResultOfListResultDtoOfLanguageDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfLanguageDto; +}; + +export type WrapResultOfListResultDtoOfLastChatMessage = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfLastChatMessage; +}; + +export type WrapResultOfListResultDtoOfLayoutDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfLayoutDto; +}; + +export type WrapResultOfListResultDtoOfMenuDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfMenuDto; +}; + +export type WrapResultOfListResultDtoOfMyFileShareDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfMyFileShareDto; +}; + +export type WrapResultOfListResultDtoOfNameValue = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfNameValue; +}; + +export type WrapResultOfListResultDtoOfNotificationDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfNotificationDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfNotificationGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfNotificationGroupDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfNotificationGroupDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfNotificationGroupDto; +}; + +export type WrapResultOfListResultDtoOfNotificationTemplateDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfNotificationTemplateDto; +}; + +export type WrapResultOfListResultDtoOfOrganizationUnitDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfOrganizationUnitDto; +}; + +export type WrapResultOfListResultDtoOfOssObjectDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfOssObjectDto; +}; + +export type WrapResultOfListResultDtoOfPermissionDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfPermissionDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfPermissionGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfPermissionGroupDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfResourceDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfResourceDto; +}; + +export type WrapResultOfListResultDtoOfSettingDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfSettingDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfString = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfString; +}; + +export type WrapResultOfListResultDtoOfTenantConnectionStringDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfTenantConnectionStringDto; +}; + +export type WrapResultOfListResultDtoOfTextDifferenceDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfTextDifferenceDto; +}; + +export type WrapResultOfListResultDtoOfTextTemplateDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfTextTemplateDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfUserData = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfUserData; +}; + +export type WrapResultOfListResultDtoOfUserFavoriteMenuDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfUserFavoriteMenuDto; +}; + +export type WrapResultOfListResultDtoOfUserFriend = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfUserFriend; +}; + +export type WrapResultOfListResultDtoOfUserSubscreNotificationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfUserSubscreNotificationDto; +}; + +export type WrapResultOfListResultDtoOfWebhookAvailableGroupDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfWebhookAvailableGroupDto; +}; + +export type WrapResultOfListResultDtoOfWebhookDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfWebhookDefinitionDto; +}; + +export type WrapResultOfListResultDtoOfWebhookGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ListResultDtoOfWebhookGroupDefinitionDto; +}; + +export type WrapResultOfLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: LogDto; +}; + +export type WrapResultOfMenuDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: MenuDto; +}; + +export type WrapResultOfNotificationDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: NotificationDefinitionDto; +}; + +export type WrapResultOfNotificationGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: NotificationGroupDefinitionDto; +}; + +export type WrapResultOfOpenIddictApplicationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OpenIddictApplicationDto; +}; + +export type WrapResultOfOpenIddictAuthorizationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OpenIddictAuthorizationDto; +}; + +export type WrapResultOfOpenIddictScopeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OpenIddictScopeDto; +}; + +export type WrapResultOfOpenIddictTokenDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OpenIddictTokenDto; +}; + +export type WrapResultOfOrganizationUnitDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OrganizationUnitDto; +}; + +export type WrapResultOfOrganizationUnitEntityRuleDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OrganizationUnitEntityRuleDto; +}; + +export type WrapResultOfOssContainerDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OssContainerDto; +}; + +export type WrapResultOfOssContainersResultDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OssContainersResultDto; +}; + +export type WrapResultOfOssObjectDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OssObjectDto; +}; + +export type WrapResultOfOssObjectsResultDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: OssObjectsResultDto; +}; + +export type WrapResultOfPackageBlobDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PackageBlobDto; +}; + +export type WrapResultOfPackageDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PackageDto; +}; + +export type WrapResultOfPagedResultDtoOfAuditLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfAuditLogDto; +}; + +export type WrapResultOfPagedResultDtoOfBackgroundJobInfoDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfBackgroundJobInfoDto; +}; + +export type WrapResultOfPagedResultDtoOfBackgroundJobLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfBackgroundJobLogDto; +}; + +export type WrapResultOfPagedResultDtoOfChatMessage = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfChatMessage; +}; + +export type WrapResultOfPagedResultDtoOfDataDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfDataDto; +}; + +export type WrapResultOfPagedResultDtoOfEditionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfEditionDto; +}; + +export type WrapResultOfPagedResultDtoOfEntityChangeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfEntityChangeDto; +}; + +export type WrapResultOfPagedResultDtoOfEntityTypeInfoDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfEntityTypeInfoDto; +}; + +export type WrapResultOfPagedResultDtoOfFeedbackDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfFeedbackDto; +}; + +export type WrapResultOfPagedResultDtoOfGroup = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfGroup; +}; + +export type WrapResultOfPagedResultDtoOfGroupUserCard = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfGroupUserCard; +}; + +export type WrapResultOfPagedResultDtoOfIdentityClaimTypeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfIdentityClaimTypeDto; +}; + +export type WrapResultOfPagedResultDtoOfIdentityRoleDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfIdentityRoleDto; +}; + +export type WrapResultOfPagedResultDtoOfIdentitySessionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfIdentitySessionDto; +}; + +export type WrapResultOfPagedResultDtoOfIdentitySessionDto_1 = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfIdentitySessionDto_1; +}; + +export type WrapResultOfPagedResultDtoOfIdentityUserDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfIdentityUserDto; +}; + +export type WrapResultOfPagedResultDtoOfLayoutDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfLayoutDto; +}; + +export type WrapResultOfPagedResultDtoOfLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfLogDto; +}; + +export type WrapResultOfPagedResultDtoOfMenuDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfMenuDto; +}; + +export type WrapResultOfPagedResultDtoOfOpenIddictApplicationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfOpenIddictApplicationDto; +}; + +export type WrapResultOfPagedResultDtoOfOpenIddictAuthorizationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfOpenIddictAuthorizationDto; +}; + +export type WrapResultOfPagedResultDtoOfOpenIddictScopeDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfOpenIddictScopeDto; +}; + +export type WrapResultOfPagedResultDtoOfOpenIddictTokenDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfOpenIddictTokenDto; +}; + +export type WrapResultOfPagedResultDtoOfOrganizationUnitDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfOrganizationUnitDto; +}; + +export type WrapResultOfPagedResultDtoOfPackageDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfPackageDto; +}; + +export type WrapResultOfPagedResultDtoOfSecurityLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfSecurityLogDto; +}; + +export type WrapResultOfPagedResultDtoOfTenantDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfTenantDto; +}; + +export type WrapResultOfPagedResultDtoOfUserFriend = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfUserFriend; +}; + +export type WrapResultOfPagedResultDtoOfUserNotificationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfUserNotificationDto; +}; + +export type WrapResultOfPagedResultDtoOfUserSubscreNotificationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfUserSubscreNotificationDto; +}; + +export type WrapResultOfPagedResultDtoOfWebhookSendRecordDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfWebhookSendRecordDto; +}; + +export type WrapResultOfPagedResultDtoOfWebhookSubscriptionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PagedResultDtoOfWebhookSubscriptionDto; +}; + +export type WrapResultOfPermissionDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PermissionDefinitionDto; +}; + +export type WrapResultOfPermissionGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: PermissionGroupDefinitionDto; +}; + +export type WrapResultOfProfileDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ProfileDto; +}; + +export type WrapResultOfResourceDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ResourceDto; +}; + +export type WrapResultOfRoleEntityRuleDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: RoleEntityRuleDto; +}; + +export type WrapResultOfSecurityLogDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: SecurityLogDto; +}; + +export type WrapResultOfSettingDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: SettingDefinitionDto; +}; + +export type WrapResultOfSettingGroupResult = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: SettingGroupResult; +}; + +export type WrapResultOfTenantConnectionStringDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: TenantConnectionStringDto; +}; + +export type WrapResultOfTenantDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: TenantDto; +}; + +export type WrapResultOfTextDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: TextDto; +}; + +export type WrapResultOfTextTemplateContentDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: TextTemplateContentDto; +}; + +export type WrapResultOfTextTemplateDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: TextTemplateDefinitionDto; +}; + +export type WrapResultOfThemeSettingDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: ThemeSettingDto; +}; + +export type WrapResultOfTwoFactorEnabledDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: TwoFactorEnabledDto; +}; + +export type WrapResultOfUserData = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: UserData; +}; + +export type WrapResultOfUserFavoriteMenuDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: UserFavoriteMenuDto; +}; + +export type WrapResultOfUserFriend = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: UserFriend; +}; + +export type WrapResultOfUserNotificationDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: UserNotificationDto; +}; + +export type WrapResultOfUserSubscriptionsResult = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: UserSubscriptionsResult; +}; + +export type WrapResultOfWebhookDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: WebhookDefinitionDto; +}; + +export type WrapResultOfWebhookGroupDefinitionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: WebhookGroupDefinitionDto; +}; + +export type WrapResultOfWebhookSendRecordDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: WebhookSendRecordDto; +}; + +export type WrapResultOfWebhookSubscriptionDto = { + code?: string | null; + message?: string | null; + details?: string | null; + result?: WebhookSubscriptionDto; +}; + +export type AbpApiDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + IncludeTypes?: boolean; + }; +}; + +export type AbpApiDefinitionGetResponse = ApplicationApiDescriptionModel; + +export type AbpApiDefinitionGetError = RemoteServiceErrorResponse; + +export type AbpApplicationConfigurationGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + IncludeLocalizationResources?: boolean; + }; +}; + +export type AbpApplicationConfigurationGetResponse = WrapResultOfApplicationConfigurationDto; + +export type AbpApplicationConfigurationGetError = WrapResult; + +export type AbpApplicationLocalizationGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + CultureName: string; + OnlyDynamics?: boolean; + }; +}; + +export type AbpApplicationLocalizationGetResponse = WrapResultOfApplicationLocalizationDto; + +export type AbpApplicationLocalizationGetError = WrapResult; + +export type AbpTenantFindTenantByNameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type AbpTenantFindTenantByNameResponse = WrapResultOfFindTenantResultDto; + +export type AbpTenantFindTenantByNameError = WrapResult; + +export type AbpTenantFindTenantByIdData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type AbpTenantFindTenantByIdResponse = WrapResultOfFindTenantResultDto; + +export type AbpTenantFindTenantByIdError = WrapResult; + +export type AccountRegisterData = { + body?: PhoneRegisterDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountRegisterResponse = WrapResult; + +export type AccountRegisterError = WrapResult; + +export type AccountResetPasswordData = { + body?: PhoneResetPasswordDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountResetPasswordResponse = WrapResult; + +export type AccountResetPasswordError = WrapResult; + +export type AccountSendPhoneSigninCodeData = { + body?: SendPhoneSigninCodeDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountSendPhoneSigninCodeResponse = WrapResult; + +export type AccountSendPhoneSigninCodeError = WrapResult; + +export type AccountSendEmailSigninCodeData = { + body?: SendEmailSigninCodeDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountSendEmailSigninCodeResponse = WrapResult; + +export type AccountSendEmailSigninCodeError = WrapResult; + +export type AccountSendPhoneRegisterCodeData = { + body?: SendPhoneRegisterCodeDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountSendPhoneRegisterCodeResponse = WrapResult; + +export type AccountSendPhoneRegisterCodeError = WrapResult; + +export type AccountSendPhoneResetPasswordCodeData = { + body?: SendPhoneResetPasswordCodeDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountSendPhoneResetPasswordCodeResponse = WrapResult; + +export type AccountSendPhoneResetPasswordCodeError = WrapResult; + +export type AccountGetTwoFactorProvidersData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + UserId: string; + }; +}; + +export type AccountGetTwoFactorProvidersResponse = WrapResultOfListResultDtoOfNameValue; + +export type AccountGetTwoFactorProvidersError = WrapResult; + +export type AccountRegister1Data = { + body?: RegisterDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountRegister1Response = WrapResultOfIdentityUserDto; + +export type AccountRegister1Error = WrapResult; + +export type AccountSendPasswordResetCodeData = { + body?: SendPasswordResetCodeDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountSendPasswordResetCodeResponse = WrapResult; + +export type AccountSendPasswordResetCodeError = WrapResult; + +export type AccountVerifyPasswordResetTokenData = { + body?: VerifyPasswordResetTokenInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountVerifyPasswordResetTokenResponse = WrapResultOfBoolean; + +export type AccountVerifyPasswordResetTokenError = WrapResult; + +export type AccountResetPassword1Data = { + body?: ResetPasswordDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type AccountResetPassword1Response = WrapResult; + +export type AccountResetPassword1Error = WrapResult; + +export type AuditLogDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type AuditLogDeleteResponse = WrapResult; + +export type AuditLogDeleteError = WrapResult; + +export type AuditLogGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type AuditLogGetResponse = WrapResultOfAuditLogDto; + +export type AuditLogGetError = WrapResult; + +export type AuditLogGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ApplicationName?: string; + ClientId?: string; + ClientIpAddress?: string; + CorrelationId?: string; + EndTime?: string; + HasException?: boolean; + HttpMethod?: string; + HttpStatusCode?: HttpStatusCode; + MaxExecutionDuration?: number; + MaxResultCount?: number; + MinExecutionDuration?: number; + SkipCount?: number; + Sorting?: string; + StartTime?: string; + Url?: string; + UserId?: string; + UserName?: string; + }; +}; + +export type AuditLogGetListResponse = WrapResultOfPagedResultDtoOfAuditLogDto; + +export type AuditLogGetListError = WrapResult; + +export type BackgroundJobActionAddActionData = { + body?: BackgroundJobActionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + jobId: string; + }; +}; + +export type BackgroundJobActionAddActionResponse = WrapResultOfBackgroundJobActionDto; + +export type BackgroundJobActionAddActionError = WrapResult; + +export type BackgroundJobActionGetActionsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + jobId: string; + }; +}; + +export type BackgroundJobActionGetActionsResponse = WrapResultOfListResultDtoOfBackgroundJobActionDto; + +export type BackgroundJobActionGetActionsError = WrapResult; + +export type BackgroundJobActionDeleteActionData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobActionDeleteActionResponse = WrapResult; + +export type BackgroundJobActionDeleteActionError = WrapResult; + +export type BackgroundJobActionUpdateActionData = { + body?: BackgroundJobActionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobActionUpdateActionResponse = WrapResultOfBackgroundJobActionDto; + +export type BackgroundJobActionUpdateActionError = WrapResult; + +export type BackgroundJobActionGetDefinitionsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Type?: JobActionType; + }; +}; + +export type BackgroundJobActionGetDefinitionsResponse = WrapResultOfListResultDtoOfBackgroundJobActionDefinitionDto; + +export type BackgroundJobActionGetDefinitionsError = WrapResult; + +export type BackgroundJobInfoCreateData = { + body?: BackgroundJobInfoCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoCreateResponse = WrapResultOfBackgroundJobInfoDto; + +export type BackgroundJobInfoCreateError = WrapResult; + +export type BackgroundJobInfoGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + BeginCreationTime?: string; + BeginLastRunTime?: string; + BeginTime?: string; + EndCreationTime?: string; + EndLastRunTime?: string; + EndTime?: string; + Filter?: string; + Group?: string; + IsAbandoned?: boolean; + JobType?: JobType; + MaxResultCount?: number; + Name?: string; + Priority?: JobPriority; + SkipCount?: number; + Sorting?: string; + Source?: JobSource; + Status?: JobStatus; + Type?: string; + }; +}; + +export type BackgroundJobInfoGetListResponse = WrapResultOfPagedResultDtoOfBackgroundJobInfoDto; + +export type BackgroundJobInfoGetListError = WrapResult; + +export type BackgroundJobInfoDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoDeleteResponse = WrapResult; + +export type BackgroundJobInfoDeleteError = WrapResult; + +export type BackgroundJobInfoGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoGetResponse = WrapResultOfBackgroundJobInfoDto; + +export type BackgroundJobInfoGetError = WrapResult; + +export type BackgroundJobInfoUpdateData = { + body?: BackgroundJobInfoUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoUpdateResponse = WrapResultOfBackgroundJobInfoDto; + +export type BackgroundJobInfoUpdateError = WrapResult; + +export type BackgroundJobInfoPauseData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoPauseResponse = WrapResult; + +export type BackgroundJobInfoPauseError = WrapResult; + +export type BackgroundJobInfoResumeData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoResumeResponse = WrapResult; + +export type BackgroundJobInfoResumeError = WrapResult; + +export type BackgroundJobInfoTriggerData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoTriggerResponse = WrapResult; + +export type BackgroundJobInfoTriggerError = WrapResult; + +export type BackgroundJobInfoStopData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoStopResponse = WrapResult; + +export type BackgroundJobInfoStopError = WrapResult; + +export type BackgroundJobInfoStartData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type BackgroundJobInfoStartResponse = WrapResult; + +export type BackgroundJobInfoStartError = WrapResult; + +export type BackgroundJobInfoBulkStopData = { + body?: BackgroundJobInfoBatchInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoBulkStopResponse = WrapResult; + +export type BackgroundJobInfoBulkStopError = WrapResult; + +export type BackgroundJobInfoBulkStartData = { + body?: BackgroundJobInfoBatchInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoBulkStartResponse = WrapResult; + +export type BackgroundJobInfoBulkStartError = WrapResult; + +export type BackgroundJobInfoBulkTriggerData = { + body?: BackgroundJobInfoBatchInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoBulkTriggerResponse = WrapResult; + +export type BackgroundJobInfoBulkTriggerError = WrapResult; + +export type BackgroundJobInfoBulkResumeData = { + body?: BackgroundJobInfoBatchInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoBulkResumeResponse = WrapResult; + +export type BackgroundJobInfoBulkResumeError = WrapResult; + +export type BackgroundJobInfoBulkPauseData = { + body?: BackgroundJobInfoBatchInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoBulkPauseResponse = WrapResult; + +export type BackgroundJobInfoBulkPauseError = WrapResult; + +export type BackgroundJobInfoBulkDeleteData = { + body?: BackgroundJobInfoBatchInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoBulkDeleteResponse = WrapResult; + +export type BackgroundJobInfoBulkDeleteError = WrapResult; + +export type BackgroundJobInfoGetDefinitionsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoGetDefinitionsResponse = WrapResultOfListResultDtoOfBackgroundJobDefinitionDto; + +export type BackgroundJobInfoGetDefinitionsError = WrapResult; + +export type BackgroundJobInfoGetAvailableFieldsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoGetAvailableFieldsResponse = WrapResultOfListResultDtoOfDynamicParamterDto; + +export type BackgroundJobInfoGetAvailableFieldsError = WrapResult; + +export type BackgroundJobInfoSearchData = { + body?: GetListByDynamicQueryableInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type BackgroundJobInfoSearchResponse = WrapResultOfPagedResultDtoOfBackgroundJobInfoDto; + +export type BackgroundJobInfoSearchError = WrapResult; + +export type BackgroundJobLogDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: number; + }; +}; + +export type BackgroundJobLogDeleteResponse = WrapResult; + +export type BackgroundJobLogDeleteError = WrapResult; + +export type BackgroundJobLogGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: number; + }; +}; + +export type BackgroundJobLogGetResponse = WrapResultOfBackgroundJobLogDto; + +export type BackgroundJobLogGetError = WrapResult; + +export type BackgroundJobLogGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + BeginRunTime?: string; + EndRunTime?: string; + Filter?: string; + Group?: string; + HasExceptions?: boolean; + JobId?: string; + MaxResultCount?: number; + Name?: string; + SkipCount?: number; + Sorting?: string; + Type?: string; + }; +}; + +export type BackgroundJobLogGetListResponse = WrapResultOfPagedResultDtoOfBackgroundJobLogDto; + +export type BackgroundJobLogGetListError = WrapResult; + +export type BackupHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; + query?: { + ids?: string; + version?: VersionOptions; + }; +}; + +export type BackupHandleResponse = unknown; + +export type BackupHandleError = ProblemDetails; + +export type BulkCancelHandleData = { + body?: BulkCancelWorkflowsRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type BulkCancelHandleResponse = unknown; + +export type BulkCancelHandleError = unknown; + +export type BulkDeleteHandleData = { + body?: BulkDeleteWorkflowsRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type BulkDeleteHandleResponse = unknown; + +export type BulkDeleteHandleError = unknown; + +export type BulkRetryHandleData = { + body?: BulkRetryWorkflowsRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type BulkRetryHandleResponse = unknown; + +export type BulkRetryHandleError = unknown; + +export type CacheGetKeysData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + Marker?: string; + Prefix?: string; + }; +}; + +export type CacheGetKeysResponse = WrapResultOfCacheKeysDto; + +export type CacheGetKeysError = WrapResult; + +export type CacheGetValueData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Key: string; + }; +}; + +export type CacheGetValueResponse = WrapResultOfCacheValueDto; + +export type CacheGetValueError = WrapResult; + +export type CacheSetData = { + body?: CacheSetInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type CacheSetResponse = WrapResult; + +export type CacheSetError = WrapResult; + +export type CacheRefreshData = { + body?: CacheRefreshInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type CacheRefreshResponse = WrapResult; + +export type CacheRefreshError = WrapResult; + +export type CacheRemoveData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Key: string; + }; +}; + +export type CacheRemoveResponse = WrapResult; + +export type CacheRemoveError = WrapResult; + +export type CancelHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; +}; + +export type CancelHandleResponse = unknown; + +export type CancelHandleError = ProblemDetails; + +export type ChatGetMyGroupMessageData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Filter?: string; + GroupId: number; + MaxResultCount?: number; + MessageType?: MessageType; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type ChatGetMyGroupMessageResponse = WrapResultOfPagedResultDtoOfChatMessage; + +export type ChatGetMyGroupMessageError = WrapResult; + +export type ChatGetMyChatMessageData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Filter?: string; + MaxResultCount?: number; + MessageType?: MessageType; + ReceiveUserId: string; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type ChatGetMyChatMessageResponse = WrapResultOfPagedResultDtoOfChatMessage; + +export type ChatGetMyChatMessageError = WrapResult; + +export type ChatGetMyLastChatMessageData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + MaxResultCount?: number; + Sorting?: string; + State?: MessageState; + }; +}; + +export type ChatGetMyLastChatMessageResponse = WrapResultOfListResultDtoOfLastChatMessage; + +export type ChatGetMyLastChatMessageError = WrapResult; + +export type ChatSendMessageData = { + body?: ChatMessage; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ChatSendMessageResponse = WrapResultOfChatMessageSendResultDto; + +export type ChatSendMessageError = WrapResult; + +export type ClaimChangeAvatarData = { + body?: ChangeAvatarInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ClaimChangeAvatarResponse = WrapResult; + +export type ClaimChangeAvatarError = WrapResult; + +export type ClaimTypeCreateData = { + body?: IdentityClaimTypeCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ClaimTypeCreateResponse = WrapResultOfIdentityClaimTypeDto; + +export type ClaimTypeCreateError = WrapResult; + +export type ClaimTypeGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type ClaimTypeGetListResponse = WrapResultOfPagedResultDtoOfIdentityClaimTypeDto; + +export type ClaimTypeGetListError = WrapResult; + +export type ClaimTypeDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type ClaimTypeDeleteResponse = WrapResult; + +export type ClaimTypeDeleteError = WrapResult; + +export type ClaimTypeGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type ClaimTypeGetResponse = WrapResultOfIdentityClaimTypeDto; + +export type ClaimTypeGetError = WrapResult; + +export type ClaimTypeUpdateData = { + body?: IdentityClaimTypeUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type ClaimTypeUpdateResponse = WrapResultOfIdentityClaimTypeDto; + +export type ClaimTypeUpdateError = WrapResult; + +export type ClaimTypeGetAllListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ClaimTypeGetAllListResponse = WrapResultOfListResultDtoOfIdentityClaimTypeDto; + +export type ClaimTypeGetAllListError = WrapResult; + +export type DataCreateData = { + body?: DataCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type DataCreateResponse = WrapResultOfDataDto; + +export type DataCreateError = WrapResult; + +export type DataGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type DataGetListResponse = WrapResultOfPagedResultDtoOfDataDto; + +export type DataGetListError = WrapResult; + +export type DataCreateItemData = { + body?: DataItemCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type DataCreateItemResponse = WrapResult; + +export type DataCreateItemError = WrapResult; + +export type DataDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type DataDeleteResponse = WrapResult; + +export type DataDeleteError = WrapResult; + +export type DataGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type DataGetResponse = WrapResultOfDataDto; + +export type DataGetError = WrapResult; + +export type DataUpdateData = { + body?: DataUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type DataUpdateResponse = WrapResultOfDataDto; + +export type DataUpdateError = WrapResult; + +export type DataDeleteItemData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + name: string; + }; +}; + +export type DataDeleteItemResponse = WrapResult; + +export type DataDeleteItemError = WrapResult; + +export type DataUpdateItemData = { + body?: DataItemUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + name: string; + }; +}; + +export type DataUpdateItemResponse = WrapResult; + +export type DataUpdateItemError = WrapResult; + +export type DataGet1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type DataGet1Response = WrapResultOfDataDto; + +export type DataGet1Error = WrapResult; + +export type DataGetAllData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type DataGetAllResponse = WrapResultOfListResultDtoOfDataDto; + +export type DataGetAllError = WrapResult; + +export type DataMoveData = { + body?: DataMoveDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type DataMoveResponse = WrapResultOfDataDto; + +export type DataMoveError = WrapResult; + +export type DeleteHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; +}; + +export type DeleteHandleResponse = void; + +export type DeleteHandleError = ProblemDetails; + +export type GetHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; +}; + +export type GetHandleResponse = WorkflowInstance; + +export type GetHandleError = unknown; + +export type DeleteHandle1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; +}; + +export type DeleteHandle1Response = unknown; + +export type DeleteHandle1Error = ProblemDetails; + +export type GetHandle1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; +}; + +export type GetHandle1Response = WebhookDefinition; + +export type GetHandle1Error = ProblemDetails; + +export type DeleteByDefinitionHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + definitionId: string; + }; +}; + +export type DeleteByDefinitionHandleResponse = unknown; + +export type DeleteByDefinitionHandleError = unknown; + +export type DeleteByDefinitionAndVersionHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + definitionId: string; + versionOptions: VersionOptions; + }; +}; + +export type DeleteByDefinitionAndVersionHandleResponse = unknown; + +export type DeleteByDefinitionAndVersionHandleError = unknown; + +export type DispatchHandleData = { + body?: DispatchWorkflowDefinitionRequestModel; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + workflowDefinitionId: string; + }; +}; + +export type DispatchHandleResponse = DispatchWorkflowDefinitionResponseModel; + +export type DispatchHandleError = ProblemDetails; + +export type DispatchHandle1Data = { + body?: DispatchWorkflowInstanceRequestModel; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + workflowInstanceId: string; + }; +}; + +export type DispatchHandle1Response = DispatchWorkflowInstanceResponseModel; + +export type DispatchHandle1Error = ProblemDetails; + +export type DispatchHandle2Data = { + body?: DispatchSignalRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + signalName: string; + }; +}; + +export type DispatchHandle2Response = DispatchSignalResponse; + +export type DispatchHandle2Error = unknown; + +export type DispatchEndpointHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + token: string; + }; +}; + +export type DispatchEndpointHandleResponse = unknown; + +export type DispatchEndpointHandleError = unknown; + +export type DispatchEndpointHandle1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + token: string; + }; +}; + +export type DispatchEndpointHandle1Response = unknown; + +export type DispatchEndpointHandle1Error = unknown; + +export type DynamicClaimsRefreshData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type DynamicClaimsRefreshResponse = WrapResult; + +export type DynamicClaimsRefreshError = WrapResult; + +export type EditionCreateData = { + body?: EditionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type EditionCreateResponse = WrapResultOfEditionDto; + +export type EditionCreateError = WrapResult; + +export type EditionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type EditionGetListResponse = WrapResultOfPagedResultDtoOfEditionDto; + +export type EditionGetListError = WrapResult; + +export type EditionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type EditionDeleteResponse = WrapResult; + +export type EditionDeleteError = WrapResult; + +export type EditionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type EditionGetResponse = WrapResultOfEditionDto; + +export type EditionGetError = WrapResult; + +export type EditionUpdateData = { + body?: EditionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type EditionUpdateResponse = WrapResultOfEditionDto; + +export type EditionUpdateError = WrapResult; + +export type EntityChangesGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type EntityChangesGetResponse = WrapResultOfEntityChangeDto; + +export type EntityChangesGetError = WrapResult; + +export type EntityChangesGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + AuditLogId?: string; + ChangeType?: EntityChangeType; + EndTime?: string; + EntityId?: string; + EntityTypeFullName?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + StartTime?: string; + }; +}; + +export type EntityChangesGetListResponse = WrapResultOfPagedResultDtoOfEntityChangeDto; + +export type EntityChangesGetListError = WrapResult; + +export type EntityChangesGetWithUsernameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type EntityChangesGetWithUsernameResponse = WrapResultOfEntityChangeWithUsernameDto; + +export type EntityChangesGetWithUsernameError = WrapResult; + +export type EntityChangesGetWithUsername1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + EntityId?: string; + EntityTypeFullName?: string; + }; +}; + +export type EntityChangesGetWithUsername1Response = WrapResultOfListResultDtoOfEntityChangeWithUsernameDto; + +export type EntityChangesGetWithUsername1Error = WrapResult; + +export type EntityTypeInfoGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type EntityTypeInfoGetResponse = WrapResultOfEntityTypeInfoDto; + +export type EntityTypeInfoGetError = WrapResult; + +export type EntityTypeInfoGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + IsAuditEnabled?: boolean; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type EntityTypeInfoGetListResponse = WrapResultOfPagedResultDtoOfEntityTypeInfoDto; + +export type EntityTypeInfoGetListError = WrapResult; + +export type ExecuteHandleData = { + body?: ExecuteWorkflowDefinitionRequestModel; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + workflowDefinitionId: string; + }; +}; + +export type ExecuteHandleResponse = ExecuteWorkflowDefinitionResponseModel; + +export type ExecuteHandleError = ProblemDetails; + +export type ExecuteHandle1Data = { + body?: ExecuteWorkflowInstanceRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + workflowInstanceId: string; + }; +}; + +export type ExecuteHandle1Response = ExecuteWorkflowInstanceResponseModel; + +export type ExecuteHandle1Error = ProblemDetails; + +export type ExecuteHandle2Data = { + body?: ExecuteSignalRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + signalName: string; + }; +}; + +export type ExecuteHandle2Response = ExecuteSignalResponse; + +export type ExecuteHandle2Error = unknown; + +export type ExportHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + versionOptions: VersionOptions; + workflowDefinitionId: string; + }; +}; + +export type ExportHandleResponse = unknown; + +export type ExportHandleError = ProblemDetails; + +export type FeatureDefinitionCreateData = { + body?: FeatureDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type FeatureDefinitionCreateResponse = WrapResultOfFeatureDefinitionDto; + +export type FeatureDefinitionCreateError = WrapResult; + +export type FeatureDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + GroupName?: string; + }; +}; + +export type FeatureDefinitionGetListResponse = WrapResultOfListResultDtoOfFeatureDefinitionDto; + +export type FeatureDefinitionGetListError = WrapResult; + +export type FeatureDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type FeatureDefinitionDeleteResponse = WrapResult; + +export type FeatureDefinitionDeleteError = WrapResult; + +export type FeatureDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type FeatureDefinitionGetResponse = WrapResultOfFeatureDefinitionDto; + +export type FeatureDefinitionGetError = WrapResult; + +export type FeatureDefinitionUpdateData = { + body?: FeatureDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type FeatureDefinitionUpdateResponse = WrapResultOfFeatureDefinitionDto; + +export type FeatureDefinitionUpdateError = WrapResult; + +export type FeatureGroupDefinitionCreateData = { + body?: FeatureGroupDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type FeatureGroupDefinitionCreateResponse = WrapResultOfFeatureGroupDefinitionDto; + +export type FeatureGroupDefinitionCreateError = WrapResult; + +export type FeatureGroupDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type FeatureGroupDefinitionGetListResponse = WrapResultOfListResultDtoOfFeatureGroupDefinitionDto; + +export type FeatureGroupDefinitionGetListError = WrapResult; + +export type FeatureGroupDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type FeatureGroupDefinitionDeleteResponse = WrapResult; + +export type FeatureGroupDefinitionDeleteError = WrapResult; + +export type FeatureGroupDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type FeatureGroupDefinitionGetResponse = WrapResultOfFeatureGroupDefinitionDto; + +export type FeatureGroupDefinitionGetError = WrapResult; + +export type FeatureGroupDefinitionUpdateData = { + body?: FeatureGroupDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type FeatureGroupDefinitionUpdateResponse = WrapResultOfFeatureGroupDefinitionDto; + +export type FeatureGroupDefinitionUpdateError = WrapResult; + +export type FeaturesGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + providerKey?: string; + providerName?: string; + }; +}; + +export type FeaturesGetResponse = WrapResultOfGetFeatureListResultDto; + +export type FeaturesGetError = WrapResult; + +export type FeaturesUpdateData = { + body?: UpdateFeaturesDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + providerKey?: string; + providerName?: string; + }; +}; + +export type FeaturesUpdateResponse = WrapResult; + +export type FeaturesUpdateError = WrapResult; + +export type FeaturesDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + providerKey?: string; + providerName?: string; + }; +}; + +export type FeaturesDeleteResponse = WrapResult; + +export type FeaturesDeleteError = WrapResult; + +export type FeedbackCreateData = { + body?: FeedbackCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type FeedbackCreateResponse = WrapResultOfFeedbackDto; + +export type FeedbackCreateError = WrapResult; + +export type FeedbackGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Category?: string; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + Status?: FeedbackStatus; + }; +}; + +export type FeedbackGetListResponse = WrapResultOfPagedResultDtoOfFeedbackDto; + +export type FeedbackGetListError = WrapResult; + +export type FeedbackDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type FeedbackDeleteResponse = WrapResult; + +export type FeedbackDeleteError = WrapResult; + +export type FeedbackGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type FeedbackGetResponse = WrapResultOfFeedbackDto; + +export type FeedbackGetError = WrapResult; + +export type FeedbackAttachmentGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + FeedbackId: string; + Name: string; + }; +}; + +export type FeedbackAttachmentGetResponse = IRemoteStreamContent; + +export type FeedbackAttachmentGetError = RemoteServiceErrorResponse; + +export type FeedbackAttachmentDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + FeedbackId: string; + Name: string; + }; +}; + +export type FeedbackAttachmentDeleteResponse = WrapResult; + +export type FeedbackAttachmentDeleteError = WrapResult; + +export type FeedbackAttachmentUploadData = { + body?: { + File?: IRemoteStreamContent; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type FeedbackAttachmentUploadResponse = WrapResultOfFeedbackAttachmentTempFileDto; + +export type FeedbackAttachmentUploadError = WrapResult; + +export type GetHandle2Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + versionOptions: VersionOptions; + }; +}; + +export type GetHandle2Response = PagedListOfWorkflowBlueprintModel; + +export type GetHandle2Error = unknown; + +export type GetHandle3Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; + query?: { + page?: number; + pageSize?: number; + }; +}; + +export type GetHandle3Response = PagedListOfWorkflowExecutionLogRecord; + +export type GetHandle3Error = unknown; + +export type GetHandle4Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type GetHandle4Response = unknown; + +export type GetHandle4Error = unknown; + +export type GetHandle5Data = { + body?: IntellisenseContext; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + workflowDefinitionId: string; + }; + query?: { + version?: VersionOptions; + }; +}; + +export type GetHandle5Response = Blob | File; + +export type GetHandle5Error = unknown; + +export type GetHandle6Data = { + body?: RuntimeSelectListContextHolder; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type GetHandle6Response = OkObjectResult; + +export type GetHandle6Error = unknown; + +export type GetHandle7Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + activityId: string; + apiVersion: string; + workflowInstanceId: string; + }; +}; + +export type GetHandle7Response = ActivityStats; + +export type GetHandle7Error = unknown; + +export type GetByDefinitionAndVersionHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + versionOptions: VersionOptions; + workflowDefinitionId: string; + }; +}; + +export type GetByDefinitionAndVersionHandleResponse = WorkflowDefinition; + +export type GetByDefinitionAndVersionHandleError = ProblemDetails; + +export type GetByVersionIdHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + versionId: string; + }; +}; + +export type GetByVersionIdHandleResponse = WorkflowDefinition; + +export type GetByVersionIdHandleError = ProblemDetails; + +export type GroupGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + groupId: string; + }; +}; + +export type GroupGetResponse = WrapResultOfGroup; + +export type GroupGetError = WrapResult; + +export type GroupSearchData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type GroupSearchResponse = WrapResultOfPagedResultDtoOfGroup; + +export type GroupSearchError = WrapResult; + +export type HistoryHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + definitionId: string; + }; +}; + +export type HistoryHandleResponse = Array; + +export type HistoryHandleError = unknown; + +export type IdentitySessionsGetSessionsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ClientId?: string; + Device?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + UserId?: string; + }; +}; + +export type IdentitySessionsGetSessionsResponse = WrapResultOfPagedResultDtoOfIdentitySessionDto; + +export type IdentitySessionsGetSessionsError = WrapResult; + +export type IdentitySessionsRevokeSessionData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + sessionId: string; + }; +}; + +export type IdentitySessionsRevokeSessionResponse = WrapResult; + +export type IdentitySessionsRevokeSessionError = WrapResult; + +export type ImportHandleData = { + body?: { + ContentType?: string; + ContentDisposition?: string; + Headers?: { + [key: string]: Array; + }; + Length?: number; + Name?: string; + FileName?: string; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + workflowDefinitionId: string; + }; +}; + +export type ImportHandleResponse = unknown; + +export type ImportHandleError = unknown; + +export type LanguageGetByNameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type LanguageGetByNameResponse = WrapResultOfLanguageDto; + +export type LanguageGetByNameError = WrapResult; + +export type LanguageDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type LanguageDeleteResponse = WrapResult; + +export type LanguageDeleteError = WrapResult; + +export type LanguageUpdateData = { + body?: LanguageUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type LanguageUpdateResponse = WrapResultOfLanguageDto; + +export type LanguageUpdateError = WrapResult; + +export type LanguageCreateData = { + body?: LanguageCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type LanguageCreateResponse = WrapResultOfLanguageDto; + +export type LanguageCreateError = WrapResult; + +export type LanguageGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type LanguageGetListResponse = WrapResultOfListResultDtoOfLanguageDto; + +export type LanguageGetListError = WrapResult; + +export type LayoutCreateData = { + body?: LayoutCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type LayoutCreateResponse = WrapResultOfLayoutDto; + +export type LayoutCreateError = WrapResult; + +export type LayoutGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + Framework?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type LayoutGetListResponse = WrapResultOfPagedResultDtoOfLayoutDto; + +export type LayoutGetListError = WrapResult; + +export type LayoutDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type LayoutDeleteResponse = WrapResult; + +export type LayoutDeleteError = WrapResult; + +export type LayoutGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type LayoutGetResponse = WrapResultOfLayoutDto; + +export type LayoutGetError = WrapResult; + +export type LayoutUpdateData = { + body?: LayoutUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type LayoutUpdateResponse = WrapResultOfLayoutDto; + +export type LayoutUpdateError = WrapResult; + +export type LayoutGetAllListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type LayoutGetAllListResponse = WrapResultOfListResultDtoOfLayoutDto; + +export type LayoutGetAllListError = WrapResult; + +export type ListHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + version: string; + }; +}; + +export type ListHandleResponse = Array; + +export type ListHandleError = unknown; + +export type ListHandle1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + version: string; + }; +}; + +export type ListHandle1Response = Array; + +export type ListHandle1Error = unknown; + +export type ListHandle2Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; + query?: { + correlationId?: string; + orderBy?: WorkflowInstanceOrderBy; + page?: number; + pageSize?: number; + searchTerm?: string; + status?: WorkflowStatus; + workflow?: string; + }; +}; + +export type ListHandle2Response = PagedListOfWorkflowInstanceSummaryModel; + +export type ListHandle2Error = unknown; + +export type ListHandle3Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; + query?: { + ids?: string; + orderBy?: WorkflowDefinitionOrderBy; + page?: number; + pageSize?: number; + searchTerm?: string; + sortBy?: SortBy; + version?: VersionOptions; + }; +}; + +export type ListHandle3Response = PagedListOfWorkflowDefinitionSummaryModel; + +export type ListHandle3Error = unknown; + +export type SaveHandleData = { + body?: SaveWorkflowDefinitionRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: ApiVersion; + }; +}; + +export type SaveHandleResponse = WorkflowDefinition; + +export type SaveHandleError = unknown; + +export type ListHandle4Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type ListHandle4Response = unknown; + +export type ListHandle4Error = unknown; + +export type ListHandle5Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type ListHandle5Response = unknown; + +export type ListHandle5Error = unknown; + +export type ListHandle6Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + version: string; + }; +}; + +export type ListHandle6Response = Array; + +export type ListHandle6Error = unknown; + +export type ListHandle7Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type ListHandle7Response = Array; + +export type ListHandle7Error = unknown; + +export type PostHandleData = { + body?: SaveWebhookDefinitionRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: ApiVersion; + }; +}; + +export type PostHandleResponse = WebhookDefinition; + +export type PostHandleError = unknown; + +export type UpdateHandleData = { + body?: SaveWebhookDefinitionRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: ApiVersion; + }; +}; + +export type UpdateHandleResponse = WebhookDefinition; + +export type UpdateHandleError = ProblemDetails; + +export type ListAllHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; + query?: { + version?: VersionOptions; + }; +}; + +export type ListAllHandleResponse = Array; + +export type ListAllHandleError = unknown; + +export type ListByDefinitionVersionIdsHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; + query?: { + ids?: string; + }; +}; + +export type ListByDefinitionVersionIdsHandleResponse = PagedListOfWorkflowBlueprintSummaryModel; + +export type ListByDefinitionVersionIdsHandleError = unknown; + +export type ListByProviderHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + providerName: string; + }; + query?: { + page?: number; + pageSize?: number; + version?: VersionOptions; + }; +}; + +export type ListByProviderHandleResponse = PagedListOfWorkflowBlueprintSummaryModel; + +export type ListByProviderHandleError = unknown; + +export type LoggingGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type LoggingGetResponse = WrapResultOfLogDto; + +export type LoggingGetError = WrapResult; + +export type LoggingGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Application?: string; + Context?: string; + CorrelationId?: string; + EndTime?: string; + Environment?: string; + HasException?: boolean; + Level?: LogLevel; + MachineName?: string; + MaxResultCount?: number; + ProcessId?: number; + RequestId?: string; + RequestPath?: string; + SkipCount?: number; + Sorting?: string; + StartTime?: string; + ThreadId?: number; + }; +}; + +export type LoggingGetListResponse = WrapResultOfPagedResultDtoOfLogDto; + +export type LoggingGetListError = WrapResult; + +export type LoginLoginData = { + body?: UserLoginInfo; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type LoginLoginResponse = WrapResultOfAbpLoginResult; + +export type LoginLoginError = WrapResult; + +export type LoginLogoutData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type LoginLogoutResponse = WrapResult; + +export type LoginLogoutError = WrapResult; + +export type LoginCheckPasswordData = { + body?: UserLoginInfo; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type LoginCheckPasswordResponse = WrapResultOfAbpLoginResult; + +export type LoginCheckPasswordError = WrapResult; + +export type MenuGetCurrentUserMenuListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Framework?: string; + }; +}; + +export type MenuGetCurrentUserMenuListResponse = WrapResultOfListResultDtoOfMenuDto; + +export type MenuGetCurrentUserMenuListError = WrapResult; + +export type MenuGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type MenuGetResponse = WrapResultOfMenuDto; + +export type MenuGetError = WrapResult; + +export type MenuUpdateData = { + body?: MenuUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type MenuUpdateResponse = WrapResultOfMenuDto; + +export type MenuUpdateError = WrapResult; + +export type MenuDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type MenuDeleteResponse = WrapResult; + +export type MenuDeleteError = WrapResult; + +export type MenuGetAllData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + Framework?: string; + LayoutId?: string; + ParentId?: string; + Reverse?: boolean; + Sorting?: string; + }; +}; + +export type MenuGetAllResponse = WrapResultOfListResultDtoOfMenuDto; + +export type MenuGetAllError = WrapResult; + +export type MenuGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + Framework?: string; + LayoutId?: string; + MaxResultCount?: number; + ParentId?: string; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type MenuGetListResponse = WrapResultOfPagedResultDtoOfMenuDto; + +export type MenuGetListError = WrapResult; + +export type MenuCreateData = { + body?: MenuCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MenuCreateResponse = WrapResultOfMenuDto; + +export type MenuCreateError = WrapResult; + +export type MenuSetUserMenusData = { + body?: UserMenuInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MenuSetUserMenusResponse = WrapResult; + +export type MenuSetUserMenusError = WrapResult; + +export type MenuGetUserMenuListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Framework?: string; + Roles?: Array; + UserId: string; + }; +}; + +export type MenuGetUserMenuListResponse = WrapResultOfListResultDtoOfMenuDto; + +export type MenuGetUserMenuListError = WrapResult; + +export type MenuSetUserStartupData = { + body?: UserMenuStartupInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type MenuSetUserStartupResponse = WrapResult; + +export type MenuSetUserStartupError = WrapResult; + +export type MenuGetUserMenuList1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + framework: string; + userId: string; + }; +}; + +export type MenuGetUserMenuList1Response = WrapResultOfListResultDtoOfMenuDto; + +export type MenuGetUserMenuList1Error = WrapResult; + +export type MenuSetRoleMenusData = { + body?: RoleMenuInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MenuSetRoleMenusResponse = WrapResult; + +export type MenuSetRoleMenusError = WrapResult; + +export type MenuGetRoleMenuListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Framework?: string; + Role: string; + }; +}; + +export type MenuGetRoleMenuListResponse = WrapResultOfListResultDtoOfMenuDto; + +export type MenuGetRoleMenuListError = WrapResult; + +export type MenuSetRoleStartupData = { + body?: RoleMenuStartupInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type MenuSetRoleStartupResponse = WrapResult; + +export type MenuSetRoleStartupError = WrapResult; + +export type MenuGetRoleMenuList1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + framework: string; + role: string; + }; +}; + +export type MenuGetRoleMenuList1Response = WrapResultOfListResultDtoOfMenuDto; + +export type MenuGetRoleMenuList1Error = WrapResult; + +export type MyFeedbackGetMyFeedbacksData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Category?: string; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + Status?: FeedbackStatus; + }; +}; + +export type MyFeedbackGetMyFeedbacksResponse = WrapResultOfPagedResultDtoOfFeedbackDto; + +export type MyFeedbackGetMyFeedbacksError = WrapResult; + +export type MyFriendCreateData = { + body?: MyFriendCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MyFriendCreateResponse = WrapResult; + +export type MyFriendCreateError = WrapResult; + +export type MyFriendDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + FriendId: string; + }; +}; + +export type MyFriendDeleteResponse = WrapResult; + +export type MyFriendDeleteError = WrapResult; + +export type MyFriendGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type MyFriendGetListResponse = WrapResultOfPagedResultDtoOfUserFriend; + +export type MyFriendGetListError = WrapResult; + +export type MyFriendAddRequestData = { + body?: MyFriendAddRequestDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MyFriendAddRequestResponse = WrapResult; + +export type MyFriendAddRequestError = WrapResult; + +export type MyFriendGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + friendId: string; + }; +}; + +export type MyFriendGetResponse = WrapResultOfUserFriend; + +export type MyFriendGetError = WrapResult; + +export type MyFriendGetAllListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Sorting?: string; + }; +}; + +export type MyFriendGetAllListResponse = WrapResultOfListResultDtoOfUserFriend; + +export type MyFriendGetAllListError = WrapResult; + +export type MyNotificationMarkReadStateData = { + body?: NotificationMarkReadStateInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MyNotificationMarkReadStateResponse = WrapResult; + +export type MyNotificationMarkReadStateError = WrapResult; + +export type MyNotificationDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: number; + }; +}; + +export type MyNotificationDeleteResponse = WrapResult; + +export type MyNotificationDeleteError = WrapResult; + +export type MyNotificationGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: number; + }; +}; + +export type MyNotificationGetResponse = WrapResultOfUserNotificationDto; + +export type MyNotificationGetError = WrapResult; + +export type MyNotificationGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + ReadState?: NotificationReadState; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type MyNotificationGetListResponse = WrapResultOfPagedResultDtoOfUserNotificationDto; + +export type MyNotificationGetListError = WrapResult; + +export type MySubscriptionGetAllListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MySubscriptionGetAllListResponse = WrapResultOfListResultDtoOfUserSubscreNotificationDto; + +export type MySubscriptionGetAllListError = WrapResult; + +export type MySubscriptionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type MySubscriptionGetListResponse = WrapResultOfPagedResultDtoOfUserSubscreNotificationDto; + +export type MySubscriptionGetListError = WrapResult; + +export type MySubscriptionSubscribeData = { + body?: SubscriptionsGetByNameDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type MySubscriptionSubscribeResponse = WrapResult; + +export type MySubscriptionSubscribeError = WrapResult; + +export type MySubscriptionUnSubscribeData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Name: string; + }; +}; + +export type MySubscriptionUnSubscribeResponse = WrapResult; + +export type MySubscriptionUnSubscribeError = WrapResult; + +export type MySubscriptionIsSubscribedData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + }; +}; + +export type MySubscriptionIsSubscribedResponse = WrapResultOfUserSubscriptionsResult; + +export type MySubscriptionIsSubscribedError = WrapResult; + +export type NotificationSendData = { + body?: NotificationSendDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type NotificationSendResponse = WrapResult; + +export type NotificationSendError = WrapResult; + +export type NotificationSend1Data = { + body?: NotificationTemplateSendDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type NotificationSend1Response = WrapResult; + +export type NotificationSend1Error = WrapResult; + +export type NotificationGetAssignableNotifiersData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type NotificationGetAssignableNotifiersResponse = WrapResultOfListResultDtoOfNotificationGroupDto; + +export type NotificationGetAssignableNotifiersError = WrapResult; + +export type NotificationGetAssignableTemplatesData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type NotificationGetAssignableTemplatesResponse = WrapResultOfListResultDtoOfNotificationTemplateDto; + +export type NotificationGetAssignableTemplatesError = WrapResult; + +export type NotificationDefinitionCreateData = { + body?: NotificationDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type NotificationDefinitionCreateResponse = WrapResultOfNotificationDefinitionDto; + +export type NotificationDefinitionCreateError = WrapResult; + +export type NotificationDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + AllowSubscriptionToClients?: boolean; + ContentType?: NotificationContentType; + Filter?: string; + GroupName?: string; + NotificationLifetime?: NotificationLifetime; + NotificationType?: NotificationType; + Template?: string; + }; +}; + +export type NotificationDefinitionGetListResponse = WrapResultOfListResultDtoOfNotificationDefinitionDto; + +export type NotificationDefinitionGetListError = WrapResult; + +export type NotificationDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type NotificationDefinitionDeleteResponse = WrapResult; + +export type NotificationDefinitionDeleteError = WrapResult; + +export type NotificationDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type NotificationDefinitionGetResponse = WrapResultOfNotificationDefinitionDto; + +export type NotificationDefinitionGetError = WrapResult; + +export type NotificationDefinitionUpdateData = { + body?: NotificationDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type NotificationDefinitionUpdateResponse = WrapResultOfNotificationDefinitionDto; + +export type NotificationDefinitionUpdateError = WrapResult; + +export type NotificationGroupDefinitionCreateData = { + body?: NotificationGroupDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type NotificationGroupDefinitionCreateResponse = WrapResultOfNotificationGroupDefinitionDto; + +export type NotificationGroupDefinitionCreateError = WrapResult; + +export type NotificationGroupDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type NotificationGroupDefinitionGetListResponse = WrapResultOfListResultDtoOfNotificationGroupDefinitionDto; + +export type NotificationGroupDefinitionGetListError = WrapResult; + +export type NotificationGroupDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type NotificationGroupDefinitionDeleteResponse = WrapResult; + +export type NotificationGroupDefinitionDeleteError = WrapResult; + +export type NotificationGroupDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type NotificationGroupDefinitionGetResponse = WrapResultOfNotificationGroupDefinitionDto; + +export type NotificationGroupDefinitionGetError = WrapResult; + +export type NotificationGroupDefinitionUpdateData = { + body?: NotificationGroupDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type NotificationGroupDefinitionUpdateResponse = WrapResultOfNotificationGroupDefinitionDto; + +export type NotificationGroupDefinitionUpdateError = WrapResult; + +export type OpenIddictApplicationGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictApplicationGetResponse = WrapResultOfOpenIddictApplicationDto; + +export type OpenIddictApplicationGetError = WrapResult; + +export type OpenIddictApplicationUpdateData = { + body?: OpenIddictApplicationUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictApplicationUpdateResponse = WrapResultOfOpenIddictApplicationDto; + +export type OpenIddictApplicationUpdateError = WrapResult; + +export type OpenIddictApplicationDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictApplicationDeleteResponse = WrapResult; + +export type OpenIddictApplicationDeleteError = WrapResult; + +export type OpenIddictApplicationGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OpenIddictApplicationGetListResponse = WrapResultOfPagedResultDtoOfOpenIddictApplicationDto; + +export type OpenIddictApplicationGetListError = WrapResult; + +export type OpenIddictApplicationCreateData = { + body?: OpenIddictApplicationCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OpenIddictApplicationCreateResponse = WrapResultOfOpenIddictApplicationDto; + +export type OpenIddictApplicationCreateError = WrapResult; + +export type OpenIddictAuthorizationDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictAuthorizationDeleteResponse = WrapResult; + +export type OpenIddictAuthorizationDeleteError = WrapResult; + +export type OpenIddictAuthorizationGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictAuthorizationGetResponse = WrapResultOfOpenIddictAuthorizationDto; + +export type OpenIddictAuthorizationGetError = WrapResult; + +export type OpenIddictAuthorizationGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + BeginCreationTime?: string; + ClientId?: string; + EndCreationTime?: string; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + Status?: string; + Subject?: string; + Type?: string; + }; +}; + +export type OpenIddictAuthorizationGetListResponse = WrapResultOfPagedResultDtoOfOpenIddictAuthorizationDto; + +export type OpenIddictAuthorizationGetListError = WrapResult; + +export type OpenIddictScopeCreateData = { + body?: OpenIddictScopeCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OpenIddictScopeCreateResponse = WrapResultOfOpenIddictScopeDto; + +export type OpenIddictScopeCreateError = WrapResult; + +export type OpenIddictScopeGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OpenIddictScopeGetListResponse = WrapResultOfPagedResultDtoOfOpenIddictScopeDto; + +export type OpenIddictScopeGetListError = WrapResult; + +export type OpenIddictScopeDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictScopeDeleteResponse = WrapResult; + +export type OpenIddictScopeDeleteError = WrapResult; + +export type OpenIddictScopeGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictScopeGetResponse = WrapResultOfOpenIddictScopeDto; + +export type OpenIddictScopeGetError = WrapResult; + +export type OpenIddictScopeUpdateData = { + body?: OpenIddictScopeUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictScopeUpdateResponse = WrapResultOfOpenIddictScopeDto; + +export type OpenIddictScopeUpdateError = WrapResult; + +export type OpenIddictTokenDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictTokenDeleteResponse = WrapResult; + +export type OpenIddictTokenDeleteError = WrapResult; + +export type OpenIddictTokenGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OpenIddictTokenGetResponse = WrapResultOfOpenIddictTokenDto; + +export type OpenIddictTokenGetError = WrapResult; + +export type OpenIddictTokenGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + AuthorizationId?: string; + BeginCreationTime?: string; + BeginExpirationDate?: string; + ClientId?: string; + EndCreationTime?: string; + EndExpirationDate?: string; + Filter?: string; + MaxResultCount?: number; + ReferenceId?: string; + SkipCount?: number; + Sorting?: string; + Status?: string; + Subject?: string; + Type?: string; + }; +}; + +export type OpenIddictTokenGetListResponse = WrapResultOfPagedResultDtoOfOpenIddictTokenDto; + +export type OpenIddictTokenGetListError = WrapResult; + +export type OrganizationUnitsCreateData = { + body?: OrganizationUnitCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OrganizationUnitsCreateResponse = WrapResultOfOrganizationUnitDto; + +export type OrganizationUnitsCreateError = WrapResult; + +export type OrganizationUnitsGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OrganizationUnitsGetListResponse = WrapResultOfPagedResultDtoOfOrganizationUnitDto; + +export type OrganizationUnitsGetListError = WrapResult; + +export type OrganizationUnitsDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsDeleteResponse = WrapResult; + +export type OrganizationUnitsDeleteError = WrapResult; + +export type OrganizationUnitsGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsGetResponse = WrapResultOfOrganizationUnitDto; + +export type OrganizationUnitsGetError = WrapResult; + +export type OrganizationUnitsUpdateData = { + body?: OrganizationUnitUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsUpdateResponse = WrapResultOfOrganizationUnitDto; + +export type OrganizationUnitsUpdateError = WrapResult; + +export type OrganizationUnitsFindChildrenData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Id: string; + Recursive?: boolean; + }; +}; + +export type OrganizationUnitsFindChildrenResponse = WrapResultOfListResultDtoOfOrganizationUnitDto; + +export type OrganizationUnitsFindChildrenError = WrapResult; + +export type OrganizationUnitsGetRootData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OrganizationUnitsGetRootResponse = WrapResultOfListResultDtoOfOrganizationUnitDto; + +export type OrganizationUnitsGetRootError = WrapResult; + +export type OrganizationUnitsGetLastChildOrNullData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + parentId?: string; + }; +}; + +export type OrganizationUnitsGetLastChildOrNullResponse = WrapResultOfOrganizationUnitDto; + +export type OrganizationUnitsGetLastChildOrNullError = WrapResult; + +export type OrganizationUnitsGetAllListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OrganizationUnitsGetAllListResponse = WrapResultOfListResultDtoOfOrganizationUnitDto; + +export type OrganizationUnitsGetAllListError = WrapResult; + +export type OrganizationUnitsGetRoleNamesData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsGetRoleNamesResponse = WrapResultOfListResultDtoOfString; + +export type OrganizationUnitsGetRoleNamesError = WrapResult; + +export type OrganizationUnitsGetUnaddedRolesData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OrganizationUnitsGetUnaddedRolesResponse = WrapResultOfPagedResultDtoOfIdentityRoleDto; + +export type OrganizationUnitsGetUnaddedRolesError = WrapResult; + +export type OrganizationUnitsGetRolesData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; + query?: { + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OrganizationUnitsGetRolesResponse = WrapResultOfPagedResultDtoOfIdentityRoleDto; + +export type OrganizationUnitsGetRolesError = WrapResult; + +export type OrganizationUnitsAddRolesData = { + body?: OrganizationUnitAddRoleDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsAddRolesResponse = WrapResult; + +export type OrganizationUnitsAddRolesError = WrapResult; + +export type OrganizationUnitsGetUnaddedUsersData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OrganizationUnitsGetUnaddedUsersResponse = WrapResultOfPagedResultDtoOfIdentityUserDto; + +export type OrganizationUnitsGetUnaddedUsersError = WrapResult; + +export type OrganizationUnitsGetUsersData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; + query?: { + ExtraProperties?: { + [key: string]: unknown; + }; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OrganizationUnitsGetUsersResponse = WrapResultOfPagedResultDtoOfIdentityUserDto; + +export type OrganizationUnitsGetUsersError = WrapResult; + +export type OrganizationUnitsAddUsersData = { + body?: OrganizationUnitAddUserDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsAddUsersResponse = WrapResult; + +export type OrganizationUnitsAddUsersError = WrapResult; + +export type OrganizationUnitsMoveData = { + body?: OrganizationUnitMoveDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitsMoveResponse = WrapResult; + +export type OrganizationUnitsMoveError = WrapResult; + +export type OrganizationUnitEntityRuleGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + EntityTypeId: string; + Operation: DataAccessOperation; + OrgCode: string; + }; +}; + +export type OrganizationUnitEntityRuleGetResponse = WrapResultOfOrganizationUnitEntityRuleDto; + +export type OrganizationUnitEntityRuleGetError = WrapResult; + +export type OrganizationUnitEntityRuleCreateData = { + body?: OrganizationUnitEntityRuleCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OrganizationUnitEntityRuleCreateResponse = WrapResultOfOrganizationUnitEntityRuleDto; + +export type OrganizationUnitEntityRuleCreateError = WrapResult; + +export type OrganizationUnitEntityRuleUpdateData = { + body?: OrganizationUnitEntityRuleUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type OrganizationUnitEntityRuleUpdateResponse = WrapResultOfOrganizationUnitEntityRuleDto; + +export type OrganizationUnitEntityRuleUpdateError = WrapResult; + +export type OssContainerCreateData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type OssContainerCreateResponse = WrapResultOfOssContainerDto; + +export type OssContainerCreateError = WrapResult; + +export type OssContainerDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type OssContainerDeleteResponse = WrapResult; + +export type OssContainerDeleteError = WrapResult; + +export type OssContainerGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type OssContainerGetResponse = WrapResultOfOssContainerDto; + +export type OssContainerGetError = WrapResult; + +export type OssContainerGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Marker?: string; + MaxResultCount?: number; + Prefix?: string; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OssContainerGetListResponse = WrapResultOfOssContainersResultDto; + +export type OssContainerGetListError = WrapResult; + +export type OssContainerGetObjectListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Bucket?: string; + Delimiter?: string; + EncodingType?: string; + Marker?: string; + MaxResultCount?: number; + MD5?: boolean; + Prefix?: string; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type OssContainerGetObjectListResponse = WrapResultOfOssObjectsResultDto; + +export type OssContainerGetObjectListError = WrapResult; + +export type OssManagementSettingGetAllForCurrentTenantData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OssManagementSettingGetAllForCurrentTenantResponse = WrapResultOfSettingGroupResult; + +export type OssManagementSettingGetAllForCurrentTenantError = WrapResult; + +export type OssManagementSettingGetAllForGlobalData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OssManagementSettingGetAllForGlobalResponse = WrapResultOfSettingGroupResult; + +export type OssManagementSettingGetAllForGlobalError = WrapResult; + +export type OssObjectCreateData = { + body?: { + Bucket?: string; + Path?: string; + FileName?: string; + Overwrite?: boolean; + File?: IRemoteStreamContent; + ExpirationTime?: TimeSpan; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OssObjectCreateResponse = WrapResultOfOssObjectDto; + +export type OssObjectCreateError = WrapResult; + +export type OssObjectDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Bucket: string; + MD5?: boolean; + Object: string; + Path?: string; + }; +}; + +export type OssObjectDeleteResponse = WrapResult; + +export type OssObjectDeleteError = WrapResult; + +export type OssObjectGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Bucket: string; + MD5?: boolean; + Object: string; + Path?: string; + }; +}; + +export type OssObjectGetResponse = WrapResultOfOssObjectDto; + +export type OssObjectGetError = WrapResult; + +export type OssObjectUploadData = { + body?: { + Bucket?: string; + Path?: string; + ChunkSize: number; + CurrentChunkSize: number; + ChunkNumber: number; + TotalChunks: number; + File?: IRemoteStreamContent; + TotalSize: number; + FileName: string; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OssObjectUploadResponse = WrapResult; + +export type OssObjectUploadError = WrapResult; + +export type OssObjectBulkDeleteData = { + body?: BulkDeleteOssObjectInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type OssObjectBulkDeleteResponse = WrapResult; + +export type OssObjectBulkDeleteError = WrapResult; + +export type OssObjectGetContentData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Bucket: string; + MD5?: boolean; + Object: string; + Path?: string; + }; +}; + +export type OssObjectGetContentResponse = IRemoteStreamContent; + +export type OssObjectGetContentError = RemoteServiceErrorResponse; + +export type PackageCreateData = { + body?: PackageCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PackageCreateResponse = WrapResultOfPackageDto; + +export type PackageCreateError = WrapResult; + +export type PackageGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Authors?: string; + Description?: string; + Filter?: string; + ForceUpdate?: boolean; + MaxResultCount?: number; + Name?: string; + Note?: string; + SkipCount?: number; + Sorting?: string; + Version?: string; + }; +}; + +export type PackageGetListResponse = WrapResultOfPagedResultDtoOfPackageDto; + +export type PackageGetListError = WrapResult; + +export type PackageDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type PackageDeleteResponse = WrapResult; + +export type PackageDeleteError = WrapResult; + +export type PackageGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type PackageGetResponse = WrapResultOfPackageDto; + +export type PackageGetError = WrapResult; + +export type PackageUpdateData = { + body?: PackageUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type PackageUpdateResponse = WrapResultOfPackageDto; + +export type PackageUpdateError = WrapResult; + +export type PackageUploadBlobData = { + body?: { + Name: string; + Size?: number; + Summary?: string; + ContentType?: string; + CreatedAt?: string; + UpdatedAt?: string; + License?: string; + Authors?: string; + File: IRemoteStreamContent; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type PackageUploadBlobResponse = WrapResultOfPackageBlobDto; + +export type PackageUploadBlobError = WrapResult; + +export type PackageRemoveBlobData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + Name: string; + }; +}; + +export type PackageRemoveBlobResponse = WrapResult; + +export type PackageRemoveBlobError = WrapResult; + +export type PackageDownloadBlobData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + Name: string; + }; +}; + +export type PackageDownloadBlobResponse = IRemoteStreamContent; + +export type PackageDownloadBlobError = RemoteServiceErrorResponse; + +export type PackageGetLatestData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + }; + query?: { + Version?: string; + }; +}; + +export type PackageGetLatestResponse = WrapResultOfPackageDto; + +export type PackageGetLatestError = WrapResult; + +export type PackageGetLatest1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Version: string; + }; +}; + +export type PackageGetLatest1Response = WrapResultOfPackageDto; + +export type PackageGetLatest1Error = WrapResult; + +export type PermissionDefinitionCreateData = { + body?: PermissionDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PermissionDefinitionCreateResponse = WrapResultOfPermissionDefinitionDto; + +export type PermissionDefinitionCreateError = WrapResult; + +export type PermissionDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + GroupName?: string; + }; +}; + +export type PermissionDefinitionGetListResponse = WrapResultOfListResultDtoOfPermissionDefinitionDto; + +export type PermissionDefinitionGetListError = WrapResult; + +export type PermissionDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type PermissionDefinitionDeleteResponse = WrapResult; + +export type PermissionDefinitionDeleteError = WrapResult; + +export type PermissionDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type PermissionDefinitionGetResponse = WrapResultOfPermissionDefinitionDto; + +export type PermissionDefinitionGetError = WrapResult; + +export type PermissionDefinitionUpdateData = { + body?: PermissionDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type PermissionDefinitionUpdateResponse = WrapResultOfPermissionDefinitionDto; + +export type PermissionDefinitionUpdateError = WrapResult; + +export type PermissionGroupDefinitionCreateData = { + body?: PermissionGroupDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PermissionGroupDefinitionCreateResponse = WrapResultOfPermissionGroupDefinitionDto; + +export type PermissionGroupDefinitionCreateError = WrapResult; + +export type PermissionGroupDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type PermissionGroupDefinitionGetListResponse = WrapResultOfListResultDtoOfPermissionGroupDefinitionDto; + +export type PermissionGroupDefinitionGetListError = WrapResult; + +export type PermissionGroupDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type PermissionGroupDefinitionDeleteResponse = WrapResult; + +export type PermissionGroupDefinitionDeleteError = WrapResult; + +export type PermissionGroupDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type PermissionGroupDefinitionGetResponse = WrapResultOfPermissionGroupDefinitionDto; + +export type PermissionGroupDefinitionGetError = WrapResult; + +export type PermissionGroupDefinitionUpdateData = { + body?: PermissionGroupDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type PermissionGroupDefinitionUpdateResponse = WrapResultOfPermissionGroupDefinitionDto; + +export type PermissionGroupDefinitionUpdateError = WrapResult; + +export type PermissionsGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + providerKey?: string; + providerName?: string; + }; +}; + +export type PermissionsGetResponse = WrapResultOfGetPermissionListResultDto; + +export type PermissionsGetError = WrapResult; + +export type PermissionsUpdateData = { + body?: UpdatePermissionsDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + providerKey?: string; + providerName?: string; + }; +}; + +export type PermissionsUpdateResponse = WrapResult; + +export type PermissionsUpdateError = WrapResult; + +export type PrivateFilesUploadData = { + body?: { + Path?: string; + Object?: string; + Overwrite?: boolean; + File: IRemoteStreamContent; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PrivateFilesUploadResponse = WrapResultOfOssObjectDto; + +export type PrivateFilesUploadError = WrapResult; + +export type PrivateFilesDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Name: string; + Path?: string; + Process?: string; + TenantId?: string; + }; +}; + +export type PrivateFilesDeleteResponse = WrapResult; + +export type PrivateFilesDeleteError = WrapResult; + +export type PrivateFilesUpload1Data = { + body?: { + Bucket?: string; + Path?: string; + ChunkSize: number; + CurrentChunkSize: number; + ChunkNumber: number; + TotalChunks: number; + File?: IRemoteStreamContent; + TotalSize: number; + FileName: string; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PrivateFilesUpload1Response = WrapResult; + +export type PrivateFilesUpload1Error = WrapResult; + +export type PrivateFilesGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + Path?: string; + }; +}; + +export type PrivateFilesGetListResponse = WrapResultOfListResultDtoOfOssObjectDto; + +export type PrivateFilesGetListError = WrapResult; + +export type PrivateFilesGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + }; +}; + +export type PrivateFilesGetResponse = IRemoteStreamContent; + +export type PrivateFilesGetError = RemoteServiceErrorResponse; + +export type PrivateFilesGet1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Process: string; + }; +}; + +export type PrivateFilesGet1Response = IRemoteStreamContent; + +export type PrivateFilesGet1Error = RemoteServiceErrorResponse; + +export type PrivateFilesGet2Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + }; +}; + +export type PrivateFilesGet2Response = IRemoteStreamContent; + +export type PrivateFilesGet2Error = RemoteServiceErrorResponse; + +export type PrivateFilesGet3Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + Process: string; + }; +}; + +export type PrivateFilesGet3Response = IRemoteStreamContent; + +export type PrivateFilesGet3Error = RemoteServiceErrorResponse; + +export type PrivateFilesGet4Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + TenantId: string; + }; +}; + +export type PrivateFilesGet4Response = IRemoteStreamContent; + +export type PrivateFilesGet4Error = RemoteServiceErrorResponse; + +export type PrivateFilesGet5Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Process: string; + TenantId: string; + }; +}; + +export type PrivateFilesGet5Response = IRemoteStreamContent; + +export type PrivateFilesGet5Error = RemoteServiceErrorResponse; + +export type PrivateFilesGet6Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + TenantId: string; + }; +}; + +export type PrivateFilesGet6Response = IRemoteStreamContent; + +export type PrivateFilesGet6Error = RemoteServiceErrorResponse; + +export type PrivateFilesGet7Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + Process: string; + TenantId: string; + }; +}; + +export type PrivateFilesGet7Response = IRemoteStreamContent; + +export type PrivateFilesGet7Error = RemoteServiceErrorResponse; + +export type PrivateFilesGetShareListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PrivateFilesGetShareListResponse = WrapResultOfListResultDtoOfMyFileShareDto; + +export type PrivateFilesGetShareListError = WrapResult; + +export type PrivateFilesShareData = { + body?: FileShareInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PrivateFilesShareResponse = WrapResultOfFileShareDto; + +export type PrivateFilesShareError = WrapResult; + +export type ProfileGetSessionsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ClientId?: string; + Device?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type ProfileGetSessionsResponse = WrapResultOfPagedResultDtoOfIdentitySessionDto_1; + +export type ProfileGetSessionsError = WrapResult; + +export type ProfileRevokeSessionData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + sessionId: string; + }; +}; + +export type ProfileRevokeSessionResponse = WrapResult; + +export type ProfileRevokeSessionError = WrapResult; + +export type ProfileGetTwoFactorEnabledData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileGetTwoFactorEnabledResponse = WrapResultOfTwoFactorEnabledDto; + +export type ProfileGetTwoFactorEnabledError = WrapResult; + +export type ProfileChangeTwoFactorEnabledData = { + body?: TwoFactorEnabledDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileChangeTwoFactorEnabledResponse = WrapResult; + +export type ProfileChangeTwoFactorEnabledError = WrapResult; + +export type ProfileSendChangePhoneNumberCodeData = { + body?: SendChangePhoneNumberCodeInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileSendChangePhoneNumberCodeResponse = WrapResult; + +export type ProfileSendChangePhoneNumberCodeError = WrapResult; + +export type ProfileChangePhoneNumberData = { + body?: ChangePhoneNumberInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileChangePhoneNumberResponse = WrapResult; + +export type ProfileChangePhoneNumberError = WrapResult; + +export type ProfileSendEmailConfirmLinkData = { + body?: SendEmailConfirmCodeDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileSendEmailConfirmLinkResponse = WrapResult; + +export type ProfileSendEmailConfirmLinkError = WrapResult; + +export type ProfileConfirmEmailData = { + body?: ConfirmEmailInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileConfirmEmailResponse = WrapResult; + +export type ProfileConfirmEmailError = WrapResult; + +export type ProfileGetAuthenticatorData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileGetAuthenticatorResponse = WrapResultOfAuthenticatorDto; + +export type ProfileGetAuthenticatorError = WrapResult; + +export type ProfileVerifyAuthenticatorCodeData = { + body?: VerifyAuthenticatorCodeInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileVerifyAuthenticatorCodeResponse = WrapResultOfAuthenticatorRecoveryCodeDto; + +export type ProfileVerifyAuthenticatorCodeError = WrapResult; + +export type ProfileResetAuthenticatorData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileResetAuthenticatorResponse = WrapResult; + +export type ProfileResetAuthenticatorError = WrapResult; + +export type ProfileGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileGetResponse = WrapResultOfProfileDto; + +export type ProfileGetError = WrapResult; + +export type ProfileUpdateData = { + body?: UpdateProfileDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileUpdateResponse = WrapResultOfProfileDto; + +export type ProfileUpdateError = WrapResult; + +export type ProfileChangePasswordData = { + body?: ChangePasswordInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ProfileChangePasswordResponse = WrapResult; + +export type ProfileChangePasswordError = WrapResult; + +export type PublicFilesUploadData = { + body?: { + Path?: string; + Object?: string; + Overwrite?: boolean; + File: IRemoteStreamContent; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PublicFilesUploadResponse = WrapResultOfOssObjectDto; + +export type PublicFilesUploadError = WrapResult; + +export type PublicFilesDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Name: string; + Path?: string; + Process?: string; + TenantId?: string; + }; +}; + +export type PublicFilesDeleteResponse = WrapResult; + +export type PublicFilesDeleteError = WrapResult; + +export type PublicFilesUpload1Data = { + body?: { + Bucket?: string; + Path?: string; + ChunkSize: number; + CurrentChunkSize: number; + ChunkNumber: number; + TotalChunks: number; + File?: IRemoteStreamContent; + TotalSize: number; + FileName: string; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type PublicFilesUpload1Response = WrapResult; + +export type PublicFilesUpload1Error = WrapResult; + +export type PublicFilesGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + Path?: string; + }; +}; + +export type PublicFilesGetListResponse = WrapResultOfListResultDtoOfOssObjectDto; + +export type PublicFilesGetListError = WrapResult; + +export type PublicFilesGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + }; +}; + +export type PublicFilesGetResponse = IRemoteStreamContent; + +export type PublicFilesGetError = RemoteServiceErrorResponse; + +export type PublicFilesGet1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Process: string; + }; +}; + +export type PublicFilesGet1Response = IRemoteStreamContent; + +export type PublicFilesGet1Error = RemoteServiceErrorResponse; + +export type PublicFilesGet2Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + }; +}; + +export type PublicFilesGet2Response = IRemoteStreamContent; + +export type PublicFilesGet2Error = RemoteServiceErrorResponse; + +export type PublicFilesGet3Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + Process: string; + }; +}; + +export type PublicFilesGet3Response = IRemoteStreamContent; + +export type PublicFilesGet3Error = RemoteServiceErrorResponse; + +export type PublicFilesGet4Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + TenantId: string; + }; +}; + +export type PublicFilesGet4Response = IRemoteStreamContent; + +export type PublicFilesGet4Error = RemoteServiceErrorResponse; + +export type PublicFilesGet5Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Process: string; + TenantId: string; + }; +}; + +export type PublicFilesGet5Response = IRemoteStreamContent; + +export type PublicFilesGet5Error = RemoteServiceErrorResponse; + +export type PublicFilesGet6Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + TenantId: string; + }; +}; + +export type PublicFilesGet6Response = IRemoteStreamContent; + +export type PublicFilesGet6Error = RemoteServiceErrorResponse; + +export type PublicFilesGet7Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + Path: string; + Process: string; + TenantId: string; + }; +}; + +export type PublicFilesGet7Response = IRemoteStreamContent; + +export type PublicFilesGet7Error = RemoteServiceErrorResponse; + +export type PublishHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: ApiVersion; + workflowDefinitionId: string; + }; +}; + +export type PublishHandleResponse = WorkflowDefinition; + +export type PublishHandleError = ProblemDetails; + +export type ResourceGetByNameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type ResourceGetByNameResponse = WrapResultOfResourceDto; + +export type ResourceGetByNameError = WrapResult; + +export type ResourceDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type ResourceDeleteResponse = WrapResult; + +export type ResourceDeleteError = WrapResult; + +export type ResourceUpdateData = { + body?: ResourceUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type ResourceUpdateResponse = WrapResultOfResourceDto; + +export type ResourceUpdateError = WrapResult; + +export type ResourceCreateData = { + body?: ResourceCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ResourceCreateResponse = WrapResultOfResourceDto; + +export type ResourceCreateError = WrapResult; + +export type ResourceGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type ResourceGetListResponse = WrapResultOfListResultDtoOfResourceDto; + +export type ResourceGetListError = WrapResult; + +export type RestoreHandleData = { + body?: { + ContentType?: string; + ContentDisposition?: string; + Headers?: { + [key: string]: Array; + }; + Length?: number; + Name?: string; + FileName?: string; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type RestoreHandleResponse = unknown; + +export type RestoreHandleError = ProblemDetails; + +export type RetractHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: ApiVersion; + workflowDefinitionId: string; + }; +}; + +export type RetractHandleResponse = WorkflowDefinition; + +export type RetractHandleError = ProblemDetails; + +export type RetryHandleData = { + body?: RetryWorkflowRequest; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + id: string; + }; +}; + +export type RetryHandleResponse = unknown; + +export type RetryHandleError = ProblemDetails; + +export type RevertHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: ApiVersion; + definitionId: string; + version: number; + }; +}; + +export type RevertHandleResponse = WorkflowDefinition; + +export type RevertHandleError = ProblemDetails; + +export type RoleGetOrganizationUnitsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleGetOrganizationUnitsResponse = WrapResultOfListResultDtoOfOrganizationUnitDto; + +export type RoleGetOrganizationUnitsError = WrapResult; + +export type RoleSetOrganizationUnitsData = { + body?: IdentityRoleAddOrRemoveOrganizationUnitDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleSetOrganizationUnitsResponse = WrapResult; + +export type RoleSetOrganizationUnitsError = WrapResult; + +export type RoleRemoveOrganizationUnitsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + ouId: string; + }; +}; + +export type RoleRemoveOrganizationUnitsResponse = WrapResult; + +export type RoleRemoveOrganizationUnitsError = WrapResult; + +export type RoleGetClaimsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleGetClaimsResponse = WrapResultOfListResultDtoOfIdentityClaimDto; + +export type RoleGetClaimsError = WrapResult; + +export type RoleAddClaimData = { + body?: IdentityRoleClaimCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleAddClaimResponse = WrapResult; + +export type RoleAddClaimError = WrapResult; + +export type RoleUpdateClaimData = { + body?: IdentityRoleClaimUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleUpdateClaimResponse = WrapResult; + +export type RoleUpdateClaimError = WrapResult; + +export type RoleDeleteClaimData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; + query: { + ClaimType: string; + ClaimValue: string; + }; +}; + +export type RoleDeleteClaimResponse = WrapResult; + +export type RoleDeleteClaimError = WrapResult; + +export type RoleGetAllListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type RoleGetAllListResponse = WrapResultOfListResultDtoOfIdentityRoleDto; + +export type RoleGetAllListError = WrapResult; + +export type RoleGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ExtraProperties?: { + [key: string]: unknown; + }; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type RoleGetListResponse = WrapResultOfPagedResultDtoOfIdentityRoleDto; + +export type RoleGetListError = WrapResult; + +export type RoleCreateData = { + body?: IdentityRoleCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type RoleCreateResponse = WrapResultOfIdentityRoleDto; + +export type RoleCreateError = WrapResult; + +export type RoleGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleGetResponse = WrapResultOfIdentityRoleDto; + +export type RoleGetError = WrapResult; + +export type RoleUpdateData = { + body?: IdentityRoleUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleUpdateResponse = WrapResultOfIdentityRoleDto; + +export type RoleUpdateError = WrapResult; + +export type RoleDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleDeleteResponse = WrapResult; + +export type RoleDeleteError = WrapResult; + +export type RoleEntityRuleGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + EntityTypeId: string; + Operation: DataAccessOperation; + RoleName: string; + }; +}; + +export type RoleEntityRuleGetResponse = WrapResultOfRoleEntityRuleDto; + +export type RoleEntityRuleGetError = WrapResult; + +export type RoleEntityRuleCreateData = { + body?: RoleEntityRuleCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type RoleEntityRuleCreateResponse = WrapResultOfRoleEntityRuleDto; + +export type RoleEntityRuleCreateError = WrapResult; + +export type RoleEntityRuleUpdateData = { + body?: RoleEntityRuleUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type RoleEntityRuleUpdateResponse = WrapResultOfRoleEntityRuleDto; + +export type RoleEntityRuleUpdateError = WrapResult; + +export type SecurityLogDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type SecurityLogDeleteResponse = WrapResult; + +export type SecurityLogDeleteError = WrapResult; + +export type SecurityLogGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type SecurityLogGetResponse = WrapResultOfSecurityLogDto; + +export type SecurityLogGetError = WrapResult; + +export type SecurityLogGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ActionName?: string; + ApplicationName?: string; + ClientId?: string; + CorrelationId?: string; + EndTime?: string; + Identity?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + StartTime?: string; + UserId?: string; + UserName?: string; + }; +}; + +export type SecurityLogGetListResponse = WrapResultOfPagedResultDtoOfSecurityLogDto; + +export type SecurityLogGetListError = WrapResult; + +export type SettingSetCurrentTenantData = { + body?: UpdateSettingsDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type SettingSetCurrentTenantResponse = WrapResult; + +export type SettingSetCurrentTenantError = WrapResult; + +export type SettingSetGlobalData = { + body?: UpdateSettingsDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type SettingSetGlobalResponse = WrapResult; + +export type SettingSetGlobalError = WrapResult; + +export type SettingGetAllForGlobalData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type SettingGetAllForGlobalResponse = WrapResultOfSettingGroupResult; + +export type SettingGetAllForGlobalError = WrapResult; + +export type SettingGetAllForCurrentTenantData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type SettingGetAllForCurrentTenantResponse = WrapResultOfSettingGroupResult; + +export type SettingGetAllForCurrentTenantError = WrapResult; + +export type SettingSendTestEmailData = { + body?: SendTestEmailInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type SettingSendTestEmailResponse = WrapResult; + +export type SettingSendTestEmailError = WrapResult; + +export type SettingDefinitionCreateData = { + body?: SettingDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type SettingDefinitionCreateResponse = WrapResultOfSettingDefinitionDto; + +export type SettingDefinitionCreateError = WrapResult; + +export type SettingDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + ProviderName?: string; + }; +}; + +export type SettingDefinitionGetListResponse = WrapResultOfListResultDtoOfSettingDefinitionDto; + +export type SettingDefinitionGetListError = WrapResult; + +export type SettingDefinitionDeleteOrRestoreData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type SettingDefinitionDeleteOrRestoreResponse = WrapResult; + +export type SettingDefinitionDeleteOrRestoreError = WrapResult; + +export type SettingDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type SettingDefinitionGetResponse = WrapResultOfSettingDefinitionDto; + +export type SettingDefinitionGetError = WrapResult; + +export type SettingDefinitionUpdateData = { + body?: SettingDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type SettingDefinitionUpdateResponse = WrapResultOfSettingDefinitionDto; + +export type SettingDefinitionUpdateError = WrapResult; + +export type StaticFilesUploadData = { + body?: { + Bucket?: string; + Path?: string; + FileName?: string; + Overwrite?: boolean; + File?: IRemoteStreamContent; + ExpirationTime?: TimeSpan; + }; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type StaticFilesUploadResponse = WrapResultOfOssObjectDto; + +export type StaticFilesUploadError = WrapResult; + +export type StaticFilesGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + }; +}; + +export type StaticFilesGetResponse = IRemoteStreamContent; + +export type StaticFilesGetError = RemoteServiceErrorResponse; + +export type StaticFilesGet1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + Process: string; + }; +}; + +export type StaticFilesGet1Response = IRemoteStreamContent; + +export type StaticFilesGet1Error = RemoteServiceErrorResponse; + +export type StaticFilesGet2Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + Path: string; + }; +}; + +export type StaticFilesGet2Response = IRemoteStreamContent; + +export type StaticFilesGet2Error = RemoteServiceErrorResponse; + +export type StaticFilesGet3Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + Path: string; + Process: string; + }; +}; + +export type StaticFilesGet3Response = IRemoteStreamContent; + +export type StaticFilesGet3Error = RemoteServiceErrorResponse; + +export type StaticFilesGet4Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + TenantId: string; + }; +}; + +export type StaticFilesGet4Response = IRemoteStreamContent; + +export type StaticFilesGet4Error = RemoteServiceErrorResponse; + +export type StaticFilesGet5Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + Process: string; + TenantId: string; + }; +}; + +export type StaticFilesGet5Response = IRemoteStreamContent; + +export type StaticFilesGet5Error = RemoteServiceErrorResponse; + +export type StaticFilesGet6Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + Path: string; + TenantId: string; + }; +}; + +export type StaticFilesGet6Response = IRemoteStreamContent; + +export type StaticFilesGet6Error = RemoteServiceErrorResponse; + +export type StaticFilesGet7Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Bucket: string; + Name: string; + Path: string; + Process: string; + TenantId: string; + }; +}; + +export type StaticFilesGet7Response = IRemoteStreamContent; + +export type StaticFilesGet7Error = RemoteServiceErrorResponse; + +export type TenantGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type TenantGetResponse = WrapResultOfTenantDto; + +export type TenantGetError = WrapResult; + +export type TenantUpdateData = { + body?: TenantUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type TenantUpdateResponse = WrapResultOfTenantDto; + +export type TenantUpdateError = WrapResult; + +export type TenantDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type TenantDeleteResponse = WrapResult; + +export type TenantDeleteError = WrapResult; + +export type TenantGet1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type TenantGet1Response = WrapResultOfTenantDto; + +export type TenantGet1Error = WrapResult; + +export type TenantGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type TenantGetListResponse = WrapResultOfPagedResultDtoOfTenantDto; + +export type TenantGetListError = WrapResult; + +export type TenantCreateData = { + body?: TenantCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type TenantCreateResponse = WrapResultOfTenantDto; + +export type TenantCreateError = WrapResult; + +export type TenantGetConnectionStringData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + name: string; + }; +}; + +export type TenantGetConnectionStringResponse = WrapResultOfTenantConnectionStringDto; + +export type TenantGetConnectionStringError = WrapResult; + +export type TenantDeleteConnectionStringData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + name: string; + }; +}; + +export type TenantDeleteConnectionStringResponse = WrapResult; + +export type TenantDeleteConnectionStringError = WrapResult; + +export type TenantGetConnectionString1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type TenantGetConnectionString1Response = WrapResultOfListResultDtoOfTenantConnectionStringDto; + +export type TenantGetConnectionString1Error = WrapResult; + +export type TenantSetConnectionStringData = { + body?: TenantConnectionStringCreateOrUpdate; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type TenantSetConnectionStringResponse = WrapResultOfTenantConnectionStringDto; + +export type TenantSetConnectionStringError = WrapResult; + +export type TextSetTextData = { + body?: SetTextInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type TextSetTextResponse = WrapResult; + +export type TextSetTextError = WrapResult; + +export type TextRestoreToDefaultData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + CultureName: string; + Key: string; + ResourceName: string; + }; +}; + +export type TextRestoreToDefaultResponse = WrapResult; + +export type TextRestoreToDefaultError = WrapResult; + +export type TextGetByCultureKeyData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + CultureName: string; + Key: string; + ResourceName: string; + }; +}; + +export type TextGetByCultureKeyResponse = WrapResultOfTextDto; + +export type TextGetByCultureKeyError = WrapResult; + +export type TextGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + CultureName: string; + Filter?: string; + OnlyNull?: boolean; + ResourceName?: string; + TargetCultureName: string; + }; +}; + +export type TextGetListResponse = WrapResultOfListResultDtoOfTextDifferenceDto; + +export type TextGetListError = WrapResult; + +export type TextTemplateContentGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Name: string; + }; + query?: { + Culture?: string; + }; +}; + +export type TextTemplateContentGetResponse = WrapResultOfTextTemplateContentDto; + +export type TextTemplateContentGetError = WrapResult; + +export type TextTemplateContentGet1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + Culture: string; + Name: string; + }; +}; + +export type TextTemplateContentGet1Response = WrapResultOfTextTemplateContentDto; + +export type TextTemplateContentGet1Error = WrapResult; + +export type TextTemplateContentRestoreToDefaultData = { + body?: TextTemplateRestoreInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type TextTemplateContentRestoreToDefaultResponse = WrapResult; + +export type TextTemplateContentRestoreToDefaultError = WrapResult; + +export type TextTemplateContentUpdateData = { + body?: TextTemplateContentUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type TextTemplateContentUpdateResponse = WrapResultOfTextTemplateContentDto; + +export type TextTemplateContentUpdateError = WrapResult; + +export type TextTemplateDefinitionCreateData = { + body?: TextTemplateDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type TextTemplateDefinitionCreateResponse = WrapResultOfTextTemplateDefinitionDto; + +export type TextTemplateDefinitionCreateError = WrapResult; + +export type TextTemplateDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + IsLayout?: boolean; + IsStatic?: boolean; + }; +}; + +export type TextTemplateDefinitionGetListResponse = WrapResultOfListResultDtoOfTextTemplateDefinitionDto; + +export type TextTemplateDefinitionGetListError = WrapResult; + +export type TextTemplateDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type TextTemplateDefinitionDeleteResponse = WrapResult; + +export type TextTemplateDefinitionDeleteError = WrapResult; + +export type TextTemplateDefinitionGetByNameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type TextTemplateDefinitionGetByNameResponse = WrapResultOfTextTemplateDefinitionDto; + +export type TextTemplateDefinitionGetByNameError = WrapResult; + +export type TextTemplateDefinitionUpdateData = { + body?: TextTemplateDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type TextTemplateDefinitionUpdateResponse = WrapResultOfTextTemplateDefinitionDto; + +export type TextTemplateDefinitionUpdateError = WrapResult; + +export type ThemeSettingGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ThemeSettingGetResponse = WrapResultOfThemeSettingDto; + +export type ThemeSettingGetError = WrapResult; + +export type ThemeSettingChangeData = { + body?: ThemeSettingDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type ThemeSettingChangeResponse = WrapResult; + +export type ThemeSettingChangeError = WrapResult; + +export type TriggerHandleData = { + body?: TriggerWorkflowsRequestModel; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + apiVersion: string; + }; +}; + +export type TriggerHandleResponse = TriggerWorkflowsRequestModel; + +export type TriggerHandleError = ProblemDetails; + +export type TriggerEndpointHandleData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + token: string; + }; +}; + +export type TriggerEndpointHandleResponse = unknown; + +export type TriggerEndpointHandleError = unknown; + +export type TriggerEndpointHandle1Data = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + token: string; + }; +}; + +export type TriggerEndpointHandle1Response = unknown; + +export type TriggerEndpointHandle1Error = unknown; + +export type UserGetOrganizationUnitsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserGetOrganizationUnitsResponse = WrapResultOfListResultDtoOfOrganizationUnitDto; + +export type UserGetOrganizationUnitsError = WrapResult; + +export type UserSetOrganizationUnitsData = { + body?: IdentityUserOrganizationUnitUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserSetOrganizationUnitsResponse = WrapResult; + +export type UserSetOrganizationUnitsError = WrapResult; + +export type UserRemoveOrganizationUnitsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + ouId: string; + }; +}; + +export type UserRemoveOrganizationUnitsResponse = WrapResult; + +export type UserRemoveOrganizationUnitsError = WrapResult; + +export type UserGetClaimsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserGetClaimsResponse = WrapResultOfListResultDtoOfIdentityClaimDto; + +export type UserGetClaimsError = WrapResult; + +export type UserAddClaimData = { + body?: IdentityUserClaimCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserAddClaimResponse = WrapResult; + +export type UserAddClaimError = WrapResult; + +export type UserUpdateClaimData = { + body?: IdentityUserClaimUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserUpdateClaimResponse = WrapResult; + +export type UserUpdateClaimError = WrapResult; + +export type UserDeleteClaimData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; + query: { + ClaimType: string; + ClaimValue?: string; + }; +}; + +export type UserDeleteClaimResponse = WrapResult; + +export type UserDeleteClaimError = WrapResult; + +export type UserChangePasswordData = { + body?: IdentityUserSetPasswordInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + id?: string; + }; +}; + +export type UserChangePasswordResponse = WrapResult; + +export type UserChangePasswordError = WrapResult; + +export type UserChangeTwoFactorEnabledData = { + body?: TwoFactorEnabledDto_1; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + id?: string; + }; +}; + +export type UserChangeTwoFactorEnabledResponse = WrapResult; + +export type UserChangeTwoFactorEnabledError = WrapResult; + +export type UserLockData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + seconds: number; + }; +}; + +export type UserLockResponse = WrapResult; + +export type UserLockError = WrapResult; + +export type UserUnLockData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserUnLockResponse = WrapResult; + +export type UserUnLockError = WrapResult; + +export type UserGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserGetResponse = WrapResultOfIdentityUserDto; + +export type UserGetError = WrapResult; + +export type UserUpdateData = { + body?: IdentityUserUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserUpdateResponse = WrapResultOfIdentityUserDto; + +export type UserUpdateError = WrapResult; + +export type UserDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserDeleteResponse = WrapResult; + +export type UserDeleteError = WrapResult; + +export type UserGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ExtraProperties?: { + [key: string]: unknown; + }; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type UserGetListResponse = WrapResultOfPagedResultDtoOfIdentityUserDto; + +export type UserGetListError = WrapResult; + +export type UserCreateData = { + body?: IdentityUserCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserCreateResponse = WrapResultOfIdentityUserDto; + +export type UserCreateError = WrapResult; + +export type UserGetRolesData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserGetRolesResponse = WrapResultOfListResultDtoOfIdentityRoleDto; + +export type UserGetRolesError = WrapResult; + +export type UserUpdateRolesData = { + body?: IdentityUserUpdateRolesDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserUpdateRolesResponse = WrapResult; + +export type UserUpdateRolesError = WrapResult; + +export type UserGetAssignableRolesData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserGetAssignableRolesResponse = WrapResultOfListResultDtoOfIdentityRoleDto; + +export type UserGetAssignableRolesError = WrapResult; + +export type UserFindByUsernameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + userName: string; + }; +}; + +export type UserFindByUsernameResponse = WrapResultOfIdentityUserDto; + +export type UserFindByUsernameError = WrapResult; + +export type UserFindByEmailData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + email: string; + }; +}; + +export type UserFindByEmailResponse = WrapResultOfIdentityUserDto; + +export type UserFindByEmailError = WrapResult; + +export type UserFavoriteMenuCreateData = { + body?: UserFavoriteMenuCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + userId: string; + }; +}; + +export type UserFavoriteMenuCreateResponse = WrapResultOfUserFavoriteMenuDto; + +export type UserFavoriteMenuCreateError = WrapResult; + +export type UserFavoriteMenuGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + userId: string; + }; + query?: { + Framework?: string; + }; +}; + +export type UserFavoriteMenuGetListResponse = WrapResultOfListResultDtoOfUserFavoriteMenuDto; + +export type UserFavoriteMenuGetListError = WrapResult; + +export type UserFavoriteMenuUpdateData = { + body?: UserFavoriteMenuUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + userId: string; + }; +}; + +export type UserFavoriteMenuUpdateResponse = WrapResultOfUserFavoriteMenuDto; + +export type UserFavoriteMenuUpdateError = WrapResult; + +export type UserFavoriteMenuCreateMyFavoriteMenuData = { + body?: UserFavoriteMenuCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserFavoriteMenuCreateMyFavoriteMenuResponse = WrapResultOfUserFavoriteMenuDto; + +export type UserFavoriteMenuCreateMyFavoriteMenuError = WrapResult; + +export type UserFavoriteMenuGetMyFavoriteMenuListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Framework?: string; + }; +}; + +export type UserFavoriteMenuGetMyFavoriteMenuListResponse = WrapResultOfListResultDtoOfUserFavoriteMenuDto; + +export type UserFavoriteMenuGetMyFavoriteMenuListError = WrapResult; + +export type UserFavoriteMenuUpdateMyFavoriteMenuData = { + body?: UserFavoriteMenuUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserFavoriteMenuUpdateMyFavoriteMenuResponse = WrapResultOfUserFavoriteMenuDto; + +export type UserFavoriteMenuUpdateMyFavoriteMenuError = WrapResult; + +export type UserFavoriteMenuDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + MenuId: string; + userId: string; + }; +}; + +export type UserFavoriteMenuDeleteResponse = WrapResult; + +export type UserFavoriteMenuDeleteError = WrapResult; + +export type UserFavoriteMenuDeleteMyFavoriteMenuData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + MenuId: string; + }; +}; + +export type UserFavoriteMenuDeleteMyFavoriteMenuResponse = WrapResult; + +export type UserFavoriteMenuDeleteMyFavoriteMenuError = WrapResult; + +export type UserGroupApplyJoinGroupData = { + body?: UserJoinGroupDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserGroupApplyJoinGroupResponse = WrapResult; + +export type UserGroupApplyJoinGroupError = WrapResult; + +export type UserGroupGetGroupUsersData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query: { + Filter?: string; + GroupId: number; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type UserGroupGetGroupUsersResponse = WrapResultOfPagedResultDtoOfGroupUserCard; + +export type UserGroupGetGroupUsersError = WrapResult; + +export type UserGroupGetMyGroupsData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserGroupGetMyGroupsResponse = WrapResultOfListResultDtoOfGroup; + +export type UserGroupGetMyGroupsError = WrapResult; + +export type UserGroupGroupAcceptUserData = { + body?: GroupAcceptUserDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserGroupGroupAcceptUserResponse = WrapResult; + +export type UserGroupGroupAcceptUserError = WrapResult; + +export type UserGroupGroupRemoveUserData = { + body?: GroupRemoveUserDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserGroupGroupRemoveUserResponse = WrapResult; + +export type UserGroupGroupRemoveUserError = WrapResult; + +export type UserLookupFindByIdData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type UserLookupFindByIdResponse = WrapResultOfUserData; + +export type UserLookupFindByIdError = WrapResult; + +export type UserLookupFindByUserNameData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + userName: string; + }; +}; + +export type UserLookupFindByUserNameResponse = WrapResultOfUserData; + +export type UserLookupFindByUserNameError = WrapResult; + +export type UserLookupSearchData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + ExtraProperties?: { + [key: string]: unknown; + }; + Filter?: string; + MaxResultCount?: number; + SkipCount?: number; + Sorting?: string; + }; +}; + +export type UserLookupSearchResponse = WrapResultOfListResultDtoOfUserData; + +export type UserLookupSearchError = WrapResult; + +export type UserLookupGetCountData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type UserLookupGetCountResponse = WrapResultOfInt64; + +export type UserLookupGetCountError = WrapResult; + +export type UserSettingGetAllForCurrentUserData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserSettingGetAllForCurrentUserResponse = WrapResultOfSettingGroupResult; + +export type UserSettingGetAllForCurrentUserError = WrapResult; + +export type UserSettingSetCurrentUserData = { + body?: UpdateSettingsDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type UserSettingSetCurrentUserResponse = WrapResult; + +export type UserSettingSetCurrentUserError = WrapResult; + +export type WebhookDefinitionCreateData = { + body?: WebhookDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookDefinitionCreateResponse = WrapResultOfWebhookDefinitionDto; + +export type WebhookDefinitionCreateError = WrapResult; + +export type WebhookDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + GroupName?: string; + }; +}; + +export type WebhookDefinitionGetListResponse = WrapResultOfListResultDtoOfWebhookDefinitionDto; + +export type WebhookDefinitionGetListError = WrapResult; + +export type WebhookDefinitionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type WebhookDefinitionDeleteResponse = WrapResult; + +export type WebhookDefinitionDeleteError = WrapResult; + +export type WebhookDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type WebhookDefinitionGetResponse = WrapResultOfWebhookDefinitionDto; + +export type WebhookDefinitionGetError = WrapResult; + +export type WebhookDefinitionUpdateData = { + body?: WebhookDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type WebhookDefinitionUpdateResponse = WrapResultOfWebhookDefinitionDto; + +export type WebhookDefinitionUpdateError = WrapResult; + +export type WebhookGroupDefinitionCreateData = { + body?: WebhookGroupDefinitionCreateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookGroupDefinitionCreateResponse = WrapResultOfWebhookGroupDefinitionDto; + +export type WebhookGroupDefinitionCreateError = WrapResult; + +export type WebhookGroupDefinitionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + Filter?: string; + }; +}; + +export type WebhookGroupDefinitionGetListResponse = WrapResultOfListResultDtoOfWebhookGroupDefinitionDto; + +export type WebhookGroupDefinitionGetListError = WrapResult; + +export type WebhookGroupDefinitionDeleteAysncData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type WebhookGroupDefinitionDeleteAysncResponse = WrapResult; + +export type WebhookGroupDefinitionDeleteAysncError = WrapResult; + +export type WebhookGroupDefinitionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type WebhookGroupDefinitionGetResponse = WrapResultOfWebhookGroupDefinitionDto; + +export type WebhookGroupDefinitionGetError = WrapResult; + +export type WebhookGroupDefinitionUpdateData = { + body?: WebhookGroupDefinitionUpdateDto; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + name: string; + }; +}; + +export type WebhookGroupDefinitionUpdateResponse = WrapResultOfWebhookGroupDefinitionDto; + +export type WebhookGroupDefinitionUpdateError = WrapResult; + +export type WebhookPublishPublishData = { + body?: WebhookPublishInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookPublishPublishResponse = WrapResult; + +export type WebhookPublishPublishError = WrapResult; + +export type WebhookSendRecordGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type WebhookSendRecordGetResponse = WrapResultOfWebhookSendRecordDto; + +export type WebhookSendRecordGetError = WrapResult; + +export type WebhookSendRecordDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type WebhookSendRecordDeleteResponse = WrapResult; + +export type WebhookSendRecordDeleteError = WrapResult; + +export type WebhookSendRecordDeleteManyData = { + body?: WebhookSendRecordDeleteManyInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookSendRecordDeleteManyResponse = WrapResult; + +export type WebhookSendRecordDeleteManyError = WrapResult; + +export type WebhookSendRecordGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + BeginCreationTime?: string; + EndCreationTime?: string; + Filter?: string; + MaxResultCount?: number; + ResponseStatusCode?: HttpStatusCode; + SkipCount?: number; + Sorting?: string; + State?: boolean; + SubscriptionId?: string; + TenantId?: string; + WebhookEventId?: string; + }; +}; + +export type WebhookSendRecordGetListResponse = WrapResultOfPagedResultDtoOfWebhookSendRecordDto; + +export type WebhookSendRecordGetListError = WrapResult; + +export type WebhookSendRecordResendData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type WebhookSendRecordResendResponse = WrapResult; + +export type WebhookSendRecordResendError = WrapResult; + +export type WebhookSendRecordResendManyData = { + body?: WebhookSendRecordResendManyInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookSendRecordResendManyResponse = WrapResult; + +export type WebhookSendRecordResendManyError = WrapResult; + +export type WebhookSubscriptionCreateData = { + body?: WebhookSubscriptionCreateInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookSubscriptionCreateResponse = WrapResultOfWebhookSubscriptionDto; + +export type WebhookSubscriptionCreateError = WrapResult; + +export type WebhookSubscriptionGetListData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + query?: { + BeginCreationTime?: string; + EndCreationTime?: string; + Filter?: string; + IsActive?: boolean; + MaxResultCount?: number; + Secret?: string; + SkipCount?: number; + Sorting?: string; + TenantId?: string; + Webhooks?: string; + WebhookUri?: string; + }; +}; + +export type WebhookSubscriptionGetListResponse = WrapResultOfPagedResultDtoOfWebhookSubscriptionDto; + +export type WebhookSubscriptionGetListError = WrapResult; + +export type WebhookSubscriptionDeleteData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type WebhookSubscriptionDeleteResponse = WrapResult; + +export type WebhookSubscriptionDeleteError = WrapResult; + +export type WebhookSubscriptionGetData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type WebhookSubscriptionGetResponse = WrapResultOfWebhookSubscriptionDto; + +export type WebhookSubscriptionGetError = WrapResult; + +export type WebhookSubscriptionUpdateData = { + body?: WebhookSubscriptionUpdateInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; + path: { + id: string; + }; +}; + +export type WebhookSubscriptionUpdateResponse = WrapResultOfWebhookSubscriptionDto; + +export type WebhookSubscriptionUpdateError = WrapResult; + +export type WebhookSubscriptionDeleteManyData = { + body?: WebhookSubscriptionDeleteManyInput; + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookSubscriptionDeleteManyResponse = WrapResult; + +export type WebhookSubscriptionDeleteManyError = WrapResult; + +export type WebhookSubscriptionGetAllAvailableWebhooksData = { + headers?: { + /** + * Tenant Id in http header + */ + __tenant?: unknown; + }; +}; + +export type WebhookSubscriptionGetAllAvailableWebhooksResponse = WrapResultOfListResultDtoOfWebhookAvailableGroupDto; + +export type WebhookSubscriptionGetAllAvailableWebhooksError = WrapResult; diff --git a/apps/react-admin/src/api/management/auditing/audit-logs.ts b/apps/react-admin/src/api/management/auditing/audit-logs.ts new file mode 100644 index 000000000..2a7c528c3 --- /dev/null +++ b/apps/react-admin/src/api/management/auditing/audit-logs.ts @@ -0,0 +1,30 @@ +import type { PagedResultDto } from "#/abp-core"; + +import type { AuditLogDto, AuditLogGetListInput } from "#/management/auditing"; +import requestClient from "../../request"; + +/** + * 获取审计日志 + * @param id 日志id + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/auditing/audit-log/${id}`); +} + +/** + * 获取审计日志分页列表 + * @param input 参数 + */ +export function getPagedListApi(input: AuditLogGetListInput): Promise> { + return requestClient.get>("/api/auditing/audit-log", { + params: input, + }); +} + +/** + * 删除审计日志 + * @param id 日志id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/auditing/audit-log/${id}`); +} diff --git a/apps/react-admin/src/api/management/auditing/entity-changes.ts b/apps/react-admin/src/api/management/auditing/entity-changes.ts new file mode 100644 index 000000000..5187a6023 --- /dev/null +++ b/apps/react-admin/src/api/management/auditing/entity-changes.ts @@ -0,0 +1,16 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { EntityChangeGetWithUsernameInput, EntityChangeWithUsernameDto } from "#/management/auditing"; +import requestClient from "../../request"; + +/** + * 获取包含用户名称的实体变更列表 + * @param input 参数 + */ +export function getListWithUsernameApi( + input: EntityChangeGetWithUsernameInput, +): Promise> { + return requestClient.get>("/api/auditing/entity-changes/with-username", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/management/auditing/index.ts b/apps/react-admin/src/api/management/auditing/index.ts new file mode 100644 index 000000000..ea927ea71 --- /dev/null +++ b/apps/react-admin/src/api/management/auditing/index.ts @@ -0,0 +1,2 @@ +export * as auditLogsApi from "./audit-logs"; +export * as entityChangesApi from "./entity-changes"; diff --git a/apps/react-admin/src/api/management/identity/claim-types.ts b/apps/react-admin/src/api/management/identity/claim-types.ts new file mode 100644 index 000000000..7d4e1d9d9 --- /dev/null +++ b/apps/react-admin/src/api/management/identity/claim-types.ts @@ -0,0 +1,64 @@ +import type { ListResultDto, PagedResultDto } from "#/abp-core"; + +import type { + GetIdentityClaimTypePagedListInput, + IdentityClaimTypeCreateDto, + IdentityClaimTypeDto, + IdentityClaimTypeUpdateDto, +} from "#/management/identity"; +import requestClient from "../../request"; + +/** + * 新增用户声明 + * @param input 参数 + * @returns 用户声明实体数据传输对象 + */ +export function createApi(input: IdentityClaimTypeCreateDto): Promise { + return requestClient.post("/api/identity/claim-types", input); +} + +/** + * 删除用户声明 + * @param id 用户声明id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/identity/claim-types/${id}`); +} + +/** + * 查询用户声明 + * @param id 用户声明id + * @returns 用户声明实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/identity/claim-types/${id}`); +} + +/** + * 更新用户声明 + * @param id 用户声明id + * @returns 用户声明实体数据传输对象 + */ +export function updateApi(id: string, input: IdentityClaimTypeUpdateDto): Promise { + return requestClient.put(`/api/identity/claim-types/${id}`, input); +} + +/** + * 查询用户声明分页列表 + * @param input 过滤参数 + * @returns 用户声明实体数据传输对象分页列表 + */ +export function getPagedListApi( + input?: GetIdentityClaimTypePagedListInput, +): Promise> { + return requestClient.get>("/api/identity/claim-types", { + params: input, + }); +} + +/** + * 获取可用的声明类型列表 + */ +export function getAssignableClaimsApi(): Promise> { + return requestClient.get>("/api/identity/claim-types/actived-list"); +} diff --git a/apps/react-admin/src/api/management/identity/organization-units.ts b/apps/react-admin/src/api/management/identity/organization-units.ts new file mode 100644 index 000000000..853724019 --- /dev/null +++ b/apps/react-admin/src/api/management/identity/organization-units.ts @@ -0,0 +1,173 @@ +import type { ListResultDto, PagedResultDto } from "#/abp-core"; + +import type { IdentityRoleDto, IdentityUserDto } from "#/management/identity"; +import type { + GetIdentityRolesInput, + GetIdentityUsersInput, + GetOrganizationUnitPagedListInput, + GetUnaddedRoleListInput, + GetUnaddedUserListInput, + OrganizationUnitAddRoleDto, + OrganizationUnitAddUserDto, + OrganizationUnitCreateDto, + OrganizationUnitDto, + OrganizationUnitGetChildrenDto, + OrganizationUnitUpdateDto, +} from "#/management/identity/organization-units"; + +import requestClient from "../../request"; + +/** + * 新增组织机构 + * @param input 参数 + * @returns 组织机构实体数据传输对象 + */ +export function createApi(input: OrganizationUnitCreateDto): Promise { + return requestClient.post("/api/identity/organization-units", input); +} + +/** + * 删除组织机构 + * @param id 组织机构id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/identity/organization-units/${id}`); +} + +/** + * 查询组织机构 + * @param id 组织机构id + * @returns 组织机构实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/identity/organization-units/${id}`); +} + +/** + * 更新组织机构 + * @param id 组织机构id + * @returns 组织机构实体数据传输对象 + */ + +export function updateApi(id: string, input: OrganizationUnitUpdateDto): Promise { + return requestClient.put(`/api/identity/organization-units/${id}`, input); +} + +/** + * 查询组织机构分页列表 + * @param input 过滤参数 + * @returns 组织机构实体数据传输对象分页列表 + */ +export function getPagedListApi( + input?: GetOrganizationUnitPagedListInput, +): Promise> { + return requestClient.get>("/api/identity/organization-units", { + params: input, + }); +} + +/** + * 查询根组织机构列表 + * @returns 组织机构实体数据传输对象列表 + */ +export function getRootListApi(): Promise> { + return requestClient.get>("/api/identity/organization-units/root-node"); +} + +/** + * 查询组织机构列表 + * @returns 组织机构实体数据传输对象列表 + */ +export function getAllListApi(): Promise> { + return requestClient.get>("/api/identity/organization-units/all"); +} + +/** + * 查询下级组织机构列表 + * @param input 查询参数 + * @returns 组织机构实体数据传输对象列表 + */ +export function getChildrenApi(input: OrganizationUnitGetChildrenDto): Promise> { + return requestClient.get>("/api/identity/organization-units/find-children", { + params: input, + }); +} + +/** + * 查询组织机构用户列表 + * @param id 组织机构id + * @param input 查询过滤参数 + * @returns 用户实体数据传输对象分页列表 + */ +export function getUserListApi(id: string, input?: GetIdentityUsersInput): Promise> { + return requestClient.get>(`/api/identity/organization-units/${id}/users`, { + params: input, + }); +} + +/** + * 查询未加入组织机构的用户列表 + * @param input 查询过滤参数 + * @returns 用户实体数据传输对象分页列表 + */ +export function getUnaddedUserListApi(input: GetUnaddedUserListInput): Promise> { + return requestClient.get>( + `/api/identity/organization-units/${input.id}/unadded-users`, + { + params: input, + }, + ); +} + +/** + * 用户添加到组织机构 + * @param id 组织机构id + * @param input 用户id列表 + */ +export function addMembers(id: string, input: OrganizationUnitAddUserDto): Promise { + return requestClient.post(`/api/identity/organization-units/${id}/users`, input); +} + +/** + * 查询组织机构角色列表 + * @param id 组织机构id + * @param input 查询过滤参数 + * @returns 角色实体数据传输对象分页列表 + */ +export function getRoleListApi(id: string, input?: GetIdentityRolesInput): Promise> { + return requestClient.get>(`/api/identity/organization-units/${id}/roles`, { + params: input, + }); +} + +/** + * 查询未加入组织机构的角色列表 + * @param input 查询过滤参数 + * @returns 角色实体数据传输对象分页列表 + */ +export function getUnaddedRoleListApi(input: GetUnaddedRoleListInput): Promise> { + return requestClient.get>( + `/api/identity/organization-units/${input.id}/unadded-roles`, + { + params: input, + }, + ); +} + +/** + * 角色添加到组织机构 + * @param id 组织机构id + * @param input 角色id列表 + */ +export function addRoles(id: string, input: OrganizationUnitAddRoleDto): Promise { + return requestClient.post(`/api/identity/organization-units/${id}/roles`, input); +} + +/** + * 移动组织机构 + * @param id 组织机构id + * @param parentId 父级组织机构id + */ +export function moveTo(id: string, parentId?: string): Promise { + return requestClient.put(`api/identity/organization-units/${id}/move`, { parentId }); +} diff --git a/apps/react-admin/src/api/management/identity/role.ts b/apps/react-admin/src/api/management/identity/role.ts new file mode 100644 index 000000000..98929cefe --- /dev/null +++ b/apps/react-admin/src/api/management/identity/role.ts @@ -0,0 +1,109 @@ +import type { PagedResultDto, ListResultDto } from "#/abp-core"; + +import type { + IdentityClaimCreateDto, + IdentityClaimDeleteDto, + IdentityClaimDto, + IdentityClaimUpdateDto, +} from "#/management/identity/claims"; + +import type { + GetRolePagedListInput, + IdentityRoleCreateDto, + IdentityRoleDto, + IdentityRoleUpdateDto, +} from "#/management/identity"; + +import requestClient from "../../request"; + +/** + * 新增角色 + * @param input 参数 + * @returns 角色实体数据传输对象 + */ +export function createApi(input: IdentityRoleCreateDto): Promise { + return requestClient.post("/api/identity/roles", input); +} + +/** + * 删除角色 + * @param id 角色id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/identity/roles/${id}`); +} + +/** + * 查询角色 + * @param id 角色id + * @returns 角色实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/identity/roles/${id}`); +} + +/** + * 更新角色 + * @param id 角色id + * @returns 角色实体数据传输对象 + */ +export function updateApi(id: string, input: IdentityRoleUpdateDto): Promise { + return requestClient.put(`/api/identity/roles/${id}`, input); +} + +/** + * 查询角色分页列表 + * @param input 过滤参数 + * @returns 角色实体数据传输对象分页列表 + */ +export function getPagedListApi(input?: GetRolePagedListInput): Promise> { + return requestClient.get>("/api/identity/roles", { + params: input, + }); +} + +/** + * 从组织机构中移除角色 + * @param id 角色id + * @param ouId 组织机构id + */ +export function removeOrganizationUnitApi(id: string, ouId: string): Promise { + return requestClient.delete(`/api/identity/roles/${id}/organization-units/${ouId}`); +} + +/** + * 获取角色声明列表 + * @param id 角色id + */ +export function getClaimsApi(id: string): Promise> { + return requestClient.get>(`/api/identity/roles/${id}/claims`); +} + +/** + * 删除角色声明 + * @param id 角色id + * @param input 角色声明dto + */ +export function deleteClaimApi(id: string, input: IdentityClaimDeleteDto): Promise { + return requestClient.delete(`/api/identity/roles/${id}/claims`, { + params: input, + }); +} + +/** + * 创建角色声明 + * @param id 角色id + * @param input 角色声明dto + */ +export function createClaimApi(id: string, input: IdentityClaimCreateDto): Promise { + return requestClient.post(`/api/identity/roles/${id}/claims`, input); +} + +/** + * 更新角色声明 + * @param id 角色id + * @param input 用户角色dto + */ +export function updateClaimApi(id: string, input: IdentityClaimUpdateDto): Promise { + return requestClient.put(`/api/identity/roles/${id}/claims`, input); +} diff --git a/apps/react-admin/src/api/management/identity/security-logs.ts b/apps/react-admin/src/api/management/identity/security-logs.ts new file mode 100644 index 000000000..dba450801 --- /dev/null +++ b/apps/react-admin/src/api/management/identity/security-logs.ts @@ -0,0 +1,31 @@ +import type { GetSecurityLogPagedRequest, SecurityLogDto } from "#/management/identity"; +import type { PagedResultDto } from "#/abp-core"; +import requestClient from "../../request"; + +/** + * 删除安全日志 + * @param id 安全日志id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/auditing/security-log/${id}`); +} + +/** + * 查询安全日志 + * @param id 安全日志id + * @returns 安全日志实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/auditing/security-log/${id}`); +} + +/** + * 查询安全日志分页列表 + * @param input 过滤参数 + * @returns 安全日志实体数据传输对象分页列表 + */ +export function getPagedListApi(input?: GetSecurityLogPagedRequest): Promise> { + return requestClient.get>("/api/auditing/security-log", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/management/identity/user-lookup.ts b/apps/react-admin/src/api/management/identity/user-lookup.ts new file mode 100644 index 000000000..d2f253d28 --- /dev/null +++ b/apps/react-admin/src/api/management/identity/user-lookup.ts @@ -0,0 +1,44 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { IdentityUserDto, UserLookupCountInput, UserLookupSearchInput } from "#/management/identity/user"; + +import requestClient from "../../request"; + +/** + * 通过id查询用户 + * @param id 用户id + * @returns 用户实体数据传输对象 + */ +export function findByIdApi(id: string): Promise { + return requestClient.get(`/api/identity/users/lookup/${id}`); +} + +/** + * 通过用户名查询用户 + * @param userName 用户名 + * @returns 用户实体数据传输对象 + */ +export function findByUserNameApi(userName: string): Promise { + return requestClient.get(`/api/identity/users/lookup/by-username/${userName}`); +} + +/** + * 搜索用户列表 + * @param input 搜索过滤条件 + * @returns 用户实体数据传输对象列表 + */ +export function searchApi(input?: UserLookupSearchInput): Promise> { + return requestClient.get>("/api/identity/users/lookup/search", { + params: input, + }); +} + +/** + * 搜索用户数量 + * @param input 搜索过滤条件 + */ +export function countApi(input?: UserLookupCountInput): Promise { + return requestClient.get("/api/identity/users/lookup/count", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/management/identity/user-sessions.ts b/apps/react-admin/src/api/management/identity/user-sessions.ts new file mode 100644 index 000000000..d926b6e16 --- /dev/null +++ b/apps/react-admin/src/api/management/identity/user-sessions.ts @@ -0,0 +1,22 @@ +import type { PagedResultDto } from "#/abp-core"; +import type { GetUserSessionsInput, IdentitySessionDto } from "#/management/identity/sessions"; +import requestClient from "@/api/request"; + +/** + * 查询会话列表 + * @param { GetUserSessionsInput } input 查询参数 + * @returns { Promise> } 用户会话列表 + */ +export function getSessionsApi(input?: GetUserSessionsInput): Promise> { + return requestClient.get>("/api/identity/sessions", { + params: input, + }); +} +/** + * 撤销会话 + * @param { string } sessionId 会话id + * @returns { Promise } + */ +export function revokeSessionApi(sessionId: string): Promise { + return requestClient.delete(`/api/identity/sessions/${sessionId}/revoke`); +} diff --git a/apps/react-admin/src/api/management/identity/users.ts b/apps/react-admin/src/api/management/identity/users.ts new file mode 100644 index 000000000..0a1a3174b --- /dev/null +++ b/apps/react-admin/src/api/management/identity/users.ts @@ -0,0 +1,155 @@ +import type { ListResultDto, PagedResultDto } from "#/abp-core"; +import type { IdentityRoleDto, OrganizationUnitDto } from "#/management/identity"; +import type { + IdentityClaimCreateDto, + IdentityClaimDeleteDto, + IdentityClaimDto, + IdentityClaimUpdateDto, +} from "#/management/identity/claims"; +import type { + ChangeUserPasswordInput, + GetUserPagedListInput, + IdentityUserCreateDto, + IdentityUserDto, + IdentityUserUpdateDto, +} from "#/management/identity"; +import requestClient from "../../request"; + +/** + * 新增用户 + * @param input 参数 + * @returns 用户实体数据传输对象 + */ +export function createApi(input: IdentityUserCreateDto): Promise { + return requestClient.post("/api/identity/users", input); +} + +/** + * 删除用户 + * @param id 用户id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/identity/users/${id}`); +} + +/** + * 查询用户 + * @param id 用户id + * @returns 用户实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/identity/users/${id}`); +} + +/** + * 更新用户 + * @param id 用户id + * @returns 用户实体数据传输对象 + */ +export function updateApi(id: string, input: IdentityUserUpdateDto): Promise { + return requestClient.put(`/api/identity/users/${id}`, input); +} + +/** + * 查询用户分页列表 + * @param input 过滤参数 + * @returns 用户实体数据传输对象分页列表 + */ +export function getPagedListApi(input?: GetUserPagedListInput): Promise> { + return requestClient.get>("/api/identity/users", { + params: input, + }); +} + +/** + * 从组织机构中移除用户 + * @param id 用户id + * @param ouId 组织机构id + */ +export function removeOrganizationUnitApi(id: string, ouId: string): Promise { + return requestClient.delete(`/api/identity/users/${id}/organization-units/${ouId}`); +} + +/** + * 获取用户组织机构列表 + * @param id 用户id + */ +export function getOrganizationUnitsApi(id: string): Promise> { + return requestClient.get>(`/api/identity/users/${id}/organization-units`); +} + +/** + * 锁定用户 + * @param id 用户id + * @param seconds 锁定时长(秒) + */ +export function lockApi(id: string, seconds: number): Promise { + return requestClient.put(`/api/identity/users/${id}/lock/${seconds}`); +} + +/** + * 解锁用户 + * @param id 用户id + */ +export function unLockApi(id: string): Promise { + return requestClient.put(`/api/identity/users/${id}/unlock`); +} + +/** + * 更改用户密码 + * @param id 用户id + * @param input 密码变更dto + */ +export function changePasswordApi(id: string, input: ChangeUserPasswordInput): Promise { + return requestClient.put(`/api/identity/users/change-password?id=${id}`, input); +} + +/** + * 获取可用的角色列表 + */ +export function getAssignableRolesApi(): Promise> { + return requestClient.get>("/api/identity/users/assignable-roles"); +} + +/** + * 获取用户角色列表 + * @param id 用户id + */ +export function getRolesApi(id: string): Promise> { + return requestClient.get>(`/api/identity/users/${id}/roles`); +} + +/** + * 获取用户声明列表 + * @param id 用户id + */ +export function getClaimsApi(id: string): Promise> { + return requestClient.get>(`/api/identity/users/${id}/claims`); +} + +/** + * 删除用户声明 + * @param id 用户id + * @param input 用户声明dto + */ +export function deleteClaimApi(id: string, input: IdentityClaimDeleteDto): Promise { + return requestClient.delete(`/api/identity/users/${id}/claims`, { params: input }); +} + +/** + * 创建用户声明 + * @param id 用户id + * @param input 用户声明dto + */ +export function createClaimApi(id: string, input: IdentityClaimCreateDto): Promise { + return requestClient.post(`/api/identity/users/${id}/claims`, input); +} + +/** + * 更新用户声明 + * @param id 用户id + * @param input 用户声明dto + */ +export function updateClaimApi(id: string, input: IdentityClaimUpdateDto): Promise { + return requestClient.put(`/api/identity/users/${id}/claims`, input); +} diff --git a/apps/react-admin/src/api/management/notifications/my-notifications.ts b/apps/react-admin/src/api/management/notifications/my-notifications.ts new file mode 100644 index 000000000..70bb6a834 --- /dev/null +++ b/apps/react-admin/src/api/management/notifications/my-notifications.ts @@ -0,0 +1,35 @@ +import type { PagedResultDto } from "#/abp-core"; + +import type { + GetMyNotifilerPagedListInput, + MarkReadStateInput, + UserNotificationDto, +} from "#/notifications/my-notifilers"; + +import requestClient from "@/api/request"; +/** + * 获取我的通知列表 + * @param {GetMyNotifilerPagedListInput} input 参数 + * @returns {Promise>} 通知分页列表 + */ +export function getMyNotifilersApi(input?: GetMyNotifilerPagedListInput): Promise> { + return requestClient.get>("/api/notifications/my-notifilers", { + params: input, + }); +} +/** + * 删除我的通知 + * @param {string} id 通知id + * @returns {void} + */ +export function deleteMyNotifilerApi(id: string): Promise { + return requestClient.delete(`/api/notifications/my-notifilers/${id}`); +} +/** + * 设置通知已读状态 + * @param {MarkReadStateInput} input 参数 + * @returns {void} + */ +export function markReadStateApi(input: MarkReadStateInput): Promise { + return requestClient.put("/api/notifications/my-notifilers/mark-read-state", input); +} diff --git a/apps/react-admin/src/api/management/notifications/notifications.ts b/apps/react-admin/src/api/management/notifications/notifications.ts new file mode 100644 index 000000000..a0121fe4f --- /dev/null +++ b/apps/react-admin/src/api/management/notifications/notifications.ts @@ -0,0 +1,39 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { NotificationGroupDto, NotificationTemplateDto } from "#/notifications/definitions"; +import type { NotificationSendInput, NotificationTemplateSendInput } from "#/notifications/notifications"; + +import requestClient from "@/api/request"; + +/** + * 获取可用通知列表 + * @returns {Promise>} 可用通知列表 + */ +export function getAssignableNotifiersApi(): Promise> { + return requestClient.get>("/api/notifications/assignables"); +} +/** + * 获取可用通知模板列表 + * @returns {Promise>} 可用通知模板列表 + */ +export function getAssignableTemplatesApi(): Promise> { + return requestClient.get>("/api/notifications/assignable-templates", { + method: "GET", + }); +} +/** + * 发送通知 + * @param input 参数 + * @returns {Promise} + */ +export function sendNotiferApi(input: NotificationSendInput): Promise { + return requestClient.post("/api/notifications/send", input); +} +/** + * 发送模板通知 + * @param input 参数 + * @returns {Promise} + */ +export function sendTemplateNotiferApi(input: NotificationTemplateSendInput): Promise { + return requestClient.post("/api/notifications/send/template", input); +} diff --git a/apps/react-admin/src/api/management/permissions/definitions.ts b/apps/react-admin/src/api/management/permissions/definitions.ts new file mode 100644 index 000000000..4abfbf3c6 --- /dev/null +++ b/apps/react-admin/src/api/management/permissions/definitions.ts @@ -0,0 +1,57 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { + PermissionDefinitionCreateDto, + PermissionDefinitionDto, + PermissionDefinitionGetListInput, + PermissionDefinitionUpdateDto, +} from "#/management/permissions/definitions"; + +import requestClient from "../../request"; + +/** + * 删除权限定义 + * @param name 权限名称 + */ +export function deleteApi(name: string): Promise { + return requestClient.delete(`/api/permission-management/definitions/${name}`); +} + +/** + * 查询权限定义 + * @param name 权限名称 + * @returns 权限定义数据传输对象 + */ +export function getApi(name: string): Promise { + return requestClient.get(`/api/permission-management/definitions/${name}`); +} + +/** + * 查询权限定义列表 + * @param input 权限过滤条件 + * @returns 权限定义数据传输对象列表 + */ +export function getListApi(input?: PermissionDefinitionGetListInput): Promise> { + return requestClient.get>("/api/permission-management/definitions", { + params: input, + }); +} + +/** + * 创建权限定义 + * @param input 权限定义参数 + * @returns 权限定义数据传输对象 + */ +export function createApi(input: PermissionDefinitionCreateDto): Promise { + return requestClient.post("/api/permission-management/definitions", input); +} + +/** + * 更新权限定义 + * @param name 权限名称 + * @param input 权限定义参数 + * @returns 权限定义数据传输对象 + */ +export function updateApi(name: string, input: PermissionDefinitionUpdateDto): Promise { + return requestClient.put(`/api/permission-management/definitions/${name}`, input); +} diff --git a/apps/react-admin/src/api/management/permissions/groups.ts b/apps/react-admin/src/api/management/permissions/groups.ts new file mode 100644 index 000000000..fe062fff3 --- /dev/null +++ b/apps/react-admin/src/api/management/permissions/groups.ts @@ -0,0 +1,68 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { + PermissionGroupDefinitionCreateDto, + PermissionGroupDefinitionDto, + PermissionGroupDefinitionGetListInput, + PermissionGroupDefinitionUpdateDto, +} from "#/management/permissions/groups"; + +import requestClient from "../../request"; + +/** + * 删除权限定义 + * @param name 权限名称 + */ +export function deleteApi(name: string): Promise { + return requestClient.delete(`/api/permission-management/definitions/groups/${name}`); +} + +/** + * 查询权限定义 + * @param name 权限名称 + * @returns 权限定义数据传输对象 + */ +export function getApi(name: string): Promise { + return requestClient.get(`/api/permission-management/definitions/groups/${name}`); +} + +/** + * 查询权限定义列表 + * @param input 权限过滤条件 + * @returns 权限定义数据传输对象列表 + */ +export function getListApi( + input?: PermissionGroupDefinitionGetListInput, +): Promise> { + return requestClient.get>( + "/api/permission-management/definitions/groups", + { + params: input, + }, + ); +} + +/** + * 创建权限定义 + * @param input 权限定义参数 + * @returns 权限定义数据传输对象 + */ +export function createApi(input: PermissionGroupDefinitionCreateDto): Promise { + return requestClient.post("/api/permission-management/definitions/groups", input); +} + +/** + * 更新权限定义 + * @param name 权限名称 + * @param input 权限定义参数 + * @returns 权限定义数据传输对象 + */ +export function updateApi( + name: string, + input: PermissionGroupDefinitionUpdateDto, +): Promise { + return requestClient.put( + `/api/permission-management/definitions/groups/${name}`, + input, + ); +} diff --git a/apps/react-admin/src/api/management/permissions/permissions.ts b/apps/react-admin/src/api/management/permissions/permissions.ts new file mode 100644 index 000000000..5425039b6 --- /dev/null +++ b/apps/react-admin/src/api/management/permissions/permissions.ts @@ -0,0 +1,25 @@ +import type { PermissionProvider, PermissionResultDto, PermissionsUpdateDto } from "#/management/permissions"; + +import requestClient from "../../request"; + +/** + * 查询权限 + * @param provider + * @returns 权限实体数据传输对象 + */ +export function getApi(provider: PermissionProvider): Promise { + return requestClient.get("/api/permission-management/permissions", { + params: provider, + }); +} + +/** + * 更新权限 + * @param provider + * @param input + */ +export function updateApi(provider: PermissionProvider, input: PermissionsUpdateDto): Promise { + return requestClient.put("/api/permission-management/permissions", input, { + params: provider, + }); +} diff --git a/apps/react-admin/src/api/management/settings/definitions.ts b/apps/react-admin/src/api/management/settings/definitions.ts new file mode 100644 index 000000000..f48262c6a --- /dev/null +++ b/apps/react-admin/src/api/management/settings/definitions.ts @@ -0,0 +1,56 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { + SettingDefinitionCreateDto, + SettingDefinitionDto, + SettingDefinitionGetListInput, + SettingDefinitionUpdateDto, +} from "#/management/settings/definitions"; +import requestClient from "@/api/request"; + +/** + * 删除设置定义 + * @param name 设置名称 + */ +export function deleteApi(name: string): Promise { + return requestClient.delete(`/api/setting-management/settings/definitions/${name}`); +} + +/** + * 查询设置定义 + * @param name 设置名称 + * @returns 设置定义数据传输对象 + */ +export function getApi(name: string): Promise { + return requestClient.get(`/api/setting-management/settings/definitions/${name}`); +} + +/** + * 查询设置定义列表 + * @param input 设置过滤条件 + * @returns 设置定义数据传输对象列表 + */ +export function getListApi(input?: SettingDefinitionGetListInput): Promise> { + return requestClient.get>("/api/setting-management/settings/definitions", { + params: input, + }); +} + +/** + * 创建设置定义 + * @param input 设置定义参数 + * @returns 设置定义数据传输对象 + */ +export function createApi(input: SettingDefinitionCreateDto): Promise { + return requestClient.post("/api/setting-management/settings/definitions", input); +} + +/** + * 更新设置定义 + * @param name 设置名称 + * @param input 设置定义参数 + * @returns 设置定义数据传输对象 + */ +export function updateApi(name: string, input: SettingDefinitionUpdateDto): Promise { + return requestClient.put(`/api/setting-management/settings/definitions/${name}`, input); +} diff --git a/apps/react-admin/src/api/management/settings/settings.ts b/apps/react-admin/src/api/management/settings/settings.ts new file mode 100644 index 000000000..399b70314 --- /dev/null +++ b/apps/react-admin/src/api/management/settings/settings.ts @@ -0,0 +1,62 @@ +import type { ListResultDto } from "#/abp-core"; + +import type { SettingGroup, SettingsUpdateInput } from "#/management/settings"; + +import requestClient from "@/api/request"; + +/** + * 获取全局设置 + * @returns 设置数据传输对象列表 + */ +export function getGlobalSettingsApi(): Promise> { + return requestClient.get>("/api/setting-management/settings/by-global"); +} + +/** + * 设置全局设置 + * @returns 设置数据传输对象列表 + */ +export function setGlobalSettingsApi(input: SettingsUpdateInput): Promise { + return requestClient.put("/api/setting-management/settings/change-global", input); +} + +/** + * 获取租户设置 + * @returns 设置数据传输对象列表 + */ +export function getTenantSettingsApi(): Promise> { + return requestClient.get>("api/setting-management/settings/by-current-tenant"); +} + +/** + * 设置租户设置 + * @returns 设置数据传输对象列表 + */ +export function setTenantSettingsApi(input: SettingsUpdateInput): Promise { + return requestClient.put("/api/setting-management/settings/change-current-tenant", input); +} +/** + * 获取用户设置 + * @returns 设置数据传输对象列表 + */ +export function getUserSettingsApi(): Promise> { + return requestClient.get>("/api/setting-management/settings/by-current-user"); +} + +/** + * 设置用户设置 + * @returns 设置数据传输对象列表 + */ +export function setUserSettingsApi(input: SettingsUpdateInput): Promise { + return requestClient.put("/api/setting-management/settings/change-current-user", input); +} + +/** + * 发送测试邮件 + * @param emailAddress 邮件接收方地址 + */ +export const sendTestEmailApi = (emailAddress: string) => { + return requestClient.post("/api/setting-management/settings/send-test-email", { + emailAddress, + }); +}; diff --git a/apps/react-admin/src/api/openiddict/applications.ts b/apps/react-admin/src/api/openiddict/applications.ts new file mode 100644 index 000000000..1b4828ecf --- /dev/null +++ b/apps/react-admin/src/api/openiddict/applications.ts @@ -0,0 +1,58 @@ +import type { PagedResultDto } from "#/abp-core"; +import type { + OpenIddictApplicationCreateDto, + OpenIddictApplicationDto, + OpenIddictApplicationGetListInput, + OpenIddictApplicationUpdateDto, +} from "#/openiddict/applications"; + +import requestClient from "../request"; + +/** + * 创建应用 + * @param input 参数 + * @returns 应用实体数据传输对象 + */ +export function createApi(input: OpenIddictApplicationCreateDto): Promise { + return requestClient.post("/api/openiddict/applications", input); +} + +/** + * 删除应用 + * @param id 应用id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/openiddict/applications/${id}`); +} + +/** + * 查询应用 + * @param id 应用id + * @returns 应用实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/openiddict/applications/${id}`); +} + +/** + * 更新应用 + * @param id 应用id + * @param input 更新参数 + * @returns 应用实体数据传输对象 + */ +export function updateApi(id: string, input: OpenIddictApplicationUpdateDto): Promise { + return requestClient.put(`/api/openiddict/applications/${id}`, input); +} + +/** + * 查询应用分页列表 + * @param input 过滤参数 + * @returns 应用实体数据传输对象分页列表 + */ +export function getPagedListApi( + input?: OpenIddictApplicationGetListInput, +): Promise> { + return requestClient.get>("/api/openiddict/applications", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/openiddict/authorizations.ts b/apps/react-admin/src/api/openiddict/authorizations.ts new file mode 100644 index 000000000..737aa891b --- /dev/null +++ b/apps/react-admin/src/api/openiddict/authorizations.ts @@ -0,0 +1,34 @@ +import type { PagedResultDto } from "#/abp-core"; +import type { OpenIddictAuthorizationDto, OpenIddictAuthorizationGetListInput } from "#/openiddict/authorizations"; + +import requestClient from "../request"; + +/** + * 删除授权 + * @param id 授权id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/openiddict/authorizations/${id}`); +} + +/** + * 查询授权 + * @param id 授权id + * @returns 授权实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/openiddict/authorizations/${id}`); +} + +/** + * 查询授权分页列表 + * @param input 过滤参数 + * @returns 授权实体数据传输对象分页列表 + */ +export function getPagedListApi( + input?: OpenIddictAuthorizationGetListInput, +): Promise> { + return requestClient.get>("/api/openiddict/authorizations", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/openiddict/open-id.ts b/apps/react-admin/src/api/openiddict/open-id.ts new file mode 100644 index 000000000..6f03b45b7 --- /dev/null +++ b/apps/react-admin/src/api/openiddict/open-id.ts @@ -0,0 +1,11 @@ +import type { OpenIdConfiguration } from "#/abp-core/openid"; + +import requestClient from "../request"; + +/** + * openid发现端点 + * @returns OpenId配置数据 + */ +export function discoveryApi(): Promise { + return requestClient.get("/.well-known/openid-configuration"); +} diff --git a/apps/react-admin/src/api/openiddict/scopes.ts b/apps/react-admin/src/api/openiddict/scopes.ts new file mode 100644 index 000000000..6239428f7 --- /dev/null +++ b/apps/react-admin/src/api/openiddict/scopes.ts @@ -0,0 +1,56 @@ +import type { PagedResultDto } from "#/abp-core"; +import type { + OpenIddictScopeCreateDto, + OpenIddictScopeDto, + OpenIddictScopeGetListInput, + OpenIddictScopeUpdateDto, +} from "#/openiddict/scopes"; + +import requestClient from "../request"; + +/** + * 创建范围 + * @param input 参数 + * @returns 范围实体数据传输对象 + */ +export function createApi(input: OpenIddictScopeCreateDto): Promise { + return requestClient.post("/api/openiddict/scopes", input); +} + +/** + * 删除范围 + * @param id 范围id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/openiddict/scopes/${id}`); +} + +/** + * 获取范围 + * @param id 范围id + * @returns 范围实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/openiddict/scopes/${id}`); +} + +/** + * 更新范围 + * @param id 范围id + * @param input 更新参数 + * @returns 范围实体数据传输对象 + */ +export function updateApi(id: string, input: OpenIddictScopeUpdateDto): Promise { + return requestClient.put(`/api/openiddict/scopes/${id}`, input); +} + +/** + * 获取范围分页列表 + * @param input 过滤参数 + * @returns 范围实体数据传输对象分页列表 + */ +export function getPagedListApi(input?: OpenIddictScopeGetListInput): Promise> { + return requestClient.get>("/api/openiddict/scopes", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/openiddict/tokens.ts b/apps/react-admin/src/api/openiddict/tokens.ts new file mode 100644 index 000000000..71dd5af84 --- /dev/null +++ b/apps/react-admin/src/api/openiddict/tokens.ts @@ -0,0 +1,31 @@ +import type { PagedResultDto } from "#/abp-core"; +import type { OpenIddictTokenDto, OpenIddictTokenGetListInput } from "#/openiddict/tokens"; +import requestClient from "../request"; + +/** + * 删除令牌 + * @param id 令牌id + */ +export function deleteApi(id: string): Promise { + return requestClient.delete(`/api/openiddict/tokens/${id}`); +} + +/** + * 获取令牌 + * @param id 令牌id + * @returns 令牌实体数据传输对象 + */ +export function getApi(id: string): Promise { + return requestClient.get(`/api/openiddict/tokens/${id}`); +} + +/** + * 获取令牌分页列表 + * @param input 过滤参数 + * @returns 令牌实体数据传输对象分页列表 + */ +export function getPagedListApi(input?: OpenIddictTokenGetListInput): Promise> { + return requestClient.get>("/api/openiddict/tokens", { + params: input, + }); +} diff --git a/apps/react-admin/src/api/request.ts b/apps/react-admin/src/api/request.ts new file mode 100644 index 000000000..2e3fb250f --- /dev/null +++ b/apps/react-admin/src/api/request.ts @@ -0,0 +1,127 @@ +import { authenticateResponseInterceptor, errorMessageResponseInterceptor, RequestClient } from "@/request-client"; +import useLocaleStore from "@/store/localeI18nStore"; +import useUserStore from "@/store/userStore"; +import userStore from "@/store/userStore"; +import { mapLocaleToAbpLanguageFormat } from "@/utils"; +import { toast } from "sonner"; +import { refreshToken } from "./account/token"; +import { wrapperResult } from "@/utils/abp/request"; +import { handleOAuthError } from "@/utils/abp/handleOAuthError"; + +const requestClient = new RequestClient({ + baseURL: import.meta.env.VITE_APP_BASE_API, +}); + +/** + * 重新认证逻辑 + */ +async function doReAuthenticate() { + console.warn("Access token or refresh token is invalid or expired. "); + //直接登出 + userStore.getState().actions.clearUserInfoAndToken(); +} + +/** + * 刷新token逻辑 + */ +async function doRefreshToken() { + console.debug("try -> Refresh token"); + + const { userToken } = useUserStore.getState(); + if (!userToken.refreshToken) { + console.warn("No refresh token available."); + return ""; + } + + try { + const res = await refreshToken({ refreshToken: userToken.refreshToken }); + + const { tokenType, accessToken, refreshToken: newRefreshToken } = res; + + if (accessToken) { + // 更新 userStore,保存新 token + useUserStore.getState().actions.setUserToken({ + accessToken: `${tokenType} ${accessToken}`, + refreshToken: newRefreshToken, + }); + console.debug("Token refreshed successfully."); + return `${tokenType} ${accessToken}`; // 返回新 token 供拦截器使用 + } + + console.error("Failed to refresh token: No access token returned."); + return ""; + } catch (error) { + console.error("Error refreshing token:", error); + return ""; // 返回空字符串,触发重登录逻辑 + } +} + +function formatToken(token: null | string) { + return token ? token : null; //有个tokenType的获取值 +} + +// 请求头处理 +requestClient.addRequestInterceptor({ + fulfilled: async (config) => { + const { userToken } = useUserStore.getState(); + if (userToken.accessToken) { + config.headers.Authorization = `${userToken.accessToken}`; + } + const { locale } = useLocaleStore.getState(); + config.headers["Accept-Language"] = mapLocaleToAbpLanguageFormat(locale); + config.headers["X-Request-From"] = "slash-admin"; + return config; + }, +}); + +// response数据解构 +requestClient.addResponseInterceptor({ + fulfilled: (response) => { + const { data, status } = response; + const { hasWrapResult, getData } = wrapperResult(response); + + if (hasWrapResult()) { + return getData(); + } + + if (status >= 200 && status < 400) { + return data; + } + + throw Object.assign({}, response, { response }); + }, +}); + +// token过期的处理 +requestClient.addResponseInterceptor( + authenticateResponseInterceptor({ + client: requestClient, + doReAuthenticate, + doRefreshToken, + enableRefreshToken: true, + formatToken, + }), +); + +// 通用的错误处理,如果没有进入上面的错误处理逻辑,就会进入这里 +requestClient.addResponseInterceptor( + errorMessageResponseInterceptor((msg: string, error) => { + // 这里可以根据业务进行定制,你可以拿到 error 内的信息进行定制化处理,根据不同的 code 做不同的提示,而不是直接使用 message.error 提示 msg + // 当前mock接口返回的错误字段是 error 或者 message + const responseData = error?.response?.data ?? {}; + if (responseData?.error_description) { + const { formatError } = handleOAuthError(); + toast.error(formatError(responseData) || msg, { + position: "top-center", + }); + return; + } + const errorMessage = responseData?.error ?? responseData?.message ?? ""; + // 如果没有错误信息,则会根据状态码进行提示 + toast.error(errorMessage || msg, { + position: "top-center", + }); + }), +); + +export default requestClient; diff --git a/apps/react-admin/src/api/services/demoService.ts b/apps/react-admin/src/api/services/demoService.ts new file mode 100644 index 000000000..857ba1a50 --- /dev/null +++ b/apps/react-admin/src/api/services/demoService.ts @@ -0,0 +1,11 @@ +import apiClient from "../apiClient"; + +export enum DemoApi { + TOKEN_EXPIRED = "/user/tokenExpired", +} + +const mockTokenExpired = () => apiClient.post({ url: DemoApi.TOKEN_EXPIRED }); + +export default { + mockTokenExpired, +}; diff --git a/apps/react-admin/src/api/services/orgService.ts b/apps/react-admin/src/api/services/orgService.ts new file mode 100644 index 000000000..b33cd49a4 --- /dev/null +++ b/apps/react-admin/src/api/services/orgService.ts @@ -0,0 +1,13 @@ +import apiClient from "../apiClient"; + +import type { Organization } from "#/entity"; + +export enum OrgApi { + Org = "/org", +} + +const getOrgList = () => apiClient.get({ url: OrgApi.Org }); + +export default { + getOrgList, +}; diff --git a/apps/react-admin/src/api/services/userService.ts b/apps/react-admin/src/api/services/userService.ts new file mode 100644 index 000000000..ad3022b71 --- /dev/null +++ b/apps/react-admin/src/api/services/userService.ts @@ -0,0 +1,33 @@ +import apiClient from "../apiClient"; + +import type { UserInfo, UserToken } from "#/entity"; + +export interface SignInReq { + username: string; + password: string; +} + +export interface SignUpReq extends SignInReq { + email: string; +} +export type SignInRes = UserToken & { user: UserInfo }; + +export enum UserApi { + SignIn = "/auth/signin", + SignUp = "/auth/signup", + Logout = "/auth/logout", + Refresh = "/auth/refresh", + User = "/user", +} + +const signin = (data: SignInReq) => apiClient.post({ url: UserApi.SignIn, data }); +const signup = (data: SignUpReq) => apiClient.post({ url: UserApi.SignUp, data }); +const logout = () => apiClient.get({ url: UserApi.Logout }); +const findById = (id: string) => apiClient.get({ url: `${UserApi.User}/${id}` }); + +export default { + signin, + signup, + findById, + logout, +}; diff --git a/apps/react-admin/src/assets/icons/ic-analysis.svg b/apps/react-admin/src/assets/icons/ic-analysis.svg new file mode 100644 index 000000000..130880561 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-analysis.svg @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-blog.svg b/apps/react-admin/src/assets/icons/ic-blog.svg new file mode 100644 index 000000000..eb74d960d --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-blog.svg @@ -0,0 +1,7 @@ + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-clear.svg b/apps/react-admin/src/assets/icons/ic-clear.svg new file mode 100644 index 000000000..bc535b32d --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-clear.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-dashboard.svg b/apps/react-admin/src/assets/icons/ic-dashboard.svg new file mode 100644 index 000000000..6cbedde97 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-dashboard.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-left-arrow.svg b/apps/react-admin/src/assets/icons/ic-left-arrow.svg new file mode 100644 index 000000000..7301e2c0e --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-left-arrow.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-locale_en_US.svg b/apps/react-admin/src/assets/icons/ic-locale_en_US.svg new file mode 100644 index 000000000..f3980e2b7 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-locale_en_US.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-locale_zh_CN.svg b/apps/react-admin/src/assets/icons/ic-locale_zh_CN.svg new file mode 100644 index 000000000..b9aa7a2e4 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-locale_zh_CN.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-logo.svg b/apps/react-admin/src/assets/icons/ic-logo.svg new file mode 100644 index 000000000..63f85c360 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-logo.svg @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-management.svg b/apps/react-admin/src/assets/icons/ic-management.svg new file mode 100644 index 000000000..281dec2e5 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-management.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic-markdown.svg b/apps/react-admin/src/assets/icons/ic-markdown.svg new file mode 100644 index 000000000..a9f882bcd --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-markdown.svg @@ -0,0 +1,40 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-menu.svg b/apps/react-admin/src/assets/icons/ic-menu.svg new file mode 100644 index 000000000..c9d8d36b0 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-menu.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-menulevel.svg b/apps/react-admin/src/assets/icons/ic-menulevel.svg new file mode 100644 index 000000000..e557e9498 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-menulevel.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-reset-password.svg b/apps/react-admin/src/assets/icons/ic-reset-password.svg new file mode 100644 index 000000000..cf9e8c3d8 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-reset-password.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-right-arrow.svg b/apps/react-admin/src/assets/icons/ic-right-arrow.svg new file mode 100644 index 000000000..9400f219e --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-right-arrow.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-search.svg b/apps/react-admin/src/assets/icons/ic-search.svg new file mode 100644 index 000000000..d06a45119 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-search.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-setting.svg b/apps/react-admin/src/assets/icons/ic-setting.svg new file mode 100644 index 000000000..48468ac84 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-setting.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic-settings-exit-fullscreen.svg b/apps/react-admin/src/assets/icons/ic-settings-exit-fullscreen.svg new file mode 100644 index 000000000..46453e9d9 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-settings-exit-fullscreen.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-settings-fullscreen.svg b/apps/react-admin/src/assets/icons/ic-settings-fullscreen.svg new file mode 100644 index 000000000..a13fcc8ca --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-settings-fullscreen.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-settings-mode-moon.svg b/apps/react-admin/src/assets/icons/ic-settings-mode-moon.svg new file mode 100644 index 000000000..be816934f --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-settings-mode-moon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic-settings-mode-sun.svg b/apps/react-admin/src/assets/icons/ic-settings-mode-sun.svg new file mode 100644 index 000000000..aeaeeac02 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-settings-mode-sun.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic-user.svg b/apps/react-admin/src/assets/icons/ic-user.svg new file mode 100644 index 000000000..141aeba97 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-user.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic-workbench.svg b/apps/react-admin/src/assets/icons/ic-workbench.svg new file mode 100644 index 000000000..6ea1c6dea --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic-workbench.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic_blank.svg b/apps/react-admin/src/assets/icons/ic_blank.svg new file mode 100644 index 000000000..d187ec296 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_blank.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic_chat.svg b/apps/react-admin/src/assets/icons/ic_chat.svg new file mode 100644 index 000000000..d8b905cc6 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_chat.svg @@ -0,0 +1,28 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_decline.svg b/apps/react-admin/src/assets/icons/ic_decline.svg new file mode 100644 index 000000000..0931d3895 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_decline.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/icons/ic_delivery.svg b/apps/react-admin/src/assets/icons/ic_delivery.svg new file mode 100644 index 000000000..e0b077c7d --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_delivery.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_disabled.svg b/apps/react-admin/src/assets/icons/ic_disabled.svg new file mode 100644 index 000000000..216410112 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_disabled.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic_external.svg b/apps/react-admin/src/assets/icons/ic_external.svg new file mode 100644 index 000000000..d38340e5e --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_external.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file.svg b/apps/react-admin/src/assets/icons/ic_file.svg new file mode 100644 index 000000000..f5295c2e2 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file.svg @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_ai.svg b/apps/react-admin/src/assets/icons/ic_file_ai.svg new file mode 100644 index 000000000..4d8098a87 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_ai.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_audio.svg b/apps/react-admin/src/assets/icons/ic_file_audio.svg new file mode 100644 index 000000000..329f232a7 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_audio.svg @@ -0,0 +1,24 @@ + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_excel.svg b/apps/react-admin/src/assets/icons/ic_file_excel.svg new file mode 100644 index 000000000..cb80eb2bf --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_excel.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_img.svg b/apps/react-admin/src/assets/icons/ic_file_img.svg new file mode 100644 index 000000000..a95194a99 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_img.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_pdf.svg b/apps/react-admin/src/assets/icons/ic_file_pdf.svg new file mode 100644 index 000000000..8ed54c947 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_pdf.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_ppt.svg b/apps/react-admin/src/assets/icons/ic_file_ppt.svg new file mode 100644 index 000000000..f2d7f144a --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_ppt.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_psd.svg b/apps/react-admin/src/assets/icons/ic_file_psd.svg new file mode 100644 index 000000000..7ecbee0c2 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_psd.svg @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_txt.svg b/apps/react-admin/src/assets/icons/ic_file_txt.svg new file mode 100644 index 000000000..1d34c3481 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_txt.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_video.svg b/apps/react-admin/src/assets/icons/ic_file_video.svg new file mode 100644 index 000000000..fb6eca6c2 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_video.svg @@ -0,0 +1,20 @@ + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_word.svg b/apps/react-admin/src/assets/icons/ic_file_word.svg new file mode 100644 index 000000000..b112fe589 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_word.svg @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_file_zip.svg b/apps/react-admin/src/assets/icons/ic_file_zip.svg new file mode 100644 index 000000000..f34001e8b --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_file_zip.svg @@ -0,0 +1,27 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_folder.svg b/apps/react-admin/src/assets/icons/ic_folder.svg new file mode 100644 index 000000000..01f6671ed --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_folder.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_label.svg b/apps/react-admin/src/assets/icons/ic_label.svg new file mode 100644 index 000000000..933e6357b --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_label.svg @@ -0,0 +1,4 @@ + + + + diff --git a/apps/react-admin/src/assets/icons/ic_mail.svg b/apps/react-admin/src/assets/icons/ic_mail.svg new file mode 100644 index 000000000..f9561c459 --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_mail.svg @@ -0,0 +1,15 @@ + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_order.svg b/apps/react-admin/src/assets/icons/ic_order.svg new file mode 100644 index 000000000..cc8dbb75a --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_order.svg @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/apps/react-admin/src/assets/icons/ic_rise.svg b/apps/react-admin/src/assets/icons/ic_rise.svg new file mode 100644 index 000000000..93689126d --- /dev/null +++ b/apps/react-admin/src/assets/icons/ic_rise.svg @@ -0,0 +1 @@ + diff --git a/apps/react-admin/src/assets/images/background/cyan-blur.png b/apps/react-admin/src/assets/images/background/cyan-blur.png new file mode 100644 index 000000000..b5dbc95da Binary files /dev/null and b/apps/react-admin/src/assets/images/background/cyan-blur.png differ diff --git a/apps/react-admin/src/assets/images/background/dashboard.png b/apps/react-admin/src/assets/images/background/dashboard.png new file mode 100644 index 000000000..26a2e8896 Binary files /dev/null and b/apps/react-admin/src/assets/images/background/dashboard.png differ diff --git a/apps/react-admin/src/assets/images/background/overlay_2.jpg b/apps/react-admin/src/assets/images/background/overlay_2.jpg new file mode 100644 index 000000000..119d428b8 Binary files /dev/null and b/apps/react-admin/src/assets/images/background/overlay_2.jpg differ diff --git a/apps/react-admin/src/assets/images/background/red-blur.png b/apps/react-admin/src/assets/images/background/red-blur.png new file mode 100644 index 000000000..a0df012ff Binary files /dev/null and b/apps/react-admin/src/assets/images/background/red-blur.png differ diff --git a/apps/react-admin/src/assets/images/characters/character_3.png b/apps/react-admin/src/assets/images/characters/character_3.png new file mode 100644 index 000000000..2d639ccde Binary files /dev/null and b/apps/react-admin/src/assets/images/characters/character_3.png differ diff --git a/apps/react-admin/src/assets/images/characters/character_4.png b/apps/react-admin/src/assets/images/characters/character_4.png new file mode 100644 index 000000000..0ce49ffe4 Binary files /dev/null and b/apps/react-admin/src/assets/images/characters/character_4.png differ diff --git a/apps/react-admin/src/assets/images/characters/character_5.png b/apps/react-admin/src/assets/images/characters/character_5.png new file mode 100644 index 000000000..b8fbb44fc Binary files /dev/null and b/apps/react-admin/src/assets/images/characters/character_5.png differ diff --git a/apps/react-admin/src/assets/images/characters/character_6.png b/apps/react-admin/src/assets/images/characters/character_6.png new file mode 100644 index 000000000..f59a84417 Binary files /dev/null and b/apps/react-admin/src/assets/images/characters/character_6.png differ diff --git a/apps/react-admin/src/assets/images/characters/character_8.png b/apps/react-admin/src/assets/images/characters/character_8.png new file mode 100644 index 000000000..44f170875 Binary files /dev/null and b/apps/react-admin/src/assets/images/characters/character_8.png differ diff --git a/apps/react-admin/src/assets/images/cover/cover_3.jpg b/apps/react-admin/src/assets/images/cover/cover_3.jpg new file mode 100644 index 000000000..8390e518e Binary files /dev/null and b/apps/react-admin/src/assets/images/cover/cover_3.jpg differ diff --git a/apps/react-admin/src/assets/images/cover/cover_4.jpg b/apps/react-admin/src/assets/images/cover/cover_4.jpg new file mode 100644 index 000000000..c68f1581a Binary files /dev/null and b/apps/react-admin/src/assets/images/cover/cover_4.jpg differ diff --git a/apps/react-admin/src/assets/images/cover/profile_banner.jpeg b/apps/react-admin/src/assets/images/cover/profile_banner.jpeg new file mode 100644 index 000000000..4a0a1c7a4 Binary files /dev/null and b/apps/react-admin/src/assets/images/cover/profile_banner.jpeg differ diff --git a/apps/react-admin/src/assets/images/glass/ic_glass_bag.png b/apps/react-admin/src/assets/images/glass/ic_glass_bag.png new file mode 100644 index 000000000..41cb3c506 Binary files /dev/null and b/apps/react-admin/src/assets/images/glass/ic_glass_bag.png differ diff --git a/apps/react-admin/src/assets/images/glass/ic_glass_buy.png b/apps/react-admin/src/assets/images/glass/ic_glass_buy.png new file mode 100644 index 000000000..065ffcde1 Binary files /dev/null and b/apps/react-admin/src/assets/images/glass/ic_glass_buy.png differ diff --git a/apps/react-admin/src/assets/images/glass/ic_glass_message.png b/apps/react-admin/src/assets/images/glass/ic_glass_message.png new file mode 100644 index 000000000..10b6c9591 Binary files /dev/null and b/apps/react-admin/src/assets/images/glass/ic_glass_message.png differ diff --git a/apps/react-admin/src/assets/images/glass/ic_glass_users.png b/apps/react-admin/src/assets/images/glass/ic_glass_users.png new file mode 100644 index 000000000..415f0c9be Binary files /dev/null and b/apps/react-admin/src/assets/images/glass/ic_glass_users.png differ diff --git a/apps/react-admin/src/assets/images/logo.png b/apps/react-admin/src/assets/images/logo.png new file mode 100644 index 000000000..b0eeef4ab Binary files /dev/null and b/apps/react-admin/src/assets/images/logo.png differ diff --git a/apps/react-admin/src/components/abp/account/authenticator-settings.tsx b/apps/react-admin/src/components/abp/account/authenticator-settings.tsx new file mode 100644 index 000000000..282ea9d17 --- /dev/null +++ b/apps/react-admin/src/components/abp/account/authenticator-settings.tsx @@ -0,0 +1,73 @@ +import { Button, Card, List, Skeleton, Modal } from "antd"; +import { useTranslation } from "react-i18next"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import { getAuthenticatorApi, resetAuthenticatorApi } from "@/api/account/profile"; +import AuthenticatorSteps from "./authenticator-steps"; +import { toast } from "sonner"; + +const AuthenticatorSettings: React.FC = () => { + const { t: $t } = useTranslation(); + const [modal, contextHolder] = Modal.useModal(); + const queryClient = useQueryClient(); + + const { data: authenticator, isLoading } = useQuery({ + queryKey: ["authenticator"], + queryFn: getAuthenticatorApi, + }); + + const { mutateAsync: resetAuthenticator } = useMutation({ + mutationFn: resetAuthenticatorApi, + onSuccess: () => { + queryClient.invalidateQueries({ queryKey: ["authenticator"] }); + toast.success($t("AbpAccount.YourAuthenticatorIsSuccessfullyReset")); + }, + }); + + const handleReset = () => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpAccount.ResetAuthenticatorWarning"), + centered: true, + onOk: () => resetAuthenticator(), + }); + }; + + if (isLoading) { + return ( + + + + ); + } + + return ( + <> + {contextHolder} + + {authenticator?.isAuthenticated === false ? ( + queryClient.invalidateQueries({ queryKey: ["authenticator"] })} + /> + ) : authenticator?.isAuthenticated === true ? ( + + + {$t("AbpAccount.ResetAuthenticator")} + + } + > + + + + ) : null} + + + ); +}; + +export default AuthenticatorSettings; diff --git a/apps/react-admin/src/components/abp/account/authenticator-steps.tsx b/apps/react-admin/src/components/abp/account/authenticator-steps.tsx new file mode 100644 index 000000000..22bdc8664 --- /dev/null +++ b/apps/react-admin/src/components/abp/account/authenticator-steps.tsx @@ -0,0 +1,177 @@ +import { useState } from "react"; +import { Card, Steps, Button, Form, Input, QRCode } from "antd"; +import { useTranslation } from "react-i18next"; + +import { verifyAuthenticatorCodeApi } from "@/api/account/profile"; +import { useMutation } from "@tanstack/react-query"; +import type { AuthenticatorDto } from "#/account/profile"; +import { useCopyToClipboard } from "@/hooks/event/use-copy-to-clipboard"; +import { toast } from "sonner"; + +interface Props { + authenticator: AuthenticatorDto; + onDone: () => void; +} + +const AuthenticatorSteps: React.FC = ({ authenticator, onDone }) => { + const { t: $t } = useTranslation(); + const { copyFn } = useCopyToClipboard(); + const [form] = Form.useForm(); + const [currentStep, setCurrentStep] = useState(0); + const [codeValidated, setCodeValidated] = useState(false); + const [recoveryCodes, setRecoveryCodes] = useState([]); + + const steps = [ + { title: $t("AbpAccount.Authenticator") }, + { title: $t("AbpAccount.ValidAuthenticator") }, + { title: $t("AbpAccount.RecoveryCode") }, + ]; + + const { mutateAsync: verifyCode, isPending: isLoading } = useMutation({ + mutationFn: verifyAuthenticatorCodeApi, + onSuccess: (data) => { + setRecoveryCodes(data.recoveryCodes); + setCodeValidated(true); + handleNextStep(); + }, + }); + + const handleCopy = async (text?: string) => { + if (!text) return; + await copyFn(text); + toast.success($t("AbpUi.CopiedToTheClipboard")); + }; + + const handleValidCode = async () => { + try { + const values = await form.validateFields(); + await verifyCode(values); + } catch (error) { + console.error("Validation failed:", error); + } + }; + + const handlePrevStep = () => setCurrentStep((prev) => prev - 1); + const handleNextStep = () => setCurrentStep((prev) => prev + 1); + + const renderStepContent = () => { + switch (currentStep) { + case 0: + return ( + + + {$t("AbpAccount.Authenticator")} + {$t("AbpAccount.AuthenticatorDesc")} + + } + /> +
+
+ +
+ +
+
+
+
+ handleCopy(authenticator.sharedKey)}> + {$t("AbpAccount.Authenticator:CopyToClipboard")} + + } + > +
+
{authenticator.sharedKey}
+
+
+
+
+
+ ); + + case 1: + return ( + + + {$t("AbpAccount.ValidAuthenticator")} + {$t("AbpAccount.ValidAuthenticatorDesc")} + + } + /> +
+
+
+ + + +
+
+
+ +
+
+
+ ); + + case 2: + return ( + + {$t("AbpAccount.RecoveryCode")} + {$t("AbpAccount.RecoveryCodeDesc")} + + } + extra={ + + } + > +
+
{recoveryCodes.slice(0, 5).join("\r\n")}
+
{recoveryCodes.slice(5).join("\r\n")}
+
+
+ ); + } + }; + + return ( + + + {renderStepContent()} +
+ {currentStep > 0 && !codeValidated && ( + + )} + {currentStep < 2 && ( + + )} + {currentStep === 2 && ( + + )} +
+
+ ); +}; + +export default AuthenticatorSteps; diff --git a/apps/react-admin/src/components/abp/account/basic-settings.tsx b/apps/react-admin/src/components/abp/account/basic-settings.tsx new file mode 100644 index 000000000..9b8ef1d8e --- /dev/null +++ b/apps/react-admin/src/components/abp/account/basic-settings.tsx @@ -0,0 +1,91 @@ +import { useEffect, useState } from "react"; +import { Card, Form, Input, Avatar, Upload, Button } from "antd"; +import { UploadOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import type { ProfileDto, UpdateProfileDto } from "#/account/profile"; +import type { UploadChangeParam, UploadProps } from "antd/es/upload"; +import { useUserInfo } from "@/store/userStore"; +import { faker } from "@faker-js/faker"; +import { useAbpSettings } from "@/hooks/abp/use-abp-settings"; + +interface Props { + profile: ProfileDto; + onSubmit: (profile: UpdateProfileDto) => void; +} + +const BasicSettings: React.FC = ({ profile, onSubmit }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + const { isTrue } = useAbpSettings(); + const userInfo = useUserInfo(); + + const [formModel, setFormModel] = useState({} as ProfileDto); + + useEffect(() => { + setFormModel({ ...profile }); + form.setFieldsValue(profile); + }, [profile]); + + const handleAvatarChange = (_param: UploadChangeParam) => { + // TODO: Wait for OSS module integration + console.warn("Waiting for OSS module integration..."); + }; + + const handleBeforeUpload: UploadProps["beforeUpload"] = () => { + console.warn("Waiting for OSS module integration..."); + return false; + }; + + const handleSubmit = () => { + onSubmit(formModel); + }; + + return ( + +
+
+
setFormModel(values)} + > + + + + + + + + + + + + + +
+ +
+
+
+
+
+
+

{$t("AbpUi.ProfilePicture")}

+ } /> + + + +
+
+
+
+ ); +}; + +export default BasicSettings; diff --git a/apps/react-admin/src/components/abp/account/bind-settings.tsx b/apps/react-admin/src/components/abp/account/bind-settings.tsx new file mode 100644 index 000000000..386345633 --- /dev/null +++ b/apps/react-admin/src/components/abp/account/bind-settings.tsx @@ -0,0 +1,14 @@ +import { Card, Empty } from "antd"; +import { useTranslation } from "react-i18next"; + +const BindSettings: React.FC = () => { + const { t: $t } = useTranslation(); + + return ( + + + + ); +}; + +export default BindSettings; diff --git a/apps/react-admin/src/components/abp/account/email-confirm-modal.tsx b/apps/react-admin/src/components/abp/account/email-confirm-modal.tsx new file mode 100644 index 000000000..9076852a4 --- /dev/null +++ b/apps/react-admin/src/components/abp/account/email-confirm-modal.tsx @@ -0,0 +1,68 @@ +import { useState } from "react"; +import { Modal, Form, Input } from "antd"; +import { useTranslation } from "react-i18next"; +import { useMutation } from "@tanstack/react-query"; +import { confirmEmailApi } from "@/api/account/profile"; +import { toast } from "sonner"; + +interface Props { + visible: boolean; + onSuccess: () => void; + onClose: () => void; + initialState: { + confirmToken: string; + email: string; + returnUrl?: string; + userId: string; + }; +} + +const EmailConfirmModal: React.FC = ({ visible, onClose, onSuccess, initialState }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + const [confirmLoading, setConfirmLoading] = useState(false); + + const { mutateAsync: confirmEmail } = useMutation({ + mutationFn: confirmEmailApi, + onSuccess: () => { + toast.success($t("AbpAccount.YourEmailIsSuccessfullyConfirm")); + onSuccess(); + onClose(); + if (initialState.returnUrl) { + window.location.href = initialState.returnUrl; + } + }, + onSettled: () => { + setConfirmLoading(false); + }, + }); + + const handleSubmit = async () => { + try { + setConfirmLoading(true); + await confirmEmail({ + confirmToken: decodeURIComponent(initialState.confirmToken), + }); + } catch (error) { + console.error("Email confirmation failed:", error); + } + }; + + return ( + +
+ + + +
+
+ ); +}; + +export default EmailConfirmModal; diff --git a/apps/react-admin/src/components/abp/account/notice-settings.tsx b/apps/react-admin/src/components/abp/account/notice-settings.tsx new file mode 100644 index 000000000..18e775431 --- /dev/null +++ b/apps/react-admin/src/components/abp/account/notice-settings.tsx @@ -0,0 +1,14 @@ +import { Card, Empty } from "antd"; +import { useTranslation } from "react-i18next"; + +const BindSettings: React.FC = () => { + const { t: $t } = useTranslation(); + + return ( + + + + ); +}; + +export default BindSettings; diff --git a/apps/react-admin/src/components/abp/account/security-settings.tsx b/apps/react-admin/src/components/abp/account/security-settings.tsx new file mode 100644 index 000000000..87076eb39 --- /dev/null +++ b/apps/react-admin/src/components/abp/account/security-settings.tsx @@ -0,0 +1,158 @@ +import { useState, useEffect } from "react"; +import { Card, List, Button, Tag, Switch } from "antd"; +import { useTranslation } from "react-i18next"; +import { useMutation, useQuery } from "@tanstack/react-query"; +import { getTwoFactorEnabledApi, changeTwoFactorEnabledApi, sendEmailConfirmLinkApi } from "@/api/account/profile"; +import type { UserInfo } from "#/account/user"; + +interface Props { + userInfo: UserInfo | null; + onChangePassword: () => void; + onChangePhoneNumber: () => void; +} + +const SecuritySettings: React.FC = ({ userInfo, onChangePassword, onChangePhoneNumber }) => { + const { t: $t } = useTranslation(); + const [loading, setLoading] = useState(false); + const [sendMailInterval, setSendMailInterval] = useState(0); + let timer: NodeJS.Timeout; + + // Get two factor status + const { data: twoFactor, refetch: refetchTwoFactor } = useQuery({ + queryKey: ["twoFactorEnabled"], + queryFn: getTwoFactorEnabledApi, + }); + + // Change two factor mutation + const { mutateAsync: changeTwoFactor } = useMutation({ + mutationFn: changeTwoFactorEnabledApi, + onMutate: () => setLoading(true), + onSettled: () => setLoading(false), + onError: () => refetchTwoFactor(), + onSuccess: () => refetchTwoFactor(), + }); + + // Send email confirmation mutation + const { mutateAsync: sendEmailConfirm } = useMutation({ + mutationFn: (email: string) => + sendEmailConfirmLinkApi({ + appName: "ReactAdmin", + email, + returnUrl: window.location.href, + }), + onSuccess: () => { + setSendMailInterval(60); + timer = setInterval(() => { + setSendMailInterval((prev) => { + if (prev <= 0) { + clearInterval(timer); + return 0; + } + return prev - 1; + }); + }, 1000); + }, + onError: () => setSendMailInterval(0), + }); + + useEffect(() => { + return () => { + if (timer) clearInterval(timer); + }; + }, []); + + const getSendMailTitle = () => { + if (sendMailInterval > 0) { + return `${sendMailInterval} s`; + } + return $t("AbpAccount.ClickToValidation"); + }; + + return ( + + + {/* Password */} + + {$t("AbpUi.Edit")} + + } + > + + + + {/* Phone Number */} + + {$t("AbpUi.Edit")} + + } + > + + {userInfo?.phoneNumber} + {!userInfo?.phoneNumber ? ( + {$t("abp.account.settings.security.unSet")} + ) : userInfo?.phoneNumberVerified ? ( + {$t("abp.account.settings.security.verified")} + ) : ( + {$t("abp.account.settings.security.unVerified")} + )} + + } + /> + + + {/* Email */} + 0} onClick={() => sendEmailConfirm(userInfo.email)}> + {getSendMailTitle()} + + ) + } + > + + {userInfo?.email} + {userInfo?.emailVerified ? ( + {$t("abp.account.settings.security.verified")} + ) : ( + {$t("abp.account.settings.security.unVerified")} + )} + + } + /> + + + {/* Two Factor Authentication */} + {twoFactor && ( + changeTwoFactor({ enabled: checked })} + /> + } + > + + + )} + + + ); +}; + +export default SecuritySettings; diff --git a/apps/react-admin/src/components/abp/account/session-settings.tsx b/apps/react-admin/src/components/abp/account/session-settings.tsx new file mode 100644 index 000000000..54956ffaf --- /dev/null +++ b/apps/react-admin/src/components/abp/account/session-settings.tsx @@ -0,0 +1,51 @@ +import { Card, Modal } from "antd"; +import { useTranslation } from "react-i18next"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import type { IdentitySessionDto } from "#/management/identity/sessions"; +import { getSessionsApi, revokeSessionApi } from "@/api/account/my-session"; +import { toast } from "sonner"; +import UserSessionTable from "@/pages/management/identity/sessions/user-session-table"; + +const SessionSettings: React.FC = () => { + const { t: $t } = useTranslation(); + const [modal, contextHolder] = Modal.useModal(); + const queryClient = useQueryClient(); + + // Fetch sessions + const { data: sessions = [] } = useQuery({ + queryKey: ["mySessions"], + queryFn: async () => { + const { items } = await getSessionsApi(); + return items; + }, + }); + + // Revoke session mutation + const { mutateAsync: revokeSession } = useMutation({ + mutationFn: revokeSessionApi, + onSuccess: () => { + queryClient.invalidateQueries({ queryKey: ["mySessions"] }); + toast.success($t("AbpIdentity.SuccessfullyRevoked")); + }, + }); + + const handleRevoke = (session: IdentitySessionDto) => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpIdentity.SessionWillBeRevokedMessage"), + centered: true, + onOk: () => revokeSession(session.sessionId), + }); + }; + + return ( + <> + {contextHolder} + + + + + ); +}; + +export default SessionSettings; diff --git a/apps/react-admin/src/components/abp/auditing/entity-change-drawer.tsx b/apps/react-admin/src/components/abp/auditing/entity-change-drawer.tsx new file mode 100644 index 000000000..6aa304400 --- /dev/null +++ b/apps/react-admin/src/components/abp/auditing/entity-change-drawer.tsx @@ -0,0 +1,36 @@ +import { getListWithUsernameApi } from "@/api/management/auditing/entity-changes"; +import { EntityChangeTable } from "./entity-change-table"; +import type { EntityChangeGetWithUsernameInput } from "#/management/auditing/entity-changes"; +import { Drawer } from "antd"; +import { useQuery } from "@tanstack/react-query"; +import { useTranslation } from "react-i18next"; + +interface EntityChangeDrawerProps { + open: boolean; + onClose: () => void; + input?: EntityChangeGetWithUsernameInput; + subject?: string; +} + +export const EntityChangeDrawer: React.FC = ({ open, onClose, input, subject }) => { + const { t } = useTranslation(); + + const { data: entityChanges = [] } = useQuery({ + queryKey: ["entityChanges", input], + queryFn: async () => { + if (!input) return []; + const { items } = await getListWithUsernameApi(input); + return items.map((item) => ({ + ...item.entityChange, + userName: item.userName, + })); + }, + enabled: open && !!input, + }); + + return ( + + + + ); +}; diff --git a/apps/react-admin/src/components/abp/auditing/entity-change-table.tsx b/apps/react-admin/src/components/abp/auditing/entity-change-table.tsx new file mode 100644 index 000000000..43f271565 --- /dev/null +++ b/apps/react-admin/src/components/abp/auditing/entity-change-table.tsx @@ -0,0 +1,140 @@ +import { formatToDateTime } from "@/utils/abp"; +import { useTranslation } from "react-i18next"; +import type { EntityChangeDto, PropertyChange, ChangeType } from "#/management/auditing/entity-changes"; +import { Tag, Table, Card } from "antd"; +import type { ColumnsType } from "antd/es/table"; +import { useState, useMemo } from "react"; +import { useAuditLogs } from "@/hooks/abp/auditing/use-audit-logs"; +import Scrollbar from "@/components/scrollbar"; + +interface EntityChangeTableProps { + data: EntityChangeDto[]; + showUserName?: boolean; +} + +export const EntityChangeTable: React.FC = ({ data, showUserName = false }) => { + const [pageSize, setPageSize] = useState(10); + const [current, setCurrent] = useState(1); + const { t } = useTranslation(); + const { getChangeTypeColor, getChangeTypeValue } = useAuditLogs(); + + const columns: ColumnsType = [ + showUserName && { + title: t("AbpAuditLogging.UserName"), + dataIndex: "userName", + align: "center", + width: 100, // 设置列宽 + }, + { + title: t("AbpAuditLogging.ChangeType"), + dataIndex: "changeType", + sorter: true, + align: "center", + width: 120, // 设置列宽 + render: (type: ChangeType) => {getChangeTypeValue(type)}, + }, + { + title: t("AbpAuditLogging.StartTime"), + dataIndex: "changeTime", + sorter: true, + width: 200, // 设置列宽 + render: (value: Date) => value && formatToDateTime(value), + }, + { + title: t("AbpAuditLogging.EntityTypeFullName"), + dataIndex: "entityTypeFullName", + ellipsis: true, + sorter: true, + width: 400, // 设置列宽 + }, + { + title: t("AbpAuditLogging.EntityId"), + dataIndex: "entityId", + sorter: true, + width: 312, // 设置列宽 + }, + { + title: t("AbpAuditLogging.TenantId"), + dataIndex: "entityTenantId", + sorter: true, + width: 312, // 设置列宽 + }, + ].filter(Boolean) as ColumnsType; + + const propertyColumns: ColumnsType = [ + { + title: t("AbpAuditLogging.PropertyName"), + dataIndex: "propertyName", + sorter: true, + width: 150, // 设置列宽 + }, + { + title: t("AbpAuditLogging.NewValue"), + dataIndex: "newValue", + sorter: true, + className: "font-medium text-success", + width: 250, // 设置列宽 + }, + { + title: t("AbpAuditLogging.OriginalValue"), + dataIndex: "originalValue", + sorter: true, + className: "font-medium text-error", + width: 250, // 设置列宽 + }, + { + title: t("AbpAuditLogging.PropertyTypeFullName"), + dataIndex: "propertyTypeFullName", + sorter: true, + width: 250, // 设置列宽 + }, + ]; + + const paginatedData = useMemo(() => { + const startIndex = (current - 1) * pageSize; + return data.slice(startIndex, startIndex + pageSize); + }, [data, current, pageSize]); + + return ( + + +
+
+ { + setCurrent(page); + setPageSize(size); + }, + showSizeChanger: true, + pageSizeOptions: ["10", "25", "50", "100"], + }} + expandable={{ + expandedRowRender: (record) => ( +
+
+ + ), + }} + /> + + + + + ); +}; diff --git a/apps/react-admin/src/components/abp/claims/claim-modal.tsx b/apps/react-admin/src/components/abp/claims/claim-modal.tsx new file mode 100644 index 000000000..1da72b42f --- /dev/null +++ b/apps/react-admin/src/components/abp/claims/claim-modal.tsx @@ -0,0 +1,111 @@ +import type React from "react"; +import { useEffect } from "react"; +import { Modal, Form, Input, Select } from "antd"; +import { useTranslation } from "react-i18next"; +import type { IdentityClaimCreateDto, IdentityClaimDto, IdentityClaimUpdateDto } from "#/management/identity/claims"; +import { useQuery, useMutation } from "@tanstack/react-query"; +import { getAssignableClaimsApi } from "@/api/management/identity/claim-types"; +import { toast } from "sonner"; + +interface ClaimEditModalProps { + visible: boolean; + claim?: IdentityClaimDto; + onClose: () => void; + onChange: (data: IdentityClaimDto) => void; + createApi: (input: IdentityClaimCreateDto) => Promise; + updateApi: (input: IdentityClaimUpdateDto) => Promise; +} + +const ClaimModal: React.FC = ({ visible, claim, onClose, onChange, createApi, updateApi }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + + // Query for assignable claims + const { data: assignableClaimsData } = useQuery({ + queryKey: ["assignableClaims"], + queryFn: getAssignableClaimsApi, + enabled: visible && !claim?.id, + }); + + // Mutations for create/update + const { mutateAsync: mutateCreate, isPending: isCreating } = useMutation({ + mutationFn: createApi, + onSuccess: (_, variables) => { + onChange(variables as IdentityClaimDto); + onClose(); + toast.success($t("AbpUi.CreatedSuccessfully")); + }, + }); + + const { mutateAsync: mutateUpdate, isPending: isUpdating } = useMutation({ + mutationFn: updateApi, + onSuccess: (_, variables) => { + onChange({ + claimType: claim?.claimType, + claimValue: variables.newClaimValue, + id: claim?.id, + } as IdentityClaimDto); + onClose(); + toast.success($t("AbpUi.SavedSuccessfully")); + }, + }); + + useEffect(() => { + if (visible) { + form.resetFields(); + if (claim) { + form.setFieldsValue({ + ...claim, + newClaimValue: claim.claimValue, + }); + } + } + }, [visible, claim, form.setFieldsValue, form.resetFields]); + + const handleOk = async () => { + try { + const values = await form.validateFields(); + if (claim?.id) { + await mutateUpdate({ + claimType: claim.claimType, + claimValue: claim.claimValue, + newClaimValue: values.claimValue, + }); + } else { + await mutateCreate({ + claimType: values.claimType, + claimValue: values.claimValue, + }); + } + } catch (error) { + // Form validation error, no need to handle + } + }; + + return ( + +
+ + ({ + label: lang.displayName, + value: lang.cultureName, + }))} + /> + + + + + +
+ ); +}; + +export default DisplayNameModal; diff --git a/apps/react-admin/src/components/abp/display-names/display-name-table.tsx b/apps/react-admin/src/components/abp/display-names/display-name-table.tsx new file mode 100644 index 000000000..3454df082 --- /dev/null +++ b/apps/react-admin/src/components/abp/display-names/display-name-table.tsx @@ -0,0 +1,75 @@ +import { useState } from "react"; +import { Button, Popconfirm } from "antd"; +import { DeleteOutlined, PlusOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { ProTable, type ProColumns } from "@ant-design/pro-table"; +import type { DisplayNameInfo, DisplayNameProps } from "./types"; +import DisplayNameModal from "./display-name-modal"; + +const DisplayNameTable: React.FC = ({ data, onChange, onDelete }) => { + const { t: $t } = useTranslation(); + const [modalVisible, setModalVisible] = useState(false); + + const dataSource = Object.entries(data || {}).map(([culture, displayName]) => ({ + culture, + displayName, + key: culture, + })); + + const columns: ProColumns[] = [ + { + title: $t("AbpOpenIddict.DisplayName:CultureName"), + dataIndex: "culture", + align: "left", + width: 200, + }, + { + title: $t("AbpOpenIddict.DisplayName:DisplayName"), + dataIndex: "displayName", + align: "left", + width: 200, + }, + { + title: $t("AbpUi.Actions"), + width: 180, + fixed: "right", + render: (_, record) => ( + onDelete?.(record)} + > + + + ), + }, + ]; + + return ( + <> + + columns={columns} + dataSource={dataSource} + search={false} + pagination={false} + toolBarRender={() => [ + , + ]} + /> + + setModalVisible(false)} + onChange={(info) => { + onChange?.(info); + setModalVisible(false); + }} + /> + + ); +}; + +export default DisplayNameTable; diff --git a/apps/react-admin/src/components/abp/display-names/types.ts b/apps/react-admin/src/components/abp/display-names/types.ts new file mode 100644 index 000000000..2266a7a59 --- /dev/null +++ b/apps/react-admin/src/components/abp/display-names/types.ts @@ -0,0 +1,12 @@ +import type { Dictionary } from "#/abp-core"; + +export interface DisplayNameInfo { + culture: string; + displayName: string; +} + +export interface DisplayNameProps { + data?: Dictionary; + onChange?: (data: DisplayNameInfo) => void; + onDelete?: (data: DisplayNameInfo) => void; +} diff --git a/apps/react-admin/src/components/abp/localizable-input/localizable-input.tsx b/apps/react-admin/src/components/abp/localizable-input/localizable-input.tsx new file mode 100644 index 000000000..07939546d --- /dev/null +++ b/apps/react-admin/src/components/abp/localizable-input/localizable-input.tsx @@ -0,0 +1,183 @@ +import { useCallback, useEffect, useMemo, useState } from "react"; +import { Form, Input, Select } from "antd"; +import type { DefaultOptionType } from "antd/es/select"; +import { useTranslation } from "react-i18next"; +import { isNullOrWhiteSpace } from "@/utils/string"; +import type { LocalizableStringInfo } from "#/abp-core/global"; +import useAbpStore from "@/store/abpCoreStore"; +import { localizationSerializer } from "@/utils/abp/localization-serializer"; + +interface Props { + allowClear?: boolean; + disabled?: boolean; + value?: string; + onChange?: (value: string) => void; +} + +interface State { + displayName?: string; + displayNames: DefaultOptionType[]; + resourceName?: string; +} + +const LocalizableInput: React.FC = ({ allowClear, disabled, value, onChange }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + const abpStore = useAbpStore(); + const { deserialize, serialize } = localizationSerializer(); + + const [state, setState] = useState({ + displayNames: [], + displayName: undefined, + resourceName: undefined, + }); + + const isFixed = useMemo(() => { + return state.resourceName === "Fixed"; + }, [state.resourceName]); + + const resources = useMemo(() => { + if (!abpStore.localization) { + return []; + } + + const sources = Object.keys(abpStore.localization.resources).map((key) => ({ + label: key, + value: key, + })); + + return [ + { + label: $t("component.localizable_input.resources.fiexed.group"), + options: [ + { + label: $t("component.localizable_input.resources.fiexed.label"), + value: "Fixed", + }, + ], + value: "F", + }, + { + label: $t("component.localizable_input.resources.localization.group"), + options: sources, + value: "R", + }, + ]; + }, [abpStore.localization, $t]); + + const triggerDisplayNameChange = useCallback( + (displayName?: string) => { + if (!displayName) return; + + let updateValue = ""; + if (isFixed) { + updateValue = `F:${displayName}`; + } else if (!isNullOrWhiteSpace(state.resourceName)) { + const info: LocalizableStringInfo = { + name: displayName, + resourceName: state.resourceName ?? "", + }; + updateValue = serialize(info); + } + + onChange?.(updateValue); + form.setFieldValue("localizableInput", updateValue); + }, + [isFixed, state.resourceName, serialize, onChange, form], + ); + + const handleDisplayNameChange = (value?: string) => { + setState((prev) => ({ ...prev, displayName: value })); + triggerDisplayNameChange(value); + }; + + const localizationResources = abpStore.localization?.resources; + const handleResourceChange = useCallback( + (value?: string, triggerChanged = false) => { + const newDisplayNames: DefaultOptionType[] = []; + + if (value && localizationResources?.[value]) { + Object.keys(localizationResources[value].texts).forEach((key) => { + const labelText = localizationResources[value]?.texts[key]; + newDisplayNames.push({ + label: labelText ?? key, + value: key, + }); + }); + } + + setState((prev) => ({ + ...prev, + displayNames: newDisplayNames, + displayName: undefined, + resourceName: value, + })); + + if (triggerChanged) { + triggerDisplayNameChange(undefined); + } + }, + [localizationResources, triggerDisplayNameChange], + ); + useEffect(() => { + if (value) { + const info = deserialize(value); + if (state.resourceName !== info.resourceName) { + handleResourceChange(isNullOrWhiteSpace(info.resourceName) ? undefined : info.resourceName, false); + } + if (state.displayName !== info.name) { + setState((prev) => ({ + ...prev, + displayName: isNullOrWhiteSpace(info.name) ? undefined : info.name, + })); + } + } + }, [value]); + + return ( +
+ + +
+
+ handleDisplayNameChange(e.target.value)} + /> + ) : ( + + + + + + + + ); +}; + +export default PropertyModal; diff --git a/apps/react-admin/src/components/abp/properties/property-table.tsx b/apps/react-admin/src/components/abp/properties/property-table.tsx new file mode 100644 index 000000000..363713997 --- /dev/null +++ b/apps/react-admin/src/components/abp/properties/property-table.tsx @@ -0,0 +1,102 @@ +import { Button, Popconfirm, Table } from "antd"; +import type { ColumnsType } from "antd/es/table"; +import { PlusOutlined, DeleteOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { useMemo, useState } from "react"; +import PropertyModal from "./property-modal"; +import type { PropertyInfo, PropertyProps } from "./types"; + +const PropertyTable: React.FC = ({ + data = {}, + allowDelete = true, + allowEdit = true, + disabled = false, + onChange, + onDelete, +}) => { + const { t: $t } = useTranslation(); + const [modalVisible, setModalVisible] = useState(false); + + const dataSource = useMemo((): PropertyInfo[] => { + return Object.keys(data).map((key) => ({ + key, + value: data[key], + })); + }, [data]); + + const columns: ColumnsType = useMemo(() => { + const baseColumns: ColumnsType = [ + { + align: "left", + dataIndex: "key", + fixed: "left", + width: 100, + title: $t("component.extra_property_dictionary.key"), + }, + { + align: "left", + dataIndex: "value", + fixed: "left", + title: $t("component.extra_property_dictionary.value"), + }, + ]; + + if (disabled) { + return baseColumns; + } + + return [ + ...baseColumns, + { + align: "center", + dataIndex: "action", + fixed: "right", + key: "action", + title: $t("component.extra_property_dictionary.actions.title"), + width: 150, + render: (_, record: PropertyInfo) => + allowDelete && ( + handleDelete(record)} + > + + + ), + }, + ]; + }, [disabled, allowDelete, $t]); + + const handleCreate = () => { + setModalVisible(true); + }; + + const handleDelete = (prop: PropertyInfo) => { + onDelete?.(prop); + }; + + const handleChange = (prop: PropertyInfo) => { + onChange?.(prop); + setModalVisible(false); + }; + + return ( +
+
+ {!disabled && allowEdit && ( + + )} +
+
+
+ + setModalVisible(false)} onChange={handleChange} /> + + ); +}; + +export default PropertyTable; diff --git a/apps/react-admin/src/components/abp/properties/types.ts b/apps/react-admin/src/components/abp/properties/types.ts new file mode 100644 index 000000000..591fa70fc --- /dev/null +++ b/apps/react-admin/src/components/abp/properties/types.ts @@ -0,0 +1,16 @@ +import type { Dictionary } from "#/abp-core"; + +interface PropertyInfo { + key: string; + value: string; +} +interface PropertyProps { + allowDelete?: boolean; + allowEdit?: boolean; + data?: Dictionary; + disabled?: boolean; + onChange?: (data: PropertyInfo) => void; + onDelete?: (data: PropertyInfo) => void; +} + +export type { PropertyInfo, PropertyProps }; diff --git a/apps/react-admin/src/components/animate/motion-container.tsx b/apps/react-admin/src/components/animate/motion-container.tsx new file mode 100644 index 000000000..953386109 --- /dev/null +++ b/apps/react-admin/src/components/animate/motion-container.tsx @@ -0,0 +1,40 @@ +import { type MotionProps, m } from "framer-motion"; + +import { varContainer } from "./variants/container"; + +interface Props extends MotionProps { + className?: string; +} + +/** + * Motion 通用容器 + * + * variants: [变体可以用于使用单个动画道具为组件的整个子树设置动画](https://www.framer.com/motion/animation/#variants) + * + * Variants 是一组预定义的对象 + * const variants = { + * visible: { opacity: 1 }, + * hidden: { opacity: 0 }, + * } + * + * 需要指定 inital 和 animate 属性名 + * + */ +export default function MotionContainer({ children, className }: Props) { + return ( + + {children} + + ); +} diff --git a/apps/react-admin/src/components/animate/motion-lazy.tsx b/apps/react-admin/src/components/animate/motion-lazy.tsx new file mode 100644 index 000000000..ffd70a2b8 --- /dev/null +++ b/apps/react-admin/src/components/animate/motion-lazy.tsx @@ -0,0 +1,15 @@ +import { LazyMotion, domMax, m } from "framer-motion"; + +type Props = { + children: React.ReactNode; +}; +/** + * [Reduce bundle size by lazy-loading a subset of Motion's features](https://www.framer.com/motion/lazy-motion/) + */ +export function MotionLazy({ children }: Props) { + return ( + + {children} + + ); +} diff --git a/apps/react-admin/src/components/animate/motion-viewport.tsx b/apps/react-admin/src/components/animate/motion-viewport.tsx new file mode 100644 index 000000000..d2262c258 --- /dev/null +++ b/apps/react-admin/src/components/animate/motion-viewport.tsx @@ -0,0 +1,28 @@ +import { type MotionProps, m } from "framer-motion"; + +import { varContainer } from "./variants"; + +interface Props extends MotionProps { + className?: string; +} +/** + * [whileInView: 元素可以在进出视口时设置动画](https://www.framer.com/motion/scroll-animations/#scroll-triggered-animations) + * + * + viewport: [视口](https://www.framer.com/motion/scroll-animations/###viewport) + * + * + once: 仅触发一次 + */ +export default function MotionViewport({ children, className, ...other }: Props) { + return ( + + {children} + + ); +} diff --git a/apps/react-admin/src/components/animate/types.ts b/apps/react-admin/src/components/animate/types.ts new file mode 100644 index 000000000..9f98899e2 --- /dev/null +++ b/apps/react-admin/src/components/animate/types.ts @@ -0,0 +1,26 @@ +export type VariantsType = { + durationIn?: number; + durationOut?: number; + easeIn?: []; + easeOut?: []; + distance?: number; +}; + +export type TranHoverType = { + duration?: number; + ease?: []; +}; +export type TranEnterType = { + durationIn?: number; + easeIn?: []; +}; +export type TranExitType = { + durationOut?: number; + easeOut?: []; +}; + +export type BackgroundType = { + duration?: number; + ease?: []; + colors?: string[]; +}; diff --git a/apps/react-admin/src/components/animate/variants/action.ts b/apps/react-admin/src/components/animate/variants/action.ts new file mode 100644 index 000000000..4f7adbe51 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/action.ts @@ -0,0 +1,9 @@ +/** + * https://www.framer.com/motion/gestures/ + * @param hover + * @param tap + */ +export const varHover = (hover = 1.09, tap = 0.97) => ({ + hover: { scale: hover }, + tap: { scale: tap }, +}); diff --git a/apps/react-admin/src/components/animate/variants/background.ts b/apps/react-admin/src/components/animate/variants/background.ts new file mode 100644 index 000000000..a98458c6b --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/background.ts @@ -0,0 +1,103 @@ +import type { BackgroundType } from "../types"; + +export const varBgColor = (props?: BackgroundType) => { + const colors = props?.colors || ["#19dcea", "#b22cff"]; + const duration = props?.duration || 5; + const ease = props?.ease || "linear"; + + return { + animate: { + background: colors, + transition: { duration, ease }, + }, + }; +}; + +// ---------------------------------------------------------------------- + +export const varBgKenburns = (props?: BackgroundType) => { + const duration = props?.duration || 5; + const ease = props?.ease || "easeOut"; + + return { + top: { + animate: { + scale: [1, 1.25], + y: [0, -15], + transformOrigin: ["50% 16%", "50% top"], + transition: { duration, ease }, + }, + }, + bottom: { + animate: { + scale: [1, 1.25], + y: [0, 15], + transformOrigin: ["50% 84%", "50% bottom"], + transition: { duration, ease }, + }, + }, + left: { + animate: { + scale: [1, 1.25], + x: [0, 20], + y: [0, 15], + transformOrigin: ["16% 50%", "0% left"], + transition: { duration, ease }, + }, + }, + right: { + animate: { + scale: [1, 1.25], + x: [0, -20], + y: [0, -15], + transformOrigin: ["84% 50%", "0% right"], + transition: { duration, ease }, + }, + }, + }; +}; + +// ---------------------------------------------------------------------- + +export const varBgPan = (props?: BackgroundType) => { + const colors = props?.colors || ["#ee7752", "#e73c7e", "#23a6d5", "#23d5ab"]; + const duration = props?.duration || 5; + const ease = props?.ease || "linear"; + + const gradient = (deg: number) => `linear-gradient(${deg}deg, ${colors})`; + + return { + top: { + animate: { + backgroundImage: [gradient(0), gradient(0)], + backgroundPosition: ["center 99%", "center 1%"], + backgroundSize: ["100% 600%", "100% 600%"], + transition: { duration, ease }, + }, + }, + right: { + animate: { + backgroundPosition: ["1% center", "99% center"], + backgroundImage: [gradient(270), gradient(270)], + backgroundSize: ["600% 100%", "600% 100%"], + transition: { duration, ease }, + }, + }, + bottom: { + animate: { + backgroundImage: [gradient(0), gradient(0)], + backgroundPosition: ["center 1%", "center 99%"], + backgroundSize: ["100% 600%", "100% 600%"], + transition: { duration, ease }, + }, + }, + left: { + animate: { + backgroundPosition: ["99% center", "1% center"], + backgroundImage: [gradient(270), gradient(270)], + backgroundSize: ["600% 100%", "600% 100%"], + transition: { duration, ease }, + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/bounce.ts b/apps/react-admin/src/components/animate/variants/bounce.ts new file mode 100644 index 000000000..8830c8aba --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/bounce.ts @@ -0,0 +1,111 @@ +import type { VariantsType } from "../types"; + +import { varTranEnter, varTranExit } from "./transition"; + +export const varBounce = (props?: VariantsType) => { + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + in: { + initial: {}, + animate: { + scale: [0.3, 1.1, 0.9, 1.03, 0.97, 1], + opacity: [0, 1, 1, 1, 1, 1], + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scale: [0.9, 1.1, 0.3], + opacity: [1, 1, 0], + }, + }, + inUp: { + initial: {}, + animate: { + y: [720, -24, 12, -4, 0], + scaleY: [4, 0.9, 0.95, 0.985, 1], + opacity: [0, 1, 1, 1, 1], + transition: { ...varTranEnter({ durationIn, easeIn }) }, + }, + exit: { + y: [12, -24, 720], + scaleY: [0.985, 0.9, 3], + opacity: [1, 1, 0], + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inDown: { + initial: {}, + animate: { + y: [-720, 24, -12, 4, 0], + scaleY: [4, 0.9, 0.95, 0.985, 1], + opacity: [0, 1, 1, 1, 1], + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + y: [-12, 24, -720], + scaleY: [0.985, 0.9, 3], + opacity: [1, 1, 0], + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inLeft: { + initial: {}, + animate: { + x: [-720, 24, -12, 4, 0], + scaleX: [3, 1, 0.98, 0.995, 1], + opacity: [0, 1, 1, 1, 1], + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + x: [0, 24, -720], + scaleX: [1, 0.9, 2], + opacity: [1, 1, 0], + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inRight: { + initial: {}, + animate: { + x: [720, -24, 12, -4, 0], + scaleX: [3, 1, 0.98, 0.995, 1], + opacity: [0, 1, 1, 1, 1], + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + x: [0, -24, 720], + scaleX: [1, 0.9, 2], + opacity: [1, 1, 0], + transition: varTranExit({ durationOut, easeOut }), + }, + }, + + // OUT + out: { + animate: { scale: [0.9, 1.1, 0.3], opacity: [1, 1, 0] }, + }, + outUp: { + animate: { + y: [-12, 24, -720], + scaleY: [0.985, 0.9, 3], + opacity: [1, 1, 0], + }, + }, + outDown: { + animate: { + y: [12, -24, 720], + scaleY: [0.985, 0.9, 3], + opacity: [1, 1, 0], + }, + }, + outLeft: { + animate: { x: [0, 24, -720], scaleX: [1, 0.9, 2], opacity: [1, 1, 0] }, + }, + outRight: { + animate: { x: [0, -24, 720], scaleX: [1, 0.9, 2], opacity: [1, 1, 0] }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/container.ts b/apps/react-admin/src/components/animate/variants/container.ts new file mode 100644 index 000000000..77ce2f1de --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/container.ts @@ -0,0 +1,26 @@ +export type Props = { + staggerIn?: number; + delayIn?: number; + staggerOut?: number; +}; + +export const varContainer = (props?: Props) => { + const staggerIn = props?.staggerIn || 0.05; + const delayIn = props?.staggerIn || 0.05; + const staggerOut = props?.staggerIn || 0.05; + + return { + animate: { + transition: { + staggerChildren: staggerIn, + delayChildren: delayIn, + }, + }, + exit: { + transition: { + staggerChildren: staggerOut, + staggerDirection: -1, + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/fade.ts b/apps/react-admin/src/components/animate/variants/fade.ts new file mode 100644 index 000000000..114b3c561 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/fade.ts @@ -0,0 +1,134 @@ +import type { VariantsType } from "../types"; + +// +import { varTranEnter, varTranExit } from "./transition"; + +// ---------------------------------------------------------------------- + +export const varFade = (props?: VariantsType) => { + const distance = props?.distance || 120; + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + in: { + initial: { opacity: 0 }, + animate: { opacity: 1, transition: varTranEnter }, + exit: { opacity: 0, transition: varTranExit }, + }, + inUp: { + initial: { y: distance, opacity: 0 }, + animate: { + y: 0, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + y: distance, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inDown: { + initial: { y: -distance, opacity: 0 }, + animate: { + y: 0, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + y: -distance, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inLeft: { + initial: { x: -distance, opacity: 0 }, + animate: { + x: 0, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + x: -distance, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inRight: { + initial: { x: distance, opacity: 0 }, + animate: { + x: 0, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + x: distance, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + + // OUT + out: { + initial: { opacity: 1 }, + animate: { opacity: 0, transition: varTranEnter({ durationIn, easeIn }) }, + exit: { opacity: 1, transition: varTranExit({ durationOut, easeOut }) }, + }, + outUp: { + initial: { y: 0, opacity: 1 }, + animate: { + y: -distance, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + y: 0, + opacity: 1, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + outDown: { + initial: { y: 0, opacity: 1 }, + animate: { + y: distance, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + y: 0, + opacity: 1, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + outLeft: { + initial: { x: 0, opacity: 1 }, + animate: { + x: -distance, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + x: 0, + opacity: 1, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + outRight: { + initial: { x: 0, opacity: 1 }, + animate: { + x: distance, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + x: 0, + opacity: 1, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/flip.ts b/apps/react-admin/src/components/animate/variants/flip.ts new file mode 100644 index 000000000..b7828ef8d --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/flip.ts @@ -0,0 +1,61 @@ +import type { VariantsType } from "../types"; + +// +import { varTranEnter, varTranExit } from "./transition"; + +// ---------------------------------------------------------------------- + +export const varFlip = (props?: VariantsType) => { + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + inX: { + initial: { rotateX: -180, opacity: 0 }, + animate: { + rotateX: 0, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + rotateX: -180, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inY: { + initial: { rotateY: -180, opacity: 0 }, + animate: { + rotateY: 0, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + rotateY: -180, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + + // OUT + outX: { + initial: { rotateX: 0, opacity: 1 }, + animate: { + rotateX: 70, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + outY: { + initial: { rotateY: 0, opacity: 1 }, + animate: { + rotateY: 70, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/index.ts b/apps/react-admin/src/components/animate/variants/index.ts new file mode 100644 index 000000000..26fc19a28 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/index.ts @@ -0,0 +1,98 @@ +import { varBgColor, varBgKenburns, varBgPan } from "./background"; +import { varBounce } from "./bounce"; +import { varFade } from "./fade"; +import { varFlip } from "./flip"; +import { varRotate } from "./rotate"; +import { varScale } from "./scale"; +import { varSlide } from "./slide"; +import { varZoom } from "./zoom"; + +export * from "./action"; +export * from "./background"; +export * from "./bounce"; +export * from "./container"; +export * from "./fade"; +export * from "./flip"; +export * from "./path"; +export * from "./rotate"; +export * from "./scale"; +export * from "./slide"; +export * from "./transition"; +export * from "./zoom"; + +export function getVariant(variant = "slideInUp") { + return { + // Slide + slideInUp: varSlide().inUp, + slideInDown: varSlide().inDown, + slideInLeft: varSlide().inLeft, + slideInRight: varSlide().inRight, + slideOutUp: varSlide().outUp, + slideOutDown: varSlide().outDown, + slideOutLeft: varSlide().outLeft, + slideOutRight: varSlide().outRight, + // Fade + fadeIn: varFade().in, + fadeInUp: varFade().inUp, + fadeInDown: varFade().inDown, + fadeInLeft: varFade().inLeft, + fadeInRight: varFade().inRight, + fadeOut: varFade().out, + fadeOutUp: varFade().outUp, + fadeOutDown: varFade().outDown, + fadeOutLeft: varFade().outLeft, + fadeOutRight: varFade().outRight, + // Zoom + zoomIn: varZoom({ distance: 80 }).in, + zoomInUp: varZoom({ distance: 80 }).inUp, + zoomInDown: varZoom({ distance: 80 }).inDown, + zoomInLeft: varZoom({ distance: 240 }).inLeft, + zoomInRight: varZoom({ distance: 240 }).inRight, + zoomOut: varZoom().out, + zoomOutLeft: varZoom().outLeft, + zoomOutRight: varZoom().outRight, + zoomOutUp: varZoom().outUp, + zoomOutDown: varZoom().outDown, + // Bounce + bounceIn: varBounce().in, + bounceInUp: varBounce().inUp, + bounceInDown: varBounce().inDown, + bounceInLeft: varBounce().inLeft, + bounceInRight: varBounce().inRight, + bounceOut: varBounce().out, + bounceOutUp: varBounce().outUp, + bounceOutDown: varBounce().outDown, + bounceOutLeft: varBounce().outLeft, + bounceOutRight: varBounce().outRight, + // Flip + flipInX: varFlip().inX, + flipInY: varFlip().inY, + flipOutX: varFlip().outX, + flipOutY: varFlip().outY, + // Scale + scaleInX: varScale().inX, + scaleInY: varScale().inY, + scaleOutX: varScale().outX, + scaleOutY: varScale().outY, + // Rotate + rotateIn: varRotate().in, + rotateOut: varRotate().out, + // Background + kenburnsTop: varBgKenburns().top, + kenburnsBottom: varBgKenburns().bottom, + kenburnsLeft: varBgKenburns().left, + kenburnsRight: varBgKenburns().right, + panTop: varBgPan().top, + panBottom: varBgPan().bottom, + panLeft: varBgPan().left, + panRight: varBgPan().right, + color2x: varBgColor(), + color3x: varBgColor({ colors: ["#19dcea", "#b22cff", "#ea2222"] }), + color4x: varBgColor({ + colors: ["#19dcea", "#b22cff", "#ea2222", "#f5be10"], + }), + color5x: varBgColor({ + colors: ["#19dcea", "#b22cff", "#ea2222", "#f5be10", "#3bd80d"], + }), + }[variant]; +} diff --git a/apps/react-admin/src/components/animate/variants/path.ts b/apps/react-admin/src/components/animate/variants/path.ts new file mode 100644 index 000000000..cf31ab913 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/path.ts @@ -0,0 +1,14 @@ +// ---------------------------------------------------------------------- + +export const TRANSITION = { + duration: 2, + ease: [0.43, 0.13, 0.23, 0.96], +}; + +export const varPath = { + animate: { + fillOpacity: [0, 0, 1], + pathLength: [1, 0.4, 0], + transition: TRANSITION, + }, +}; diff --git a/apps/react-admin/src/components/animate/variants/rotate.ts b/apps/react-admin/src/components/animate/variants/rotate.ts new file mode 100644 index 000000000..6b6544003 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/rotate.ts @@ -0,0 +1,40 @@ +import type { VariantsType } from "../types"; + +// +import { varTranEnter, varTranExit } from "./transition"; + +// ---------------------------------------------------------------------- + +export const varRotate = (props?: VariantsType) => { + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + in: { + initial: { opacity: 0, rotate: -360 }, + animate: { + opacity: 1, + rotate: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + opacity: 0, + rotate: -360, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + + // OUT + out: { + initial: { opacity: 1, rotate: 0 }, + animate: { + opacity: 0, + rotate: -360, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/scale.ts b/apps/react-admin/src/components/animate/variants/scale.ts new file mode 100644 index 000000000..7c3c507e8 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/scale.ts @@ -0,0 +1,60 @@ +import type { VariantsType } from "../types"; + +import { varTranEnter, varTranExit } from "./transition"; + +// ---------------------------------------------------------------------- + +export const varScale = (props?: VariantsType) => { + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + inX: { + initial: { scaleX: 0, opacity: 0 }, + animate: { + scaleX: 1, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scaleX: 0, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inY: { + initial: { scaleY: 0, opacity: 0 }, + animate: { + scaleY: 1, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scaleY: 0, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + + // OUT + outX: { + initial: { scaleX: 1, opacity: 1 }, + animate: { + scaleX: 0, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + outY: { + initial: { scaleY: 1, opacity: 1 }, + animate: { + scaleY: 0, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/slide.ts b/apps/react-admin/src/components/animate/variants/slide.ts new file mode 100644 index 000000000..c1a9f621a --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/slide.ts @@ -0,0 +1,72 @@ +import type { VariantsType } from "../types"; + +// +import { varTranEnter, varTranExit } from "./transition"; + +// ---------------------------------------------------------------------- + +export const varSlide = (props?: VariantsType) => { + const distance = props?.distance || 160; + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + inUp: { + initial: { y: distance }, + animate: { y: 0, transition: varTranEnter({ durationIn, easeIn }) }, + exit: { y: distance, transition: varTranExit({ durationOut, easeOut }) }, + }, + inDown: { + initial: { y: -distance }, + animate: { y: 0, transition: varTranEnter({ durationIn, easeIn }) }, + exit: { y: -distance, transition: varTranExit({ durationOut, easeOut }) }, + }, + inLeft: { + initial: { x: -distance }, + animate: { x: 0, transition: varTranEnter({ durationIn, easeIn }) }, + exit: { x: -distance, transition: varTranExit({ durationOut, easeOut }) }, + }, + inRight: { + initial: { x: distance }, + animate: { x: 0, transition: varTranEnter({ durationIn, easeIn }) }, + exit: { x: distance, transition: varTranExit({ durationOut, easeOut }) }, + }, + + // OUT + outUp: { + initial: { y: 0 }, + animate: { + y: -distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { y: 0, transition: varTranExit({ durationOut, easeOut }) }, + }, + outDown: { + initial: { y: 0 }, + animate: { + y: distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { y: 0, transition: varTranExit({ durationOut, easeOut }) }, + }, + outLeft: { + initial: { x: 0 }, + animate: { + x: -distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { x: 0, transition: varTranExit({ durationOut, easeOut }) }, + }, + outRight: { + initial: { x: 0 }, + animate: { + x: distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { x: 0, transition: varTranExit({ durationOut, easeOut }) }, + }, + }; +}; diff --git a/apps/react-admin/src/components/animate/variants/transition.ts b/apps/react-admin/src/components/animate/variants/transition.ts new file mode 100644 index 000000000..f3616d436 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/transition.ts @@ -0,0 +1,25 @@ +import type { TranEnterType, TranExitType, TranHoverType } from "../types"; + +// https://www.framer.com/motion/transition/ +// A transition defines how values animate from one state to another. + +export const varTranHover = (props?: TranHoverType) => { + const duration = props?.duration || 0.32; + const ease = props?.ease || [0.43, 0.13, 0.23, 0.96]; + + return { duration, ease }; +}; + +export const varTranEnter = (props?: TranEnterType) => { + const duration = props?.durationIn || 0.64; + const ease = props?.easeIn || [0.43, 0.13, 0.23, 0.96]; + + return { duration, ease }; +}; + +export const varTranExit = (props?: TranExitType) => { + const duration = props?.durationOut || 0.48; + const ease = props?.easeOut || [0.43, 0.13, 0.23, 0.96]; + + return { duration, ease }; +}; diff --git a/apps/react-admin/src/components/animate/variants/zoom.ts b/apps/react-admin/src/components/animate/variants/zoom.ts new file mode 100644 index 000000000..bdf9d15a8 --- /dev/null +++ b/apps/react-admin/src/components/animate/variants/zoom.ts @@ -0,0 +1,137 @@ +import type { VariantsType } from "../types"; + +// +import { varTranEnter, varTranExit } from "./transition"; + +// ---------------------------------------------------------------------- + +export const varZoom = (props?: VariantsType) => { + const distance = props?.distance || 720; + const durationIn = props?.durationIn; + const durationOut = props?.durationOut; + const easeIn = props?.easeIn; + const easeOut = props?.easeOut; + + return { + // IN + in: { + initial: { scale: 0, opacity: 0 }, + animate: { + scale: 1, + opacity: 1, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scale: 0, + opacity: 0, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inUp: { + initial: { scale: 0, opacity: 0, translateY: distance }, + animate: { + scale: 1, + opacity: 1, + translateY: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scale: 0, + opacity: 0, + translateY: distance, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inDown: { + initial: { scale: 0, opacity: 0, translateY: -distance }, + animate: { + scale: 1, + opacity: 1, + translateY: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scale: 0, + opacity: 0, + translateY: -distance, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inLeft: { + initial: { scale: 0, opacity: 0, translateX: -distance }, + animate: { + scale: 1, + opacity: 1, + translateX: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scale: 0, + opacity: 0, + translateX: -distance, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + inRight: { + initial: { scale: 0, opacity: 0, translateX: distance }, + animate: { + scale: 1, + opacity: 1, + translateX: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + exit: { + scale: 0, + opacity: 0, + translateX: distance, + transition: varTranExit({ durationOut, easeOut }), + }, + }, + + // OUT + out: { + initial: { scale: 1, opacity: 1 }, + animate: { + scale: 0, + opacity: 0, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + outUp: { + initial: { scale: 1, opacity: 1 }, + animate: { + scale: 0, + opacity: 0, + translateY: -distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + outDown: { + initial: { scale: 1, opacity: 1 }, + animate: { + scale: 0, + opacity: 0, + translateY: distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + outLeft: { + initial: { scale: 1, opacity: 1 }, + animate: { + scale: 0, + opacity: 0, + translateX: -distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + outRight: { + initial: { scale: 1, opacity: 1 }, + animate: { + scale: 0, + opacity: 0, + translateX: distance, + transition: varTranEnter({ durationIn, easeIn }), + }, + }, + }; +}; diff --git a/apps/react-admin/src/components/card/index.tsx b/apps/react-admin/src/components/card/index.tsx new file mode 100644 index 000000000..7602531e8 --- /dev/null +++ b/apps/react-admin/src/components/card/index.tsx @@ -0,0 +1,28 @@ +import { themeVars } from "@/theme/theme.css"; +import type { CSSProperties, ReactNode } from "react"; + +type Props = { + children?: ReactNode; + className?: string; + style?: CSSProperties; +}; +export default function Card({ children, ...other }: Props) { + return ( +
+ {children} +
+ ); +} diff --git a/apps/react-admin/src/components/chart/chart.tsx b/apps/react-admin/src/components/chart/chart.tsx new file mode 100644 index 000000000..06d1bb431 --- /dev/null +++ b/apps/react-admin/src/components/chart/chart.tsx @@ -0,0 +1,15 @@ +import { memo } from "react"; +import ApexChart from "react-apexcharts"; +import { chartWrapper } from "./styles.css"; + +import type { Props as ApexChartProps } from "react-apexcharts"; + +function Chart(props: ApexChartProps) { + return ( +
+ +
+ ); +} + +export default memo(Chart); diff --git a/apps/react-admin/src/components/chart/styles.css.ts b/apps/react-admin/src/components/chart/styles.css.ts new file mode 100644 index 000000000..e81a1b19c --- /dev/null +++ b/apps/react-admin/src/components/chart/styles.css.ts @@ -0,0 +1,54 @@ +import { themeVars } from "@/theme/theme.css"; +import { rgbAlpha } from "@/utils/theme"; +import { globalStyle } from "@vanilla-extract/css"; +import { style } from "@vanilla-extract/css"; + +export const chartWrapper = style({}, "apexcharts-wrapper"); + +// TOOLTIP +globalStyle(`${chartWrapper} .apexcharts-tooltip`, { + color: themeVars.colors.text.primary, + borderRadius: themeVars.borderRadius.lg, + backdropFilter: "blur(6px)", + backgroundColor: rgbAlpha(themeVars.colors.background.paperChannel, 0.8), + boxShadow: themeVars.shadows.card, +}); + +globalStyle(`${chartWrapper} .apexcharts-tooltip-title`, { + textAlign: "center", + fontWeight: "bold", + backgroundColor: themeVars.colors.background.neutral, +}); + +// TOOLTIP X +globalStyle(`${chartWrapper} .apexcharts-xaxistooltip`, { + color: themeVars.colors.text.primary, + borderRadius: themeVars.borderRadius.lg, + backdropFilter: "blur(6px)", + borderColor: "transparent", + boxShadow: themeVars.shadows.card, + backgroundColor: themeVars.colors.background.paper, +}); + +globalStyle(`${chartWrapper} .apexcharts-xaxistooltip::before`, { + borderBottomColor: rgbAlpha(themeVars.colors.background.paperChannel, 0.8), +}); + +globalStyle(`${chartWrapper} .apexcharts-xaxistooltip::after`, { + borderBottomColor: themeVars.colors.background.paper, +}); + +// LEGEND +globalStyle(`${chartWrapper} .apexcharts-legend`, { + padding: 0, +}); + +globalStyle(`${chartWrapper} .apexcharts-legend-series`, { + display: "inline-flex !important", + alignItems: "center", +}); + +globalStyle(`${chartWrapper} .apexcharts-legend-text`, { + lineHeight: "18px", + textTransform: "capitalize", +}); diff --git a/apps/react-admin/src/components/chart/useChart.ts b/apps/react-admin/src/components/chart/useChart.ts new file mode 100644 index 000000000..be29a8c68 --- /dev/null +++ b/apps/react-admin/src/components/chart/useChart.ts @@ -0,0 +1,211 @@ +import { themeVars } from "@/theme/theme.css"; +import { removePx } from "@/utils/theme"; +import type { ApexOptions } from "apexcharts"; +import { mergeDeepRight } from "ramda"; + +import { useSettings } from "@/store/settingStore"; +import { paletteColors, presetsColors } from "@/theme/tokens/color"; + +export default function useChart(options: ApexOptions) { + const { themeColorPresets } = useSettings(); + + const LABEL_TOTAL = { + show: true, + label: "Total", + color: themeVars.colors.text.secondary, + fontSize: themeVars.typography.fontSize.sm, + lineHeight: themeVars.typography.lineHeight.tight, + }; + + const LABEL_VALUE = { + offsetY: 8, + color: themeVars.colors.text.primary, + fontSize: themeVars.typography.fontSize.sm, + lineHeight: themeVars.typography.lineHeight.tight, + }; + + const baseOptions: ApexOptions = { + // Colors + colors: [ + presetsColors[themeColorPresets].default, + + paletteColors.info.default, + paletteColors.warning.default, + paletteColors.error.default, + paletteColors.success.default, + + paletteColors.warning.light, + paletteColors.info.light, + paletteColors.error.light, + paletteColors.success.light, + ], + + // Chart + chart: { + toolbar: { show: false }, + zoom: { enabled: false }, + foreColor: themeVars.colors.text.disabled, + fontFamily: themeVars.typography.fontFamily.primary, + }, + + // States + states: { + hover: { + filter: { + type: "lighten", + value: 0.04, + }, + }, + active: { + filter: { + type: "darken", + value: 0.88, + }, + }, + }, + + // Fill + fill: { + opacity: 1, + gradient: { + type: "vertical", + shadeIntensity: 0, + opacityFrom: 0.4, + opacityTo: 0, + stops: [0, 100], + }, + }, + + // Datalabels + dataLabels: { + enabled: false, + }, + + // Stroke + stroke: { + width: 3, + curve: "smooth", + lineCap: "round", + }, + + // Grid + grid: { + strokeDashArray: 3, + borderColor: themeVars.colors.background.neutral, + xaxis: { + lines: { + show: false, + }, + }, + }, + + // Xaxis + xaxis: { + axisBorder: { show: false }, + axisTicks: { show: false }, + }, + + // Markers + markers: { + size: 0, + }, + + // Tooltip + tooltip: { + theme: undefined, + x: { + show: true, + }, + }, + + // Legend + legend: { + show: true, + fontSize: themeVars.typography.fontSize.sm, + position: "top", + horizontalAlign: "right", + markers: { + strokeWidth: 0, + }, + fontWeight: 500, + itemMargin: { + horizontal: 8, + }, + labels: { + colors: themeVars.colors.text.primary, + }, + }, + + // plotOptions + plotOptions: { + // Bar + bar: { + borderRadius: 4, + columnWidth: "28%", + borderRadiusApplication: "end", + borderRadiusWhenStacked: "last", + }, + + // Pie + Donut + pie: { + donut: { + labels: { + show: true, + value: LABEL_VALUE, + total: LABEL_TOTAL, + }, + }, + }, + + // Radialbar + radialBar: { + track: { + strokeWidth: "100%", + }, + dataLabels: { + value: LABEL_VALUE, + total: LABEL_TOTAL, + }, + }, + + // Radar + radar: { + polygons: { + fill: { colors: ["transparent"] }, + strokeColors: themeVars.colors.background.neutral, + connectorColors: themeVars.colors.background.neutral, + }, + }, + + // polarArea + polarArea: { + rings: { + strokeColor: themeVars.colors.background.neutral, + }, + spokes: { + connectorColors: themeVars.colors.background.neutral, + }, + }, + }, + + // Responsive + responsive: [ + { + // sm + breakpoint: removePx(themeVars.screens.sm), + options: { + plotOptions: { bar: { columnWidth: "40%" } }, + }, + }, + { + // md + breakpoint: removePx(themeVars.screens.md), + options: { + plotOptions: { bar: { columnWidth: "32%" } }, + }, + }, + ], + }; + + return mergeDeepRight(baseOptions, options) as ApexOptions; +} diff --git a/apps/react-admin/src/components/editor/index.tsx b/apps/react-admin/src/components/editor/index.tsx new file mode 100644 index 000000000..f57d969d9 --- /dev/null +++ b/apps/react-admin/src/components/editor/index.tsx @@ -0,0 +1,36 @@ +/* eslint-disable import/order */ +import "@/utils/highlight"; +import ReactQuill, { type ReactQuillProps } from "react-quill"; +import { StyledEditor } from "./styles"; +import Toolbar, { formats } from "./toolbar"; + +interface Props extends ReactQuillProps { + sample?: boolean; + hiddleToolbar?: boolean; +} +export default function Editor({ id = "slash-quill", sample = false, hiddleToolbar = false, ...other }: Props) { + const modules = { + ...(hiddleToolbar + ? {} + : { + toolbar: { + container: `#${id}`, + }, + }), + history: { + delay: 500, + maxStack: 100, + userOnly: true, + }, + syntax: true, + clipboard: { + matchVisual: false, + }, + }; + return ( + + {!hiddleToolbar && } + + + ); +} diff --git a/apps/react-admin/src/components/editor/styles.ts b/apps/react-admin/src/components/editor/styles.ts new file mode 100644 index 000000000..87aa9ad00 --- /dev/null +++ b/apps/react-admin/src/components/editor/styles.ts @@ -0,0 +1,189 @@ +import { themeVars } from "@/theme/theme.css"; +import styled from "styled-components"; + +const StyledEditor = styled.div` + h1 { + font-size: 64px; + line-height: 1.25; + font-weight: 800; + } + h2 { + font-size: 56px; + line-height: 1.25; + font-weight: 800; + } + h3 { + font-size: 48px; + line-height: 1.25; + font-weight: 700; + } + h4 { + font-size: 40px; + line-height: 1.25; + font-weight: 700; + } + h5 { + font-size: 32px; + line-height: 1.25; + font-weight: 700; + } + h6 { + font-size: 24px; + line-height: 1.25; + font-weight: 600; + } + img { + display: inline; + } + overflow: hidden; + position: relative; + border-radius: 8px; + border: 1px solid ${themeVars.colors.common.border}; + & .ql-container.ql-snow { + border: none; + line-height: 1.6; + font-weight: 400; + font-size: 0.875rem; + } + & .ql-editor { + min-height: 160px; + max-height: 640px; + background-color: rgba(145, 158, 171, 0.08); + &.ql-blank::before { + font-style: normal; + color: ${themeVars.colors.text.secondary}; + } + & pre.ql-syntax { + border-radius: 8px; + line-height: 1.57143; + font-size: 0.875rem; + font-family: 'Public Sans', sans-serif; + font-weight: 400; + padding: 16px; + border-radius: 8px; + background-color: ${themeVars.colors.background.neutral}; + } + } +`; + +const StyledToolbar = styled.div` + & .ql-snow.ql-toolbar button:hover .ql-fill, + .ql-snow .ql-toolbar button:hover .ql-fill, + .ql-snow.ql-toolbar button:focus .ql-fill, + .ql-snow .ql-toolbar button:focus .ql-fill, + .ql-snow.ql-toolbar button.ql-active .ql-fill, + .ql-snow .ql-toolbar button.ql-active .ql-fill, + .ql-snow.ql-toolbar .ql-picker-label:hover .ql-fill, + .ql-snow .ql-toolbar .ql-picker-label:hover .ql-fill, + .ql-snow.ql-toolbar .ql-picker-label.ql-active .ql-fill, + .ql-snow .ql-toolbar .ql-picker-label.ql-active .ql-fill, + .ql-snow.ql-toolbar .ql-picker-item:hover .ql-fill, + .ql-snow .ql-toolbar .ql-picker-item:hover .ql-fill, + .ql-snow.ql-toolbar .ql-picker-item.ql-selected .ql-fill, + .ql-snow .ql-toolbar .ql-picker-item.ql-selected .ql-fill, + .ql-snow.ql-toolbar button:hover .ql-stroke.ql-fill, + .ql-snow .ql-toolbar button:hover .ql-stroke.ql-fill, + .ql-snow.ql-toolbar button:focus .ql-stroke.ql-fill, + .ql-snow .ql-toolbar button:focus .ql-stroke.ql-fill, + .ql-snow.ql-toolbar button.ql-active .ql-stroke.ql-fill, + .ql-snow .ql-toolbar button.ql-active .ql-stroke.ql-fill, + .ql-snow.ql-toolbar .ql-picker-label:hover .ql-stroke.ql-fill, + .ql-snow .ql-toolbar .ql-picker-label:hover .ql-stroke.ql-fill, + .ql-snow.ql-toolbar .ql-picker-label.ql-active .ql-stroke.ql-fill, + .ql-snow .ql-toolbar .ql-picker-label.ql-active .ql-stroke.ql-fill, + .ql-snow.ql-toolbar .ql-picker-item:hover .ql-stroke.ql-fill, + .ql-snow .ql-toolbar .ql-picker-item:hover .ql-stroke.ql-fill, + .ql-snow.ql-toolbar .ql-picker-item.ql-selected .ql-stroke.ql-fill, + .ql-snow .ql-toolbar .ql-picker-item.ql-selected .ql-stroke.ql-fill { + fill: ${themeVars.colors.palette.primary.default}; + } + & .ql-snow.ql-toolbar button:hover, + .ql-snow .ql-toolbar button:hover, + .ql-snow.ql-toolbar button:focus, + .ql-snow .ql-toolbar button:focus, + .ql-snow.ql-toolbar button.ql-active, + .ql-snow .ql-toolbar button.ql-active, + .ql-snow.ql-toolbar .ql-picker-label:hover, + .ql-snow .ql-toolbar .ql-picker-label:hover, + .ql-snow.ql-toolbar .ql-picker-label.ql-active, + .ql-snow .ql-toolbar .ql-picker-label.ql-active, + .ql-snow.ql-toolbar .ql-picker-item:hover, + .ql-snow .ql-toolbar .ql-picker-item:hover, + .ql-snow.ql-toolbar .ql-picker-item.ql-selected, + .ql-snow .ql-toolbar .ql-picker-item.ql-selected { + color: ${themeVars.colors.palette.primary.default}; + } + + & .ql-snow.ql-toolbar button:hover .ql-stroke, + .ql-snow .ql-toolbar button:hover .ql-stroke, + .ql-snow.ql-toolbar button:focus .ql-stroke, + .ql-snow .ql-toolbar button:focus .ql-stroke, + .ql-snow.ql-toolbar button.ql-active .ql-stroke, + .ql-snow .ql-toolbar button.ql-active .ql-stroke, + .ql-snow.ql-toolbar .ql-picker-label:hover .ql-stroke, + .ql-snow .ql-toolbar .ql-picker-label:hover .ql-stroke, + .ql-snow.ql-toolbar .ql-picker-label.ql-active .ql-stroke, + .ql-snow .ql-toolbar .ql-picker-label.ql-active .ql-stroke, + .ql-snow.ql-toolbar .ql-picker-item:hover .ql-stroke, + .ql-snow .ql-toolbar .ql-picker-item:hover .ql-stroke, + .ql-snow.ql-toolbar .ql-picker-item.ql-selected .ql-stroke, + .ql-snow .ql-toolbar .ql-picker-item.ql-selected .ql-stroke, + .ql-snow.ql-toolbar button:hover .ql-stroke-miter, + .ql-snow .ql-toolbar button:hover .ql-stroke-miter, + .ql-snow.ql-toolbar button:focus .ql-stroke-miter, + .ql-snow .ql-toolbar button:focus .ql-stroke-miter, + .ql-snow.ql-toolbar button.ql-active .ql-stroke-miter, + .ql-snow .ql-toolbar button.ql-active .ql-stroke-miter, + .ql-snow.ql-toolbar .ql-picker-label:hover .ql-stroke-miter, + .ql-snow .ql-toolbar .ql-picker-label:hover .ql-stroke-miter, + .ql-snow.ql-toolbar .ql-picker-label.ql-active .ql-stroke-miter, + .ql-snow .ql-toolbar .ql-picker-label.ql-active .ql-stroke-miter, + .ql-snow.ql-toolbar .ql-picker-item:hover .ql-stroke-miter, + .ql-snow .ql-toolbar .ql-picker-item:hover .ql-stroke-miter, + .ql-snow.ql-toolbar .ql-picker-item.ql-selected .ql-stroke-miter, + .ql-snow .ql-toolbar .ql-picker-item.ql-selected .ql-stroke-miter { + stroke: ${themeVars.colors.palette.primary.default}; + } + + & .ql-stroke { + stroke: ${themeVars.colors.text.primary}; + } + & .ql-fill, + .ql-stroke.ql-fill { + fill: ${themeVars.colors.text.primary}; + } + + & .ql-toolbar.ql-snow { + border: none; + border-bottom: 1px solid ${themeVars.colors.common.border}; + // Button + & button { + padding: 0; + display: flex; + align-items: center; + justify-content: center; + border-radius: 4px; + } + & button svg, + span svg { + width: 20px; + height: 20px; + } + & .ql-picker-label { + border-radius: 4px; + border-color: transparent !important; + background-color: ${themeVars.colors.background.paper}; + color: ${themeVars.colors.text.primary}; + } + & .ql-picker-options { + margin-top: 4px; + border: none; + max-height: 200px; + overflow: auto; + border-radius: 8px; + color: ${themeVars.colors.text.primary}; + background-color: ${themeVars.colors.background.paper}; + } + } +`; +export { StyledEditor, StyledToolbar }; diff --git a/apps/react-admin/src/components/editor/toolbar.tsx b/apps/react-admin/src/components/editor/toolbar.tsx new file mode 100644 index 000000000..6cb9d4b42 --- /dev/null +++ b/apps/react-admin/src/components/editor/toolbar.tsx @@ -0,0 +1,104 @@ +import { StyledToolbar } from "./styles"; + +const HEADINGS = ["Heading 1", "Heading 2", "Heading 3", "Heading 4", "Heading 5", "Heading 6"]; + +export const formats = [ + "align", + "background", + "blockquote", + "bold", + "bullet", + "code", + "code-block", + "color", + "direction", + "font", + "formula", + "header", + "image", + "indent", + "italic", + "link", + "list", + "script", + "size", + "strike", + "table", + "underline", + "video", +]; + +type EditorToolbarProps = { + id: string; + isSimple?: boolean; +}; + +export default function Toolbar({ id, isSimple }: EditorToolbarProps) { + return ( + +
+
+ +
+ +
+
+ + {!isSimple && ( +
+ +
+ )} + +
+
+ + {!isSimple && ( +
+
+ )} + + {!isSimple && ( +
+
+ )} + +
+
+
+

Welcome back 👋

+

{username}

+
+
+ Welcome to join the Discord channel to discuss everything about Slash Admin, or you can visite my blog: + +
+ + + + + + + + ); +} + +function BannerSvg() { + return ( + + Banner + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/carousel-card.tsx b/apps/react-admin/src/pages/dashboard/workbench/carousel-card.tsx new file mode 100644 index 000000000..b10e076b1 --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/carousel-card.tsx @@ -0,0 +1,28 @@ +import { Carousel } from "antd"; + +export default function CarouselCard() { + const contentStyle: React.CSSProperties = { + margin: 0, + height: "160px", + color: "#000000", + lineHeight: "160px", + textAlign: "center", + background: "#364d79", + }; + return ( + +
+

1

+
+
+

2

+
+
+

3

+
+
+

4

+
+
+ ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/conversion_applications.tsx b/apps/react-admin/src/pages/dashboard/workbench/conversion_applications.tsx new file mode 100644 index 000000000..3df78cc38 --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/conversion_applications.tsx @@ -0,0 +1,55 @@ +import { Iconify } from "@/components/icon"; +import { themeVars } from "@/theme/theme.css"; +import { Progress } from "antd"; + +export function Conversion() { + return ( + + ); +} +export function Applications() { + return ( + + ); +} + +type Props = { + percent: number; + title: string; + subtitle: string; + iconify: string; + bg?: string; + strokeColor?: string; +}; +function Basic({ percent, title, subtitle, iconify, bg, strokeColor }: Props) { + const format = (val?: number) => {val}%; + return ( +
+ +
+ {title} + {subtitle} +
+
+ +
+
+ ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/current-download.tsx b/apps/react-admin/src/pages/dashboard/workbench/current-download.tsx new file mode 100644 index 000000000..2606324ee --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/current-download.tsx @@ -0,0 +1,56 @@ +import { Typography } from "antd"; + +import Card from "@/components/card"; +import Chart from "@/components/chart/chart"; +import useChart from "@/components/chart/useChart"; + +export default function CurrentDownload() { + return ( + +
+ Current Download +
+
+ +
+
+ ); +} + +const series = [44, 55, 13, 43]; +function ChartDonut() { + const chartOptions = useChart({ + labels: ["Mac", "Window", "IOS", "Android"], + stroke: { + show: false, + }, + legend: { + position: "bottom", + horizontalAlign: "center", + }, + tooltip: { + fillSeriesColor: false, + }, + chart: { + width: 240, + }, + plotOptions: { + pie: { + donut: { + size: "90%", + labels: { + total: { + fontSize: "12px", + }, + value: { + fontSize: "18px", + fontWeight: 700, + }, + }, + }, + }, + }, + }); + + return ; +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/index.tsx b/apps/react-admin/src/pages/dashboard/workbench/index.tsx new file mode 100644 index 000000000..499315e04 --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/index.tsx @@ -0,0 +1,91 @@ +import { Col, Row, Space } from "antd"; + +import AreaDownload from "./area-download"; +import BannerCard from "./banner-card"; +import { Applications, Conversion } from "./conversion_applications"; +import CurrentDownload from "./current-download"; +import NewInvoice from "./new-invoice"; +import TopAuthor from "./top-authors"; +import TopInstalled from "./top-installed"; +import TopRelated from "./top-related"; +import TotalCard from "./total-card"; + +function Workbench() { + return ( +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + ); +} + +export default Workbench; diff --git a/apps/react-admin/src/pages/dashboard/workbench/new-invoice.tsx b/apps/react-admin/src/pages/dashboard/workbench/new-invoice.tsx new file mode 100644 index 000000000..62e15f428 --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/new-invoice.tsx @@ -0,0 +1,110 @@ +import { Space, Tag, Typography } from "antd"; +import Table, { type ColumnsType } from "antd/es/table"; + +import Card from "@/components/card"; +import { IconButton, Iconify } from "@/components/icon"; +import Scrollbar from "@/components/scrollbar"; + +interface DataType { + key: string; + id: string; + category: string; + price: string; + status: string; +} + +export default function NewInvoice() { + const columns: ColumnsType = [ + { + title: "InvoiceId", + dataIndex: "id", + key: "id", + render: (text) => {text}, + }, + { + title: "Category", + dataIndex: "category", + key: "category", + }, + { + title: "Price", + dataIndex: "price", + key: "price", + render: (text) => {text}, + }, + { + title: "Status", + key: "status", + dataIndex: "status", + render: (_status) => { + const status = _status as string; + let color = "success"; + if (status === "Progress") color = "gold"; + if (status === "Out of Date") color = "red"; + return {status}; + }, + }, + { + title: "Action", + key: "action", + render: () => ( + + + + + + ), + }, + ]; + + const data: DataType[] = [ + { + key: "1", + id: "INV-1990", + category: "Android", + price: "$83.74", + status: "Paid", + }, + { + key: "2", + id: "INV-1991", + category: "Mac", + price: "$97.14", + status: "Out of Date", + }, + { + key: "3", + id: "INV-1992", + category: "Windows", + price: "$68.71", + status: "Progress", + }, + { + key: "4", + id: "INV-1993", + category: "Android", + price: "$85.21", + status: "Paid", + }, + { + key: "5", + id: "INV-1994", + category: "Mac", + price: "$53.17", + status: "Paid", + }, + ]; + + return ( + +
+ New Invoice +
+
+ +
+ + + + ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/top-authors.tsx b/apps/react-admin/src/pages/dashboard/workbench/top-authors.tsx new file mode 100644 index 000000000..118751daa --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/top-authors.tsx @@ -0,0 +1,59 @@ +import Card from "@/components/card"; +import { Iconify } from "@/components/icon"; +import { themeVars } from "@/theme/theme.css"; +import { faker } from "@faker-js/faker"; +import { Typography } from "antd"; + +export default function TopAuthor() { + const getTrophyIconColor = (index: number) => { + switch (index) { + case 1: + return { + color: themeVars.colors.palette.info.default, + bg: `rgba(${themeVars.colors.palette.info.defaultChannel}, .4)`, + }; + case 2: { + return { + color: themeVars.colors.palette.error.default, + bg: `rgba(${themeVars.colors.palette.error.defaultChannel}, .4)`, + }; + } + default: + return { + color: themeVars.colors.palette.success.default, + bg: `rgba(${themeVars.colors.palette.success.defaultChannel}, .4)`, + }; + } + }; + return ( + +
+ Top Authors +
+
+ {new Array(3).fill("").map((_, index) => ( + // biome-ignore lint/suspicious/noArrayIndexKey: +
+ +
+ {faker.person.fullName()} +
+ + {faker.number.float({ min: 3, max: 9, multipleOf: 3 })}k +
+
+ +
+ +
+
+ ))} +
+
+ ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/top-installed.tsx b/apps/react-admin/src/pages/dashboard/workbench/top-installed.tsx new file mode 100644 index 000000000..bfa986ffa --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/top-installed.tsx @@ -0,0 +1,89 @@ +import { Typography } from "antd"; +import type { ReactNode } from "react"; + +import Card from "@/components/card"; +import { Iconify } from "@/components/icon"; + +const dataSource = [ + { + country: "Germany", + iconify: "twemoji:flag-germany", + android: "9.91k", + windows: "1.95k", + ios: "1.95k", + }, + { + country: "China", + iconify: "twemoji:flag-china", + android: "1.95k", + windows: "9.25k", + ios: "7.95k", + }, + { + country: "Australia", + iconify: "twemoji:flag-australia", + android: "3.91k", + windows: "2.95k", + ios: "4.95k", + }, + { + country: "France", + iconify: "twemoji:flag-france", + android: "3.28k", + windows: "2.29k", + ios: "8.95k", + }, + { + country: "USA", + iconify: "twemoji:flag-united-states", + android: "8.81k", + windows: "7.05k", + ios: "4.35k", + }, +]; + +const platformIcon = (platform: string) => { + let iconify: ReactNode; + if (platform === "android") { + iconify = ; + } + if (platform === "windows") { + iconify = ; + } + iconify = ; + + return
{iconify}
; +}; +export default function TopInstalled() { + return ( + +
+ Top Installed Countries +
+
+ {dataSource.map((item) => ( +
+ + {item.country} +
+
+ {platformIcon("android")} + {item.android} +
+ +
+ {platformIcon("windows")} + {item.windows} +
+ +
+ {platformIcon("ios")} + {item.ios} +
+
+
+ ))} +
+
+ ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/top-related.tsx b/apps/react-admin/src/pages/dashboard/workbench/top-related.tsx new file mode 100644 index 000000000..cba9f1528 --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/top-related.tsx @@ -0,0 +1,96 @@ +import { Tag, Typography } from "antd"; + +import Card from "@/components/card"; +import { Iconify } from "@/components/icon"; +import Scrollbar from "@/components/scrollbar"; +import { themeVars } from "@/theme/theme.css"; +import { Rate } from "antd"; + +const dataSource = [ + { + logo: , + title: "Chrome", + platform: "Mac", + type: "free", + star: 4, + reviews: "9.91k", + }, + { + logo: , + title: "Drive", + platform: "Mac", + type: "free", + star: 3.5, + reviews: "1.95k", + }, + { + logo: , + title: "Dropbox", + platform: "Windows", + type: "$66.71", + star: 4.5, + reviews: "9.12k", + }, + { + logo: , + title: "Slack", + platform: "Mac", + type: "free", + star: 3.5, + reviews: "6.98k", + }, + { + logo: , + title: "Discord", + platform: "Windows", + type: "$52.17", + star: 0.5, + reviews: "8.49k", + }, +]; +export default function TopRelated() { + return ( + +
+ Top Related Applications +
+
+ + {dataSource.map((item) => ( +
+
+ {item.logo} +
+ +
+ {item.title} +
+ {item.platform === "Mac" ? ( + + ) : ( + + )} + {item.platform} + {item.type} +
+
+ +
+ + {item.reviews}reviews +
+
+ ))} +
+
+
+ ); +} diff --git a/apps/react-admin/src/pages/dashboard/workbench/total-card.tsx b/apps/react-admin/src/pages/dashboard/workbench/total-card.tsx new file mode 100644 index 000000000..40c81f1a4 --- /dev/null +++ b/apps/react-admin/src/pages/dashboard/workbench/total-card.tsx @@ -0,0 +1,79 @@ +import Card from "@/components/card"; +import Chart from "@/components/chart/chart"; +import useChart from "@/components/chart/useChart"; +import { SvgIcon } from "@/components/icon"; + +type Props = { + title: string; + increase: boolean; + percent: string; + count: string; + chartData: number[]; +}; +export default function TotalCard({ title, increase, count, percent, chartData }: Props) { + return ( + +
+
{title}
+
+ {increase ? ( + + ) : ( + + )} +
+ {increase ? "+" : "-"} + {percent} +
+
+

{count}

+
+ + +
+ ); +} + +function ChartLine({ data }: { data: number[] }) { + const series = [ + { + name: "", + data, + }, + ]; + const chartOptions = useChart({ + tooltip: { + x: { + show: false, + }, + }, + xaxis: { + labels: { + show: false, + showDuplicates: false, + }, + tooltip: { + enabled: false, + }, + crosshairs: { + show: false, + }, + }, + yaxis: { + labels: { + show: false, + }, + tooltip: { + enabled: false, + }, + crosshairs: { + show: false, + }, + }, + grid: { + show: false, + }, + }); + + return ; +} diff --git a/apps/react-admin/src/pages/functions/clipboard/index.tsx b/apps/react-admin/src/pages/functions/clipboard/index.tsx new file mode 100644 index 000000000..fa38215d8 --- /dev/null +++ b/apps/react-admin/src/pages/functions/clipboard/index.tsx @@ -0,0 +1,37 @@ +import { faker } from "@faker-js/faker"; +import { Card, Col, Input, Row, Tooltip, Typography } from "antd"; +import { type ChangeEvent, useState } from "react"; + +import { IconButton, Iconify } from "@/components/icon"; +import { useCopyToClipboard } from "@/hooks/event/use-copy-to-clipboard"; + +export default function ClipboardPage() { + const { copyFn } = useCopyToClipboard(); + + const [value, setValue] = useState("https://www.npmjs.com/package/"); + + const textOnClick = faker.lorem.paragraphs({ min: 3, max: 5 }); + + const handleChange = (e: ChangeEvent) => setValue(e.target.value); + const CopyButton = ( + + copyFn(value)}> + + + + ); + return ( + + +
+ ON CHANGE + + + + ON DOUBLE CLICK + copyFn(textOnClick)}>{textOnClick} + + + + ); +} diff --git a/apps/react-admin/src/pages/functions/token-expired/index.tsx b/apps/react-admin/src/pages/functions/token-expired/index.tsx new file mode 100644 index 000000000..0d2c6e1bf --- /dev/null +++ b/apps/react-admin/src/pages/functions/token-expired/index.tsx @@ -0,0 +1,27 @@ +import { useMutation } from "@tanstack/react-query"; +import { Button, Card, Col, Row, Typography } from "antd"; + +import demoService from "@/api/services/demoService"; + +export default function TokenExpired() { + const tokenExpiredMutation = useMutation({ + mutationFn: demoService.mockTokenExpired, + }); + const mockTokenExpired = () => { + tokenExpiredMutation.mutate(); + }; + return ( + + + + Clicking a button to simulate a token expiration scenario. + + + + + + + ); +} diff --git a/apps/react-admin/src/pages/management/audit-logs/audit-log-drawer.tsx b/apps/react-admin/src/pages/management/audit-logs/audit-log-drawer.tsx new file mode 100644 index 000000000..c6f3242e3 --- /dev/null +++ b/apps/react-admin/src/pages/management/audit-logs/audit-log-drawer.tsx @@ -0,0 +1,151 @@ +import type React from "react"; +import { useEffect, useState } from "react"; +import { Descriptions, Drawer, Tabs, Tag } from "antd"; +import { useTranslation } from "react-i18next"; +import type { AuditLogDto, Action } from "#/management/auditing/audit-logs"; +import { Table } from "antd"; +import { useAuditLogs } from "@/hooks/abp/auditing/use-audit-logs"; +import { getApi } from "@/api/management/auditing/audit-logs"; +import { EntityChangeTable } from "@/components/abp/auditing/entity-change-table"; +import { formatToDateTime } from "@/utils/abp"; +import JsonEdit from "@/components/abp/common/json-edit"; + +interface Props { + visible: boolean; + onClose: () => void; + auditLog?: AuditLogDto; +} + +const AuditLogDrawer: React.FC = ({ visible, onClose, auditLog }) => { + const { t: $t } = useTranslation(); + const [activeTab, setActiveTab] = useState("basic"); + const [auditLogModel, setAuditLogModel] = useState({} as AuditLogDto); + const { getHttpMethodColor, getHttpStatusCodeColor } = useAuditLogs(); + + const actionColumns = [ + { + title: $t("AbpAuditLogging.ServiceName"), + dataIndex: "serviceName", + key: "serviceName", + sorter: true, + }, + { + title: $t("AbpAuditLogging.MethodName"), + dataIndex: "methodName", + key: "methodName", + ellipsis: true, + sorter: true, + }, + { + title: $t("AbpAuditLogging.ExecutionTime"), + dataIndex: "executionTime", + key: "executionTime", + ellipsis: true, + sorter: true, + render: (value: string) => (value ? formatToDateTime(value) : value), + }, + { + title: $t("AbpAuditLogging.ExecutionDuration"), + dataIndex: "executionDuration", + key: "executionDuration", + ellipsis: true, + width: 150, + sorter: true, + }, + ]; + + useEffect(() => { + if (visible && auditLog?.id) { + fetchAuditLog(auditLog.id); + } + }, [visible, auditLog]); + + const fetchAuditLog = async (id: string) => { + const dto = await getApi(id); + setAuditLogModel(dto); + }; + + const expandedRowRender = (record: Action) => ( + + + {} + + + {} + + + ); + + return ( + + + + + + {auditLogModel.applicationName} + + + {formatToDateTime(auditLogModel.executionTime)} + + {auditLogModel.userName} + + {auditLogModel.httpMethod} + + + {auditLogModel.url} + + + {auditLogModel.httpStatusCode} + + + {auditLogModel.executionDuration} + + {auditLogModel.clientId} + + {auditLogModel.clientIpAddress} + + {auditLogModel.clientName} + + {auditLogModel.correlationId} + + + {auditLogModel.browserInfo} + + + {auditLogModel.comments} + + + {} + + + {auditLogModel?.extraProperties ? JSON.stringify(auditLogModel.extraProperties, null, 2) : ""} + + + + + {auditLogModel?.actions && auditLogModel.actions.length > 0 && ( + +
+ + )} + + {auditLogModel.entityChanges && auditLogModel.entityChanges?.length > 0 && ( + + + + )} + + + ); +}; + +export default AuditLogDrawer; diff --git a/apps/react-admin/src/pages/management/audit-logs/audit-log-table.tsx b/apps/react-admin/src/pages/management/audit-logs/audit-log-table.tsx new file mode 100644 index 000000000..330660a7b --- /dev/null +++ b/apps/react-admin/src/pages/management/audit-logs/audit-log-table.tsx @@ -0,0 +1,318 @@ +import type React from "react"; +import { useRef, useState } from "react"; +import { Button, Tag, Space, Card, Checkbox, type FormInstance, Tooltip } from "antd"; +import { EditOutlined, DeleteOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import ProTable, { type ProColumns, type ActionType } from "@ant-design/pro-table"; +import { useMutation, useQueryClient } from "@tanstack/react-query"; +import { formatToDateTime } from "@/utils/abp"; +import type { AuditLogDto } from "#/management/auditing/audit-logs"; +import { deleteApi, getPagedListApi } from "@/api/management/auditing/audit-logs"; +import { httpMethodOptions, httpStatusCodeOptions } from "./mapping"; +import AuditLogDrawer from "./audit-log-drawer"; +import { hasAccessByCodes, withAccessChecker } from "@/utils/abp/access-checker"; +import { AuditLogPermissions } from "@/constants/management/auditing/permissions"; +import { useAuditLogs } from "@/hooks/abp/auditing/use-audit-logs"; +import { antdOrderToAbpOrder } from "@/utils/abp/sort-order"; +import { toast } from "sonner"; +import DeleteModal from "@/components/abp/common/delete-modal"; + +const AuditLogTable: React.FC = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const formRef = useRef(); + const queryClient = useQueryClient(); + const [drawerVisible, setDrawerVisible] = useState(false); + const [selectedLog, setSelectedLog] = useState(null); + const [deleteModalVisible, setDeleteModalVisible] = useState(false); + const { getHttpMethodColor, getHttpStatusCodeColor } = useAuditLogs(); + + const openDrawer = (log: AuditLogDto) => { + setSelectedLog(log); + setDrawerVisible(true); + }; + + const closeDrawer = () => { + setDrawerVisible(false); + setSelectedLog(null); + }; + + const { mutateAsync: deleteAuditLog } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["auditLogs"] }); + }, + }); + + const handleDelete = (log: AuditLogDto) => { + setSelectedLog(log); + setDeleteModalVisible(true); + }; + + const confirmDelete = async () => { + if (selectedLog) { + await deleteAuditLog(selectedLog.id); + actionRef.current?.reload(); + setDeleteModalVisible(false); + } + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpAuditLogging.RequestUrl"), + dataIndex: "url", + sorter: true, + colSize: 2, + order: 2, + width: 500, + ellipsis: true, + render: (_, record) => ( + <> + onFilter("httpStatusCode", record.httpStatusCode)} // 点击标签触发筛选 + > + {record.httpStatusCode} + + onFilter("httpMethod", record.httpMethod)} + style={{ cursor: "pointer" }} + > + {record.httpMethod} + + + + + + ), + }, + { + title: $t("AbpAuditLogging.UserName"), + dataIndex: "userName", + sorter: true, + width: 120, + }, + { + title: $t("AbpAuditLogging.ExecutionTime"), + dataIndex: "executionTime", + valueType: "dateRange", + sorter: true, + order: 1, + colSize: 2, + width: 150, + render: (_, record) => (record.executionTime ? formatToDateTime(record.executionTime) : record.executionTime), + }, + { + title: $t("AbpAuditLogging.HttpStatusCode"), + dataIndex: "httpStatusCode", + valueType: "select", + fieldProps: { + options: httpStatusCodeOptions, + }, + hideInTable: true, // Only show in search form + }, + { + title: $t("AbpAuditLogging.HttpMethod"), + dataIndex: "httpMethod", + valueType: "select", + fieldProps: { + options: httpMethodOptions, + }, + hideInTable: true, // Only show in search form + }, + { + title: $t("AbpAuditLogging.ExecutionDuration"), + dataIndex: "executionDuration", + sorter: true, + hideInSearch: true, + width: 140, //最长 + }, + { + title: $t("AbpAuditLogging.MinExecutionDuration"), + dataIndex: "minExecutionDuration", + valueType: "digit", + hideInTable: true, + }, + { + title: $t("AbpAuditLogging.MaxExecutionDuration"), + dataIndex: "maxExecutionDuration", + valueType: "digit", + hideInTable: true, + }, + { + title: $t("AbpAuditLogging.ClientId"), + dataIndex: "clientId", + sorter: true, + width: 150, + }, + { + title: $t("AbpAuditLogging.ClientIpAddress"), + dataIndex: "clientIpAddress", + sorter: true, + width: 150, + render: (_, record) => ( + <> + {record.extraProperties?.Location && {record.extraProperties.Location}} + {record.clientIpAddress} + + ), + }, + { + title: $t("AbpAuditLogging.ApplicationName"), + dataIndex: "applicationName", + sorter: true, + ellipsis: true, + width: 160, + }, + { + title: $t("AbpAuditLogging.CorrelationId"), + dataIndex: "correlationId", + sorter: true, + colSize: 2, + width: 160, + }, + { + title: $t("AbpAuditLogging.TenantName"), + dataIndex: "tenantName", + sorter: true, + width: 100, + hideInSearch: true, + }, + { + title: $t("AbpAuditLogging.BrowserInfo"), + dataIndex: "browserInfo", + sorter: true, + ellipsis: true, + width: 300, + hideInSearch: true, + }, + { + title: $t("AbpAuditLogging.HasException"), + dataIndex: "hasException", + valueType: "checkbox", + hideInTable: true, + renderFormItem: (_) => { + return ( + { + const value = e.target.checked; // 获取 Checkbox 的选中状态 + onFilter("hasException", value, false); + }} + /> + ); + }, + }, + hasAccessByCodes([AuditLogPermissions.Default, AuditLogPermissions.Delete]) + ? { + title: $t("AbpUi.Actions"), + key: "actions", + align: "center", + fixed: "right", + hideInSearch: true, + width: 220, + render: (_, record) => ( +
+ {withAccessChecker( + , + [AuditLogPermissions.Default], + )} + {withAccessChecker( + , + [AuditLogPermissions.Delete], + )} +
+ ), + } + : {}, + ]; + + const onFilter = (field: string, value: any, shouldSubmit = true) => { + // 使用 formRef 更新查询条件 + if (formRef.current) { + formRef.current.setFieldsValue({ + [field]: value, + }); + } + if (shouldSubmit) { + // 触发表格刷新 + formRef.current?.submit(); + } + }; + + return ( + <> + + + + headerTitle={$t("AbpAuditLogging.AuditLog")} + actionRef={actionRef} + formRef={formRef} //search form + rowKey="id" + columns={columns} + request={async (params, sorter) => { + const { current, pageSize, executionTime, ...filters } = params; + const [startTime, endTime] = executionTime || []; + const query = await queryClient.fetchQuery({ + //不用换,这样与antd结合比较好用 + queryKey: ["auditLogs", params, sorter], + queryFn: () => + getPagedListApi({ + maxResultCount: pageSize, + skipCount: ((current || 1) - 1) * (pageSize || 0), + sorting: sorter + ? Object.keys(sorter) + .map((key) => `${key} ${antdOrderToAbpOrder(sorter[key])}`) + .join(", ") + : undefined, + startTime: startTime || undefined, + endTime: endTime || undefined, + ...filters, + }), + }); + return { + data: query.items, + total: query.totalCount, + }; + }} + pagination={{ + showSizeChanger: true, + }} + search={{ + labelWidth: "auto", + defaultCollapsed: true, + }} + scroll={{ x: "max-content" }} + /> + + + {selectedLog && } + setDeleteModalVisible(false)} + /> + + ); +}; + +export default AuditLogTable; diff --git a/apps/react-admin/src/pages/management/audit-logs/mapping.ts b/apps/react-admin/src/pages/management/audit-logs/mapping.ts new file mode 100644 index 000000000..ab24aff3c --- /dev/null +++ b/apps/react-admin/src/pages/management/audit-logs/mapping.ts @@ -0,0 +1,57 @@ +const httpMethodOptions = [ + { label: "GET", value: "GET" }, + { label: "PUT", value: "PUT" }, + { label: "POST", value: "POST" }, + { label: "PATCH", value: "PATCH" }, + { label: "DELETE", value: "DELETE" }, + { label: "OPTIONS", value: "OPTIONS" }, + { label: "HEAD", value: "HEAD" }, +]; + +const httpStatusCodeOptions = [ + { label: "100 - Continue", value: 100 }, + { label: "101 - Switching Protocols", value: 101 }, + { label: "200 - OK", value: 200 }, + { label: "201 - Created", value: 201 }, + { label: "202 - Accepted", value: 202 }, + { label: "203 - Non Authoritative Information", value: 203 }, + { label: "204 - No Content", value: 204 }, + { label: "205 - Reset Content", value: 205 }, + { label: "206 - Partial Content", value: 206 }, + { label: "300 - Multiple Choices", value: 300 }, + { label: "301 - Moved Permanently", value: 301 }, + { label: "302 - Found & Redirect", value: 302 }, + { label: "303 - See Other", value: 303 }, + { label: "304 - Not Modified", value: 304 }, + { label: "305 - Use Proxy", value: 305 }, + { label: "306 - Switch Proxy", value: 306 }, + { label: "307 - Temporary Redirect", value: 307 }, + { label: "308 - Permanent Redirect", value: 308 }, + { label: "400 - Bad Request", value: 400 }, + { label: "401 - Unauthorized", value: 401 }, + { label: "402 - Payment Required", value: 402 }, + { label: "403 - Forbidden", value: 403 }, + { label: "404 - Not Found", value: 404 }, + { label: "405 - Method Not Allowed", value: 405 }, + { label: "406 - Not Acceptable", value: 406 }, + { label: "407 - Proxy Authentication Required", value: 407 }, + { label: "408 - Request Timeout", value: 408 }, + { label: "409 - Conflict", value: 409 }, + { label: "410 - Gone", value: 410 }, + { label: "411 - Length Required", value: 411 }, + { label: "412 - Precondition Failed", value: 412 }, + { label: "413 - Request Entity Too Large", value: 413 }, + { label: "414 - Request Uri Too Long", value: 414 }, + { label: "415 - Unsupported Media Type", value: 415 }, + { label: "416 - Requested Range Not Satisfiable", value: 416 }, + { label: "417 - Expectation Failed", value: 417 }, + { label: "426 - Upgrade Required", value: 426 }, + { label: "500 - Internal Server Error", value: 500 }, + { label: "501 - Not mplemented", value: 501 }, + { label: "502 - Bad Gateway", value: 502 }, + { label: "503 - Service Unavailable", value: 503 }, + { label: "504 - Gateway Timeout", value: 504 }, + { label: "505 - Http Version Not Supported", value: 505 }, +]; + +export { httpMethodOptions, httpStatusCodeOptions }; diff --git a/apps/react-admin/src/pages/management/blog/index.tsx b/apps/react-admin/src/pages/management/blog/index.tsx new file mode 100644 index 000000000..dbc726530 --- /dev/null +++ b/apps/react-admin/src/pages/management/blog/index.tsx @@ -0,0 +1,5 @@ +function Blog() { + return
Blog
; +} + +export default Blog; diff --git a/apps/react-admin/src/pages/management/identity/claim-types/claim-type-modal.tsx b/apps/react-admin/src/pages/management/identity/claim-types/claim-type-modal.tsx new file mode 100644 index 000000000..bc0549b00 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/claim-types/claim-type-modal.tsx @@ -0,0 +1,119 @@ +import type React from "react"; +import { useEffect } from "react"; +import { Button, Checkbox, Form, Input, Modal, Select, Space } from "antd"; +import { toast } from "sonner"; +import { useTranslation } from "react-i18next"; +import { ValueType, type IdentityClaimTypeDto } from "#/management/identity"; +import { createApi, updateApi } from "@/api/management/identity/claim-types"; +import { useMutation } from "@tanstack/react-query"; + +interface Props { + visible: boolean; + onClose: () => void; + onSuccess: () => void; + claimType?: IdentityClaimTypeDto; +} + +const ClaimTypeModal: React.FC = ({ visible, onClose, onSuccess, claimType }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + + const { mutateAsync: createClaimType, isPending: isCreating } = useMutation({ + mutationFn: createApi, + onSuccess: () => { + toast.success($t("AbpUi.CreatedSuccessfully")); + onSuccess(); + onClose(); + }, + onError: () => { + toast.error($t("AbpUi.Error")); + }, + }); + + const { mutateAsync: updateClaimType, isPending: isUpdating } = useMutation({ + mutationFn: ({ id, data }: { id: string; data: IdentityClaimTypeDto }) => updateApi(id, data), + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + onSuccess(); + onClose(); + }, + onError: () => { + toast.error($t("AbpUi.Error")); + }, + }); + + const handleSave = async () => { + try { + const values = await form.validateFields(); + if (claimType?.id) { + await updateClaimType({ id: claimType.id, data: values }); + } else { + await createClaimType(values); + } + } catch (error) { + // Form validation error, no need to handle + } + }; + + useEffect(() => { + if (visible && claimType) { + form.setFieldsValue(claimType); + } else { + form.resetFields(); + } + }, [visible, claimType, form]); + + return ( + +
+ + + + + {$t("AbpIdentity.IdentityClaim:Required")} + + + + + + + + + + + + + + + +
+ ); +}; + +export default OrganizationUnitModal; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-page.tsx b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-page.tsx new file mode 100644 index 000000000..321678241 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-page.tsx @@ -0,0 +1,20 @@ +import { useState } from "react"; +import OrganizationUnitTree from "./organization-unit-tree"; +import OrganizationUnitTable from "./organization-unit-table"; + +const OrganizationUnitPage = () => { + const [selectedKey, setSelectedKey] = useState(); + + return ( +
+
+ +
+
+ +
+
+ ); +}; + +export default OrganizationUnitPage; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-role-table.tsx b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-role-table.tsx new file mode 100644 index 000000000..a90096d56 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-role-table.tsx @@ -0,0 +1,141 @@ +import { useRef, useState } from "react"; +import { Button, Card, Modal } from "antd"; +import { DeleteOutlined, PlusOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import type { IdentityRoleDto } from "#/management/identity/role"; +import { ProTable, type ActionType, type ProColumns } from "@ant-design/pro-table"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { OrganizationUnitPermissions } from "@/constants/management/identity/permissions"; +import SelectRoleModal from "./select-role-modal"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import { removeOrganizationUnitApi } from "@/api/management/identity/role"; +import { addRoles, getRoleListApi } from "@/api/management/identity/organization-units"; +import { toast } from "sonner"; + +interface Props { + selectedKey?: string; +} + +const OrganizationUnitRoleTable: React.FC = ({ selectedKey }) => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const queryClient = useQueryClient(); + const [modal, contextHolder] = Modal.useModal(); + const [roleModalVisible, setRoleModalVisible] = useState(false); + + // 获取角色列表 + const { data, isLoading, refetch } = useQuery({ + queryKey: ["organizationUnitRoles", selectedKey], + queryFn: () => { + if (!selectedKey) { + return Promise.reject(new Error("selectedKey is undefined")); + } + return getRoleListApi(selectedKey, { filter: "" }); + }, + enabled: !!selectedKey, + }); + + // 添加角色 + const { mutateAsync: addRolesToUnit } = useMutation({ + mutationFn: (roles: IdentityRoleDto[]) => { + if (!selectedKey) { + return Promise.reject(new Error("selectedKey is undefined")); + } + return addRoles(selectedKey, { + roleIds: roles.map((role) => role.id), + }); + }, + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + setRoleModalVisible(false); + refetch(); + + actionRef.current?.reload(); + }, + }); + + // 移除角色 + const { mutateAsync: removeRole } = useMutation({ + mutationFn: (roleId: string) => { + if (!selectedKey) { + return Promise.reject(new Error("selectedKey is undefined")); + } + return removeOrganizationUnitApi(roleId, selectedKey); + }, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + refetch(); + actionRef.current?.reload(); + }, + }); + + const handleDelete = (role: IdentityRoleDto) => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpIdentity.OrganizationUnit:AreYouSureRemoveRole", { 0: role.name }), + onOk: () => removeRole(role.id), + }); + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpIdentity.DisplayName:RoleName"), + dataIndex: "name", + width: 200, + }, + { + title: $t("AbpUi.Actions"), + width: 180, + fixed: "right", + render: (_, record) => ( + + ), + }, + ]; + + return ( + <> + {contextHolder} + + + headerTitle={$t("AbpIdentity.Roles")} + actionRef={actionRef} + columns={columns} + dataSource={data?.items} + loading={isLoading} + rowKey="id" + search={false} + pagination={{ + showSizeChanger: true, + total: data?.totalCount, + }} + toolBarRender={() => [ + selectedKey && hasAccessByCodes([OrganizationUnitPermissions.ManageRoles]) && ( + + ), + ]} + /> + + {selectedKey && ( + setRoleModalVisible(false)} + onConfirm={addRolesToUnit} + organizationUnitId={selectedKey} + /> + )} + + ); +}; + +export default OrganizationUnitRoleTable; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-table.tsx b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-table.tsx new file mode 100644 index 000000000..1ed8e2fec --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-table.tsx @@ -0,0 +1,32 @@ +import { useState } from "react"; +import { Card, Tabs } from "antd"; +import { useTranslation } from "react-i18next"; +import OrganizationUnitRoleTable from "./organization-unit-role-table"; +import OrganizationUnitUserTable from "./organization-unit-user-table"; + +interface Props { + selectedKey?: string; +} + +type TabKeys = "users" | "roles"; + +const OrganizationUnitTable: React.FC = ({ selectedKey }) => { + const { t: $t } = useTranslation(); + const [activeTab, setActiveTab] = useState("users"); + + return ( + + setActiveTab(key as TabKeys)}> + + + + {activeTab === "users" ? ( + + ) : ( + + )} + + ); +}; + +export default OrganizationUnitTable; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-tree.tsx b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-tree.tsx new file mode 100644 index 000000000..73d02d35e --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-tree.tsx @@ -0,0 +1,260 @@ +import { useEffect, useState } from "react"; +import { Card, Button, Tree, Dropdown, Modal } from "antd"; +import { EditOutlined, DeleteOutlined, PlusOutlined, RedoOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import type { DataNode } from "antd/lib/tree"; +import { useMutation, useQuery } from "@tanstack/react-query"; +import { deleteApi, getChildrenApi, getRootListApi, moveTo } from "@/api/management/identity/organization-units"; +import { Iconify } from "@/components/icon"; +import { toast } from "sonner"; +import OrganizationUnitModal from "./organization-unit-modal"; +import PermissionModal from "@/components/abp/permissions/permission-modal"; + +interface Props { + onSelected?: (id?: string) => void; +} + +const OrganizationUnitTree: React.FC = ({ onSelected }) => { + const { t: $t } = useTranslation(); + // const queryClient = useQueryClient(); // + const [modal, contextHolder] = Modal.useModal(); + + const [organizationUnits, setOrganizationUnits] = useState([]); + const [loadedKeys, setLoadedKeys] = useState([]); + const [selectedKey, setSelectedKey] = useState(); + + // Modal states + const [editModalVisible, setEditModalVisible] = useState(false); + const [permissionModalVisible, setPermissionModalVisible] = useState(false); + const [selectedUnit, setSelectedUnit] = useState<{ id?: string; parentId?: string }>(); + + // 获取根节点列表 + const { refetch: refreshTree } = useQuery({ + queryKey: ["organizationUnits", "root"], + queryFn: async () => { + const { items } = await getRootListApi(); + setOrganizationUnits( + items.map((item) => ({ + isLeaf: false, + key: item.id, + title: item.displayName, + children: [], + })), + ); + setLoadedKeys([]); + return items; + }, + }); + + // 移动节点 + const { mutateAsync: moveNode } = useMutation({ + mutationFn: ({ id, parentId }: { id: string; parentId?: string }) => moveTo(id, parentId), + onSuccess: () => { + refreshTree(); + }, + }); + + // 删除节点 + const { mutateAsync: deleteNode } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + refreshTree(); + }, + }); + + const updateTreeData = (list: DataNode[], key: React.Key, children: DataNode[]): DataNode[] => { + return list.map((node) => { + if (node.key === key) { + return { + ...node, + children, // 更新子节点 + }; + } + if (node.children) { + return { + ...node, + children: updateTreeData(node.children, key, children), // 递归更新子节点 + }; + } + return node; + }); + }; + const findNodeById = (nodes: DataNode[], id?: string): DataNode | undefined => { + if (!id) return undefined; + + for (const node of nodes) { + if (node.key === id) return node; + if (node.children) { + const found = findNodeById(node.children, id); + if (found) return found; + } + } + return undefined; + }; + useEffect(() => { + onSelected?.(selectedKey); + }, [selectedKey]); + + const handleMenuClick = async (key: string, id: string) => { + switch (key) { + case "create": + setSelectedUnit({ parentId: id }); + setEditModalVisible(true); + break; + case "update": + setSelectedUnit({ id }); + setEditModalVisible(true); + break; + case "permissions": + // const unit = await getApi(id); + setSelectedUnit({ id }); + setPermissionModalVisible(true); + break; + case "delete": + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpUi.ItemWillBeDeletedMessage"), + onOk: () => deleteNode(id), + }); + break; + case "refresh": + refreshTree(); + break; + } + }; + + const menuItems = [ + { + key: "update", + icon: , + label: $t("AbpUi.Edit"), + }, + { + key: "create", + icon: , + label: $t("AbpIdentity.OrganizationUnit:AddChildren"), + }, + { + key: "delete", + icon: , + label: $t("AbpUi.Delete"), + }, + { + key: "permissions", + icon: , + label: $t("AbpPermissionManagement.Permissions"), + }, + { + key: "refresh", + icon: , + label: $t("AbpIdentity.OrganizationUnit:RefreshRoot"), + }, + ]; + + return ( + <> + {contextHolder} + } + onClick={() => { + setSelectedUnit({}); + setEditModalVisible(true); + }} + > + {$t("AbpIdentity.OrganizationUnit:AddRoot")} + + } + > + { + // 加载子节点 + const nodeKey = String(node.key); + const { items } = await getChildrenApi({ id: nodeKey }); + node.isLeaf = items.length === 0; + node.children = items.map((item): DataNode => { + return { + isLeaf: false, + key: item.id, + title: item.displayName, + children: [], + }; + }); + setOrganizationUnits((prevUnits) => updateTreeData(prevUnits, nodeKey, node.children || [])); + + setLoadedKeys((prev) => [...prev, String(node.key)]); + }} + loadedKeys={loadedKeys} + treeData={organizationUnits} + blockNode + draggable + onDrop={(info) => { + if (!info.dragNode.key) return; + const dragKey = String(info.dragNode.key); + const dropKey = + info.dropPosition === -1 + ? undefined // 作为根节点 + : String(info.node.key); // 作为子节点 + moveNode({ id: dragKey, parentId: dropKey }); + }} + onRightClick={(_) => {}} + onSelect={(selectedKeys) => { + if (selectedKeys.length === 0) { + setSelectedKey(undefined); + return; + } + setSelectedKey(String(selectedKeys[0])); + }} + titleRender={(nodeData) => ( + handleMenuClick(key, String(nodeData.key)), + }} + > +
+ {String(nodeData.title)} + + + +
+
+ )} + /> +
+ { + setEditModalVisible(false); + setSelectedUnit(undefined); + }} + onChange={() => { + refreshTree(); + }} + /> + + { + setPermissionModalVisible(false); + setSelectedUnit(undefined); + }} + onChange={() => { + refreshTree(); + }} + /> + + ); +}; + +export default OrganizationUnitTree; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-user-table.tsx b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-user-table.tsx new file mode 100644 index 000000000..c927b3a4a --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/organization-unit-user-table.tsx @@ -0,0 +1,142 @@ +import { useRef, useState } from "react"; +import { Button, Card, Modal } from "antd"; +import { DeleteOutlined, PlusOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import type { IdentityUserDto } from "#/management/identity"; +import { ProTable, type ActionType, type ProColumns } from "@ant-design/pro-table"; +import { useMutation, useQuery } from "@tanstack/react-query"; +import { addMembers, getUserListApi } from "@/api/management/identity/organization-units"; +import { removeOrganizationUnitApi } from "@/api/management/identity/users"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { OrganizationUnitPermissions } from "@/constants/management/identity/permissions"; +import SelectMemberModal from "./select-member-modal"; +import { toast } from "sonner"; + +interface Props { + selectedKey?: string; +} + +const OrganizationUnitUserTable: React.FC = ({ selectedKey }) => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const [modal, contextHolder] = Modal.useModal(); + const [memberModalVisible, setMemberModalVisible] = useState(false); + + // 获取用户列表 + const { data, isLoading, refetch } = useQuery({ + queryKey: ["organizationUnitUsers", selectedKey], + queryFn: () => { + if (!selectedKey) { + return Promise.reject(new Error("selectedKey is undefined")); + } + return getUserListApi(selectedKey, {}); + }, + enabled: !!selectedKey, + }); + + // 添加成员 + const { mutateAsync: addUsers } = useMutation({ + mutationFn: (users: IdentityUserDto[]) => { + if (!selectedKey) { + return Promise.reject(new Error("selectedKey is undefined")); + } + return addMembers(selectedKey, { userIds: users.map((u) => u.id) }); + }, + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + refetch(); + actionRef.current?.reload(); + setMemberModalVisible(false); + }, + }); + + // 移除成员 + const { mutateAsync: removeUser } = useMutation({ + mutationFn: (userId: string) => { + if (!selectedKey) { + return Promise.reject(new Error("selectedKey is undefined")); + } + return removeOrganizationUnitApi(userId, selectedKey); + }, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + refetch(); + actionRef.current?.reload(); + }, + }); + + const columns: ProColumns[] = [ + { + title: $t("AbpIdentity.DisplayName:UserName"), + dataIndex: "userName", + width: 100, + }, + { + title: $t("AbpIdentity.DisplayName:Email"), + dataIndex: "email", + width: 120, + }, + { + title: $t("AbpUi.Actions"), + width: 120, + fixed: "right", + render: (_, record) => ( + + ), + }, + ]; + + const getAddMemberEnabled = selectedKey && hasAccessByCodes([OrganizationUnitPermissions.ManageUsers]); + + return ( + <> + {contextHolder} + + + headerTitle={$t("AbpIdentity.Users")} + actionRef={actionRef} + rowKey="id" + columns={columns} + dataSource={data?.items} + loading={isLoading} + search={false} + pagination={{ + showSizeChanger: true, + total: data?.totalCount, + }} + toolBarRender={() => [ + getAddMemberEnabled && ( + + ), + ]} + /> + + {selectedKey && ( + setMemberModalVisible(false)} + onConfirm={addUsers} + organizationUnitId={selectedKey} + /> + )} + + ); +}; + +export default OrganizationUnitUserTable; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/select-member-modal.tsx b/apps/react-admin/src/pages/management/identity/organization-units/select-member-modal.tsx new file mode 100644 index 000000000..997789c18 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/select-member-modal.tsx @@ -0,0 +1,83 @@ +import { useState } from "react"; +import { Modal } from "antd"; +import { useTranslation } from "react-i18next"; +import type { IdentityUserDto } from "#/management/identity"; +import { ProTable, type ProColumns } from "@ant-design/pro-table"; +import { useQuery } from "@tanstack/react-query"; +import { getUnaddedUserListApi } from "@/api/management/identity/organization-units"; + +interface Props { + visible: boolean; + onClose: () => void; + onConfirm: (users: IdentityUserDto[]) => void; + organizationUnitId: string; +} + +const SelectMemberModal: React.FC = ({ visible, onClose, onConfirm, organizationUnitId }) => { + const { t: $t } = useTranslation(); + const [selectedUsers, setSelectedUsers] = useState([]); + const [searchParams, setSearchParams] = useState<{ filter?: string }>({}); + + // 获取可添加的用户列表 + const { data, isLoading } = useQuery({ + queryKey: ["organizationUnitUsers", "unAdded", organizationUnitId, searchParams], + queryFn: () => + getUnaddedUserListApi({ + id: organizationUnitId, + ...searchParams, + }), + enabled: visible, + }); + + const columns: ProColumns[] = [ + { + title: $t("AbpIdentity.DisplayName:UserName"), + dataIndex: "userName", + width: 100, + }, + { + title: $t("AbpIdentity.DisplayName:Email"), + dataIndex: "email", + width: 120, + }, + ]; + + return ( + onConfirm(selectedUsers)} + width="800px" + > + + rowKey="id" + columns={columns} + dataSource={data?.items} + loading={isLoading} + rowSelection={{ + selections: true, + onChange: (_, rows) => setSelectedUsers(rows), + }} + search={{ + labelWidth: "auto", + span: 12, + }} + request={async (params) => { + setSearchParams({ filter: params.filter }); + return { + data: data?.items, + success: true, + total: data?.totalCount, + }; + }} + pagination={{ + showSizeChanger: true, + total: data?.totalCount, + }} + /> + + ); +}; + +export default SelectMemberModal; diff --git a/apps/react-admin/src/pages/management/identity/organization-units/select-role-modal.tsx b/apps/react-admin/src/pages/management/identity/organization-units/select-role-modal.tsx new file mode 100644 index 000000000..8e971e6da --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/organization-units/select-role-modal.tsx @@ -0,0 +1,65 @@ +import { useState } from "react"; +import { Modal, Table } from "antd"; +import { useTranslation } from "react-i18next"; +import type { IdentityRoleDto } from "#/management/identity/role"; +import { useQuery } from "@tanstack/react-query"; +import { getUnaddedRoleListApi } from "@/api/management/identity/organization-units"; + +interface Props { + visible: boolean; + onClose: () => void; + onConfirm: (roles: IdentityRoleDto[]) => void; + organizationUnitId: string; +} + +const SelectRoleModal: React.FC = ({ visible, onClose, onConfirm, organizationUnitId }) => { + const { t: $t } = useTranslation(); + const [selectedRoles, setSelectedRoles] = useState([]); + const [searchParams, setSearchParams] = useState<{ filter?: string }>({}); + + // 获取可添加的角色列表 + const { data, isLoading } = useQuery({ + queryKey: ["organizationUnitRoles", "unAdded", organizationUnitId, searchParams], + queryFn: () => + getUnaddedRoleListApi({ + id: organizationUnitId, + ...searchParams, + }), + enabled: visible, + }); + + const columns = [ + { + title: $t("AbpIdentity.DisplayName:RoleName"), + dataIndex: "name", + width: 200, + }, + ]; + + return ( + onConfirm(selectedRoles)} + width="800px" + > +
setSelectedRoles(rows), + }} + pagination={{ + total: data?.totalCount, + showSizeChanger: true, + }} + /> + + ); +}; + +export default SelectRoleModal; diff --git a/apps/react-admin/src/pages/management/identity/roles/role-claim-modal.tsx b/apps/react-admin/src/pages/management/identity/roles/role-claim-modal.tsx new file mode 100644 index 000000000..dd10eac5f --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/roles/role-claim-modal.tsx @@ -0,0 +1,72 @@ +import type React from "react"; +import { Modal } from "antd"; +import { useTranslation } from "react-i18next"; +import type { IdentityRoleDto } from "#/management/identity"; +import type { + IdentityClaimCreateDto, + IdentityClaimDeleteDto, + IdentityClaimUpdateDto, +} from "#/management/identity/claims"; +import { useMutation, useQueryClient } from "@tanstack/react-query"; +import { createClaimApi, deleteClaimApi, getClaimsApi, updateClaimApi } from "@/api/management/identity/role"; +import { IdentityRolePermissions } from "@/constants/management/identity/permissions"; +import ClaimTable from "@/components/abp/claims/claim-table"; + +interface Props { + visible: boolean; + onClose: () => void; + role: IdentityRoleDto; +} + +//TODO on change 结合测试配置的role的claims和其它calims获取的地方 +const RoleClaimModal: React.FC = ({ visible, onClose, role }) => { + const { t: $t } = useTranslation(); + const queryClient = useQueryClient(); + const queryKey = ["roleClaims", role.id]; + + // Mutations for CRUD operations + const { mutateAsync: createClaim } = useMutation({ + mutationFn: (input: IdentityClaimCreateDto) => createClaimApi(role.id, input), + onSuccess: () => { + queryClient.invalidateQueries({ queryKey }); + }, + }); + + const { mutateAsync: updateClaim } = useMutation({ + mutationFn: (input: IdentityClaimUpdateDto) => updateClaimApi(role.id, input), + onSuccess: () => { + queryClient.invalidateQueries({ queryKey }); + }, + }); + + const { mutateAsync: deleteClaim } = useMutation({ + mutationFn: (input: IdentityClaimDeleteDto) => deleteClaimApi(role.id, input), + onSuccess: () => { + queryClient.invalidateQueries({ queryKey }); + }, + }); + + return ( + + getClaimsApi(role.id)} + queryKey={queryKey} + /> + + ); +}; + +export default RoleClaimModal; diff --git a/apps/react-admin/src/pages/management/identity/roles/role-modal.tsx b/apps/react-admin/src/pages/management/identity/roles/role-modal.tsx new file mode 100644 index 000000000..d1b3cbdd7 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/roles/role-modal.tsx @@ -0,0 +1,103 @@ +import type React from "react"; +import { useEffect } from "react"; +import { Modal, Form, Input, Checkbox } from "antd"; +import { useTranslation } from "react-i18next"; +import type { IdentityRoleDto } from "#/management/identity"; +import { useQuery, useMutation, useQueryClient } from "@tanstack/react-query"; +import { createApi, getApi, updateApi } from "@/api/management/identity/role"; +import { toast } from "sonner"; + +interface Props { + visible: boolean; + onClose: () => void; + onChange: () => void; + role?: IdentityRoleDto; +} + +const defaultModel: Partial = { + isDefault: false, + isPublic: true, + isStatic: false, +}; + +const RoleModal: React.FC = ({ visible, onClose, onChange, role }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + const queryClient = useQueryClient(); + // Query for getting role details + const { data: roleData, isLoading: isLoadingRole } = useQuery({ + queryKey: ["role", role?.id], + queryFn: () => { + if (!role?.id) { + return Promise.reject(new Error("role id is undefined")); + } + return getApi(role.id); + }, + enabled: visible && !!role?.id, + }); + + // Mutations for create/update + const { mutateAsync: createRole, isPending: isCreating } = useMutation({ + mutationFn: createApi, + onSuccess: (_) => { + onChange(); + toast.success($t("AbpUi.CreatedSuccessfully")); + onClose(); + }, + }); + + const { mutateAsync: updateRole, isPending: isUpdating } = useMutation({ + mutationFn: ({ id, data }: { id: string; data: IdentityRoleDto }) => updateApi(id, data), + onSuccess: (_) => { + onChange(); + queryClient.invalidateQueries({ queryKey: ["role", role?.id] }); + toast.success($t("AbpUi.SavedSuccessfully")); + onClose(); + }, + }); + + useEffect(() => { + if (visible) { + form.setFieldsValue(role?.id ? (roleData ?? role) : defaultModel); + } else { + form.resetFields(); + } + }, [visible, roleData, role]); + + const handleOk = async () => { + try { + const values = await form.validateFields(); + if (role?.id) { + await updateRole({ id: role.id, data: values }); + } else { + await createRole(values); + } + } catch (error) { + // Form validation error, no need to handle + } + }; + + return ( + +
+ + {$t("AbpIdentity.DisplayName:IsDefault")} + + + {$t("AbpIdentity.DisplayName:IsPublic")} + + + + + +
+ ); +}; + +export default RoleModal; diff --git a/apps/react-admin/src/pages/management/identity/roles/role-table.tsx b/apps/react-admin/src/pages/management/identity/roles/role-table.tsx new file mode 100644 index 000000000..0d0dce368 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/roles/role-table.tsx @@ -0,0 +1,252 @@ +import { useRef, useState } from "react"; +import { Button, Dropdown, Modal, Tag, Space, Card } from "antd"; +import { EditOutlined, DeleteOutlined, EllipsisOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import type { IdentityRoleDto } from "#/management/identity/role"; +import { type ActionType, ProTable, type ProColumns } from "@ant-design/pro-table"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { deleteApi, getPagedListApi } from "@/api/management/identity/role"; +import RoleModal from "./role-modal"; +import RoleClaimModal from "./role-claim-modal"; +import PermissionModal from "@/components/abp/permissions/permission-modal"; +import { toast } from "sonner"; +import { Iconify } from "@/components/icon"; +import useAbpStore from "@/store/abpCoreStore"; +import { IdentityRolePermissions } from "@/constants/management/identity/permissions"; +import { AuditLogPermissions } from "@/constants/management/auditing/permissions"; +import { EntityChangeDrawer } from "@/components/abp/auditing/entity-change-drawer"; + +const RoleTable: React.FC = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const queryClient = useQueryClient(); + const abpStore = useAbpStore(); + const [modal, contextHolder] = Modal.useModal(); + // Modal states + const [roleModalVisible, setRoleModalVisible] = useState(false); + const [claimModalVisible, setClaimModalVisible] = useState(false); + const [permissionModalVisible, setPermissionModalVisible] = useState(false); + const [entityChangeDrawerVisible, setEntityChangeDrawerVisible] = useState(false); + const [selectedRole, setSelectedRole] = useState(); + const [searchParams, setSearchParams] = useState<{ filter?: string }>({}); + + // 获取角色列表 + const { data, isLoading } = useQuery({ + queryKey: ["roles", searchParams], + queryFn: () => getPagedListApi(searchParams), + }); + + // 删除角色 + const { mutateAsync: deleteRole } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["roles"] }); + }, + }); + + const handleDelete = (role: IdentityRoleDto) => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpIdentity.RoleDeletionConfirmationMessage", { 0: role.name }), + onOk: () => deleteRole(role.id), + }); + }; + + const handleMenuClick = (key: string, role: IdentityRoleDto) => { + setSelectedRole(role); + switch (key) { + case "permissions": + setPermissionModalVisible(true); + break; + case "claims": + setClaimModalVisible(true); + break; + case "entity-changes": + setEntityChangeDrawerVisible(true); + break; + } + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpUi.Search"), + dataIndex: "filter", + valueType: "text", + hideInTable: true, + }, + { + title: $t("AbpIdentity.DisplayName:RoleName"), + dataIndex: "name", + render: (_, record) => ( + + {record.isStatic && {$t("AbpIdentity.Static")}} + {record.isDefault && {$t("AbpIdentity.DisplayName:IsDefault")}} + {record.isPublic && {$t("AbpIdentity.Public")}} + {record.name} + + ), + hideInSearch: true, + }, + { + title: $t("AbpUi.Actions"), + width: 220, + fixed: "right", + hideInSearch: true, + render: (_, record) => ( +
+
+ {hasAccessByCodes([IdentityRolePermissions.Update]) && ( + + )} +
+
+ {hasAccessByCodes([IdentityRolePermissions.Delete]) && !record.isStatic && ( + + )} +
+
+ , + label: $t("AbpPermissionManagement.Permissions"), + } + : null, + hasAccessByCodes([IdentityRolePermissions.ManageClaims]) + ? { + key: "claims", + icon: , + label: $t("AbpIdentity.ManageClaim"), + } + : null, + hasAccessByCodes([AuditLogPermissions.Default]) + ? { + key: "entity-changes", + icon: , + label: $t("AbpAuditLogging.EntitiesChanged"), + } + : null, + ].filter(Boolean), + onClick: ({ key }) => handleMenuClick(key as string, record), + }} + > +
+
+ ), + }, + ]; + + return ( + <> + {contextHolder} + + + headerTitle={$t("AbpIdentity.Roles")} + actionRef={actionRef} + rowKey="id" + columns={columns} + dataSource={data?.items} + loading={isLoading} + search={{ + labelWidth: "auto", + span: 12, + defaultCollapsed: true, + }} + pagination={{ + showSizeChanger: true, + total: data?.totalCount, + }} + request={async (params) => { + const { filter } = params; + setSearchParams({ filter }); + // 强制重新请求数据 + await queryClient.invalidateQueries({ queryKey: ["roles"] }); + return { data: data?.items, success: true, total: data?.totalCount }; + }} + toolBarRender={() => [ + hasAccessByCodes([IdentityRolePermissions.Create]) && ( + + ), + ]} + /> + + { + setRoleModalVisible(false); + setSelectedRole(undefined); + }} + onChange={() => { + // actionRef.current?.reload(); + queryClient.invalidateQueries({ queryKey: ["roles"] }); + }} + /> + {selectedRole && ( + { + setClaimModalVisible(false); + setSelectedRole(undefined); + }} + // onChange={() => { + // actionRef.current?.reload(); + // }} + /> + )} + { + setPermissionModalVisible(false); + setSelectedRole(undefined); + }} + onChange={() => { + // actionRef.current?.reload(); + queryClient.invalidateQueries({ queryKey: ["roles"] }); + }} + /> + { + setEntityChangeDrawerVisible(false); + setSelectedRole(undefined); + }} + /> + + ); +}; + +export default RoleTable; diff --git a/apps/react-admin/src/pages/management/identity/security-logs/security-log-drawer.tsx b/apps/react-admin/src/pages/management/identity/security-logs/security-log-drawer.tsx new file mode 100644 index 000000000..d0d091972 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/security-logs/security-log-drawer.tsx @@ -0,0 +1,66 @@ +import type React from "react"; +import { Drawer, Descriptions } from "antd"; +import { formatToDateTime } from "@/utils/abp"; +import { useTranslation } from "react-i18next"; +import { useQuery } from "@tanstack/react-query"; +import { getApi } from "@/api/management/identity/security-logs"; + +interface Props { + visible: boolean; + onClose: () => void; + securityLogId?: string; +} + +const SecurityLogDrawer: React.FC = ({ visible, onClose, securityLogId }) => { + const { t: $t } = useTranslation(); + + const { data: formModel, isLoading } = useQuery({ + queryKey: ["securityLog", securityLogId], + queryFn: () => { + if (!securityLogId) { + return Promise.reject(new Error("securityLogId is undefined")); + } + return getApi(securityLogId); + }, + enabled: visible && !!securityLogId, + }); + + return ( + + + + {formModel?.applicationName} + + + {formModel?.creationTime ? formatToDateTime(formModel.creationTime) : ""} + + {formModel?.identity} + {formModel?.tenantName} + {formModel?.action} + {formModel?.correlationId} + {formModel?.userId} + {formModel?.userName} + {formModel?.clientId} + + {formModel?.clientIpAddress} + + + {formModel?.browserInfo} + + + + {formModel?.extraProperties ? JSON.stringify(formModel.extraProperties, null, 2) : ""} + + + + ); +}; + +export default SecurityLogDrawer; diff --git a/apps/react-admin/src/pages/management/identity/security-logs/security-logs-table.tsx b/apps/react-admin/src/pages/management/identity/security-logs/security-logs-table.tsx new file mode 100644 index 000000000..6f76cb866 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/security-logs/security-logs-table.tsx @@ -0,0 +1,220 @@ +import { useRef, useState } from "react"; +import { Space, Button, Tag, Card } from "antd"; +import { useMutation, useQueryClient } from "@tanstack/react-query"; +import ProTable, { type ProColumns, type ActionType } from "@ant-design/pro-table"; +import { EditOutlined, DeleteOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { formatToDateTime } from "@/utils/abp"; +import type { SecurityLogDto } from "#/management/identity"; +import { antdOrderToAbpOrder } from "@/utils/abp/sort-order"; +import { SecurityLogPermissions } from "@/constants/management/identity/permissions"; +import { hasAccessByCodes, withAccessChecker } from "@/utils/abp/access-checker"; +import { toast } from "sonner"; +import SecurityLogDrawer from "./security-log-drawer"; +import { deleteApi, getPagedListApi } from "@/api/management/identity/security-logs"; +import DeleteModal from "@/components/abp/common/delete-modal"; + +const SecurityLogs = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const queryClient = useQueryClient(); + //drawer + const [drawerVisible, setDrawerVisible] = useState(false); + const [selectedLogId, setSelectedLogId] = useState(); + //Modal + const [deleteModalVisible, setDeleteModalVisible] = useState(false); + + const openDrawer = (id: string) => { + setSelectedLogId(id); + setDrawerVisible(true); + }; + + const closeDrawer = () => { + setDrawerVisible(false); + setSelectedLogId(undefined); + }; + + const { mutateAsync: deleteSecurityLog } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["securityLogs"] }); + }, + }); + + const handleDelete = (log: SecurityLogDto) => { + setSelectedLogId(log.id); + setDeleteModalVisible(true); + }; + + const confirmDelete = async () => { + if (selectedLogId) { + await deleteSecurityLog(selectedLogId); + actionRef.current?.reload(); + setDeleteModalVisible(false); + } + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpAuditLogging.CreationTime"), + dataIndex: "creationTime", + valueType: "dateRange", + sorter: true, + width: 180, + render: (_, record) => { + // formatter + return record.creationTime ? formatToDateTime(record.creationTime) : record.creationTime; + }, + }, + { + title: $t("AbpAuditLogging.Identity"), + dataIndex: "identity", + sorter: true, + width: 180, + }, + { + title: $t("AbpAuditLogging.UserName"), + dataIndex: "userName", + sorter: true, + width: 150, + }, + { + title: $t("AbpAuditLogging.ClientId"), + dataIndex: "clientId", + sorter: true, + width: 200, + }, + { + title: $t("AbpAuditLogging.ClientIpAddress"), + dataIndex: "clientIpAddress", + sorter: true, + width: 200, + hideInSearch: true, + render: (_, record) => ( + <> + {/* 展示地址 */} + {record.extraProperties?.Location && {record.extraProperties.Location}} + {record.clientIpAddress} + + ), + }, + { + title: $t("AbpAuditLogging.ApplicationName"), + dataIndex: "applicationName", + sorter: true, + width: 200, + ellipsis: true, + }, + { + title: $t("AbpAuditLogging.TenantName"), + dataIndex: "tenantName", + hideInSearch: true, + sorter: true, + width: 180, + }, + { + title: $t("AbpAuditLogging.Actions"), + dataIndex: "action", + sorter: true, + width: 180, + }, + { + title: $t("AbpAuditLogging.CorrelationId"), + dataIndex: "correlationId", + sorter: true, + width: 200, + }, + { + title: $t("AbpAuditLogging.BrowserInfo"), + dataIndex: "browserInfo", + width: 200, + sorter: true, + hideInSearch: true, + ellipsis: true, + }, + hasAccessByCodes([SecurityLogPermissions.Default, SecurityLogPermissions.Delete]) + ? { + title: $t("AbpUi.Actions"), + key: "actions", + align: "center", + fixed: "right", + hideInSearch: true, + width: 150, + render: (_, record) => ( +
+ {withAccessChecker( + , + [SecurityLogPermissions.Default], + )} + {withAccessChecker( + , + [SecurityLogPermissions.Delete], + )} +
+ ), + } + : {}, + ]; + + return ( + <> + + + + headerTitle={$t("AbpAuditLogging.SecurityLog")} + actionRef={actionRef} + rowKey="id" + search={{ + labelWidth: "auto", + defaultCollapsed: true, + }} + columns={columns} + request={async (params, sorter) => { + const { creationTime, current, pageSize, ...rest } = params; + const [startTime, endTime] = creationTime || []; + + const query = await queryClient.fetchQuery({ + queryKey: ["securityLogs", params, sorter], + queryFn: () => + getPagedListApi({ + maxResultCount: pageSize, + skipCount: ((current || 1) - 1) * (pageSize || 0), + sorting: sorter + ? Object.keys(sorter) + .map((key) => `${key} ${antdOrderToAbpOrder(sorter[key])}`) + .join(", ") + : undefined, + startTime: startTime || undefined, // 转换为 startTime 参数 + endTime: endTime || undefined, // 转换为 endTime 参数 + ...rest, + }), + }); + + return { + data: query.items, + total: query.totalCount, + }; + }} + pagination={{ + showSizeChanger: true, + }} + scroll={{ x: "max-content" }} + /> + + + setDeleteModalVisible(false)} + /> + + + ); +}; + +export default SecurityLogs; diff --git a/apps/react-admin/src/pages/management/identity/sessions/session-table.tsx b/apps/react-admin/src/pages/management/identity/sessions/session-table.tsx new file mode 100644 index 000000000..d18cd166f --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/sessions/session-table.tsx @@ -0,0 +1,189 @@ +import { useRef, useState, useTransition } from "react"; +import { Button, Card, Modal, Select, Space, Tag } from "antd"; +import { DeleteOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { ProTable, type ActionType, type ProColumns } from "@ant-design/pro-table"; +import type { IdentitySessionDto } from "#/management/identity/sessions"; +import type { IdentityUserDto } from "#/management/identity/user"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { IdentitySessionPermissions } from "@/constants/management/identity/permissions"; +import { getPagedListApi as getUserListApi } from "@/api/management/identity/users"; +import { getSessionsApi, revokeSessionApi } from "@/api/management/identity/user-sessions"; +import { useApplication } from "@/store/abpCoreStore"; +import { toast } from "sonner"; + +const SessionTable: React.FC = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const queryClient = useQueryClient(); + const [modal, contextHolder] = Modal.useModal(); + const application = useApplication(); + + const [searchText, setSearchText] = useState(""); + const [isPending, startTransition] = useTransition(); + + // Fetch users for select + const { data: users = [] } = useQuery({ + queryKey: ["users", searchText], + queryFn: () => + getUserListApi({ + maxResultCount: 25, + filter: searchText, + }).then((res) => res.items), + enabled: !isPending, + }); + + // Revoke session mutation + const { mutateAsync: revokeSession } = useMutation({ + mutationFn: revokeSessionApi, + onSuccess: () => { + toast.success($t("AbpIdentity.SuccessfullyRevoked")); + actionRef.current?.reload(); + }, + }); + + const handleDelete = (session: IdentitySessionDto) => { + if (session.sessionId === application?.currentUser.sessionId) return; + + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpIdentity.SessionWillBeRevokedMessage"), + onOk: () => revokeSession(session.sessionId), + }); + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpUi.Search"), + dataIndex: "filter", + hideInTable: true, + }, + { + title: $t("AbpIdentity.DisplayName:UserName"), + dataIndex: "userId", + hideInTable: true, + renderFormItem: () => ( + + + + + ); +}; + +export default UserLockModal; diff --git a/apps/react-admin/src/pages/management/identity/users/user-modal.tsx b/apps/react-admin/src/pages/management/identity/users/user-modal.tsx new file mode 100644 index 000000000..88f3e25fc --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/users/user-modal.tsx @@ -0,0 +1,315 @@ +import { useEffect, useState } from "react"; +import { Modal, Form, Input, Checkbox, Tabs, Transfer, Tree } from "antd"; +import { useTranslation } from "react-i18next"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import type { IdentityUserDto } from "#/management/identity/user"; +import type { DataNode } from "antd/es/tree"; +import type { TransferItem } from "antd/es/transfer"; +import { toast } from "sonner"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { + createApi, + getApi, + updateApi, + getAssignableRolesApi, + getRolesApi, + getOrganizationUnitsApi, +} from "@/api/management/identity/users"; +import { getRootListApi, getChildrenApi } from "@/api/management/identity/organization-units"; +import { useAbpSettings } from "@/hooks/abp/use-abp-settings"; + +interface UserModalProps { + visible: boolean; + userId?: string; + onClose: () => void; + onChange: () => void; +} + +const defaultModel: Partial = { + isActive: true, +}; + +const UserModal: React.FC = ({ visible, userId, onClose, onChange }) => { + const { t: $t } = useTranslation(); + const queryClient = useQueryClient(); + const [form] = Form.useForm(); + const { isTrue } = useAbpSettings(); + + const [activeTab, setActiveTab] = useState("info"); + const [assignedRoles, setAssignedRoles] = useState([]); + const [organizationUnits, setOrganizationUnits] = useState([]); + const [loadedOuKeys, setLoadedOuKeys] = useState([]); + const [checkedOuKeys, setCheckedOuKeys] = useState([]); + const [targetKeys, setTargetKeys] = useState([]); + + // Check policies + const canManageRoles = hasAccessByCodes(["AbpIdentity.Users.Update.ManageRoles"]); + const canManageOu = hasAccessByCodes(["AbpIdentity.Users.ManageOrganizationUnits"]); + + // API mutations + const { mutateAsync: createUser, isPending: isCreating } = useMutation({ + mutationFn: createApi, + onSuccess: () => { + toast.success($t("AbpUi.CreatedSuccessfully")); + onChange(); + onClose(); + queryClient.invalidateQueries({ queryKey: ["users"] }); + }, + }); + + const { mutateAsync: updateUser, isPending: isUpdating } = useMutation({ + mutationFn: (data: IdentityUserDto) => updateApi(data.id, data), + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + onChange(); + onClose(); + queryClient.invalidateQueries({ queryKey: ["users"] }); + queryClient.invalidateQueries({ queryKey: ["userRoles"] }); + queryClient.invalidateQueries({ queryKey: ["assignableRoles"] }); + queryClient.invalidateQueries({ queryKey: ["permissions"] }); //角色更新会带来permission的变化 + }, + }); + + // Fetch user data + const { data: userData } = useQuery({ + queryKey: ["users", userId], + queryFn: () => { + if (!userId) { + return Promise.reject(new Error("userId is undefined")); + } + return getApi(userId); + }, + enabled: visible && !!userId, + }); + + // Fetch roles + const { data: userRoles } = useQuery({ + queryKey: ["userRoles", userId], + queryFn: () => { + if (!userId) { + return Promise.reject(new Error("userId is undefined")); + } + return getRolesApi(userId); + }, + enabled: visible && !!userId && canManageRoles, + }); + + // Fetch assignable roles + const { data: assignableRoles } = useQuery({ + queryKey: ["assignableRoles"], + queryFn: getAssignableRolesApi, + enabled: visible && canManageRoles, + }); + + // Fetch organization units + const { data: userOus } = useQuery({ + queryKey: ["userOus", userId], + queryFn: () => { + if (!userId) { + return Promise.reject(new Error("userId is undefined")); + } + return getOrganizationUnitsApi(userId); + }, + enabled: visible && !!userId && canManageOu, + }); + + const { data: ousRootList } = useQuery({ + queryKey: ["ousRootList"], + queryFn: () => { + if (!userId) { + return Promise.reject(new Error("userId is undefined")); + } + return getRootListApi(); + }, + enabled: visible && !!userId && canManageOu, + }); + + useEffect(() => { + if (visible) { + // Reset states + setActiveTab("info"); + setAssignedRoles([]); + setOrganizationUnits([]); + setLoadedOuKeys([]); + form.resetFields(); + + if (userData) { + // userData.roleNames = userRoles?.items.map((item) => item.name) || []; + form.setFieldsValue(userData); + } else { + form.setFieldsValue(defaultModel); + } + + // Initialize roles + if (assignableRoles) { + setAssignedRoles( + assignableRoles.items.map((item) => ({ + key: item.name, + title: item.name, + ...item, + })), + ); + } + if (userRoles) { + // 初始化 targetKeys + const userRoleNames = userRoles.items.map((item) => item.name); + setTargetKeys(userRoleNames); + form.setFieldValue("roleNames", userRoleNames); + } + + // Initialize organization units + if (userOus && ousRootList) { + //TODO 根据用户的组织关系信息,计算checkedKeys,让用户的父组织们都halfChecked + setOrganizationUnits( + ousRootList.items.map((item) => ({ + isLeaf: false, + key: item.id, + title: item.displayName, + children: [], + })), + ); + setCheckedOuKeys(userOus.items.map((item) => item.id)); + } + } + }, [visible, userData, assignableRoles, userOus]); + + const handleOk = async () => { + try { + const values = await form.validateFields(); + if (userId) { + await updateUser({ ...values, id: userId }); //admin用户更新不了? + } else { + await createUser(values); + } + } catch (error) { + console.error("Validation failed:", error); + } + }; + + // 更新组织机构树结构 + const updateTreeData = (list: DataNode[], key: React.Key, children: DataNode[]): DataNode[] => { + return list.map((node) => { + if (node.key === key) { + return { ...node, children }; + } + if (node.children) { + return { ...node, children: updateTreeData(node.children, key, children) }; + } + return node; + }); + }; + + // Load organization unit children with tree update + const onLoadOuChildren = async (treeNode: any) => { + const nodeKey = String(treeNode.key); + const { items } = await getChildrenApi({ id: nodeKey }); + const children = items.map( + (item): DataNode => ({ + isLeaf: false, + key: item.id, + title: item.displayName, + children: [], + }), + ); + setOrganizationUnits((prev) => updateTreeData(prev, nodeKey, children)); + setLoadedOuKeys((prev) => [...prev, nodeKey]); + }; + + return ( + +
+ + + + {$t("AbpIdentity.DisplayName:IsActive")} + + + + + {!userId && ( + + + + )} + + + + + + + + + + + + + + {$t("AbpIdentity.Description:LockoutEnabled")} + + + + {canManageRoles && ( + + + { + console.log("targetKeys", targetKeys); + const stringTargetKeys = targetKeys.map(String); // 转换成 string[] + setTargetKeys(stringTargetKeys); // 触发react更新 + form.setFieldValue("roleNames", targetKeys); //提交时从form获取roleNames + }} + render={(item) => item.title || ""} + listStyle={{ + width: "47%", + height: "338px", + }} + titles={[$t("AbpIdentity.Assigned"), $t("AbpIdentity.Available")]} + /> + + + )} + + {userId && canManageOu && ( + + + + )} + + +
+ ); +}; + +export default UserModal; diff --git a/apps/react-admin/src/pages/management/identity/users/user-password-modal.tsx b/apps/react-admin/src/pages/management/identity/users/user-password-modal.tsx new file mode 100644 index 000000000..15fa046a1 --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/users/user-password-modal.tsx @@ -0,0 +1,77 @@ +import { Form, Input, Modal, Button } from "antd"; +import { useTranslation } from "react-i18next"; +import { useMutation } from "@tanstack/react-query"; +import { changePasswordApi } from "@/api/management/identity/users"; +import { toast } from "sonner"; + +interface UserPasswordModalProps { + visible: boolean; + userId?: string; + onClose: () => void; + onChange: () => void; +} + +const UserPasswordModal: React.FC = ({ visible, userId, onClose, onChange }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + + const { mutateAsync: changePassword, isPending } = useMutation({ + mutationFn: (password: string) => { + if (!userId) { + return Promise.reject(new Error("userId is undefined")); + } + return changePasswordApi(userId, { password }); + }, + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + onChange(); + onClose(); + form.resetFields(); + }, + }); + + // Generate a random password + const generatePassword = () => { + const length = 12; + const charset = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789!@#$%^&*()_+"; + let password = ""; + for (let i = 0; i < length; i++) { + password += charset.charAt(Math.floor(Math.random() * charset.length)); + } + form.setFieldsValue({ password }); + }; + + const handleOk = async () => { + try { + const values = await form.validateFields(); + await changePassword(values.password); + } catch (error) { + console.error("Validation failed:", error); + } + }; + + return ( + +
+ + {$t("AbpIdentity.RandomPassword")}} + onSearch={generatePassword} + allowClear={false} + /> + + +
+ ); +}; + +export default UserPasswordModal; diff --git a/apps/react-admin/src/pages/management/identity/users/user-table.tsx b/apps/react-admin/src/pages/management/identity/users/user-table.tsx new file mode 100644 index 000000000..4d6101c5a --- /dev/null +++ b/apps/react-admin/src/pages/management/identity/users/user-table.tsx @@ -0,0 +1,395 @@ +import { useRef, useState } from "react"; +import { Button, Dropdown, Modal, Space, Tag } from "antd"; +import { + EditOutlined, + DeleteOutlined, + EllipsisOutlined, + LockOutlined, + UnlockOutlined, + PlusOutlined, +} from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import type { IdentityUserDto } from "#/management/identity/user"; +import { ProTable, type ActionType, type ProColumns } from "@ant-design/pro-table"; +import { useMutation, useQueryClient } from "@tanstack/react-query"; +import { deleteApi, getPagedListApi, unLockApi } from "@/api/management/identity/users"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { IdentityUserPermissions } from "@/constants/management/identity/permissions"; +import { AuditLogPermissions } from "@/constants/management/auditing/permissions"; +import { Iconify } from "@/components/icon"; +import { toast } from "sonner"; +import { formatToDateTime } from "@/utils/abp"; +import useAbpStore from "@/store/abpCoreStore"; + +// Modals +import UserModal from "./user-modal"; +import UserLockModal from "./user-lock-modal"; +import UserClaimModal from "./user-claim-modal"; +import UserPasswordModal from "./user-password-modal"; +import PermissionModal from "@/components/abp/permissions/permission-modal"; +import { EntityChangeDrawer } from "@/components/abp/auditing/entity-change-drawer"; +import Card from "@/components/card"; + +const UserTable: React.FC = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const [modal, contextHolder] = Modal.useModal(); + const queryClient = useQueryClient(); + const abpStore = useAbpStore(); + + // Modal visibility states + const [userModalVisible, setUserModalVisible] = useState(false); + const [lockModalVisible, setLockModalVisible] = useState(false); + const [claimModalVisible, setClaimModalVisible] = useState(false); + const [passwordModalVisible, setPasswordModalVisible] = useState(false); + const [permissionModalVisible, setPermissionModalVisible] = useState(false); + const [entityChangeDrawerVisible, setEntityChangeDrawerVisible] = useState(false); + + // Selected user state + const [selectedUser, setSelectedUser] = useState(); + + // Check if user is locked + const isLocked = (user: IdentityUserDto) => { + if (!user.lockoutEnd) return false; + const lockTime = new Date(user.lockoutEnd); + return lockTime > new Date(); + }; + + // API Mutations + const { mutateAsync: deleteUser } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["users"] }); + }, + }); + + const { mutateAsync: unlockUser } = useMutation({ + mutationFn: unLockApi, + onSuccess: () => { + toast.success($t("AbpIdentity.SavedSuccessfully")); + actionRef.current?.reload(); + queryClient.invalidateQueries({ queryKey: ["users"] }); + }, + }); + + // Handle actions + const handleMenuClick = (key: string, user: IdentityUserDto) => { + setSelectedUser(user); + switch (key) { + case "lock": + setLockModalVisible(true); + break; + case "unlock": + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + onOk: () => unlockUser(user.id), + }); + break; + case "permissions": + setPermissionModalVisible(true); + break; + case "claims": + setClaimModalVisible(true); + break; + case "password": + setPasswordModalVisible(true); + break; + case "entity-changes": + setEntityChangeDrawerVisible(true); + break; + } + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpUi.Search"), + dataIndex: "filter", + hideInTable: true, + }, + { + title: $t("AbpIdentity.DisplayName:IsActive"), + dataIndex: "isActive", + width: 100, + align: "center", + hideInSearch: true, + render: (_, record) => ( + {record.isActive ? $t("AbpUi.Yes") : $t("AbpUi.No")} + ), + }, + { + title: $t("AbpIdentity.DisplayName:UserName"), + dataIndex: "userName", + hideInSearch: true, + width: 150, + }, + { + title: $t("AbpIdentity.DisplayName:Email"), + dataIndex: "email", + hideInSearch: true, + width: 180, + sorter: true, + }, + { + title: $t("AbpIdentity.DisplayName:PhoneNumber"), + dataIndex: "phoneNumber", + hideInSearch: true, + width: 120, + }, + { + title: $t("AbpIdentity.DisplayName:Surname"), + dataIndex: "surname", + hideInSearch: true, + width: 100, + }, + { + title: $t("AbpIdentity.DisplayName:Name"), + dataIndex: "name", + hideInSearch: true, + + width: 100, + }, + { + title: $t("AbpIdentity.LockoutEnd"), + hideInSearch: true, + dataIndex: "lockoutEnd", + width: 160, + render: (_, record) => (record.lockoutEnd ? formatToDateTime(record.lockoutEnd) : "-"), + }, + { + title: $t("AbpUi.Actions"), + width: 200, + hideInSearch: true, + fixed: "right", + render: (_, record) => ( + + {hasAccessByCodes([IdentityUserPermissions.Update]) && ( + + )} + {hasAccessByCodes([IdentityUserPermissions.Delete]) && ( + + )} + handleMenuClick(key, record), + }} + > + + ), + ]} + /> + + + {/* User Modal */} + { + setUserModalVisible(false); + setSelectedUser(undefined); + }} + onChange={() => actionRef.current?.reload()} + /> + + {/* Lock Modal */} + {selectedUser && ( + { + setLockModalVisible(false); + setSelectedUser(undefined); + }} + onChange={() => { + actionRef.current?.reload(); + queryClient.invalidateQueries({ queryKey: ["users"] }); + }} + /> + )} + + {/* Claim Modal */} + {selectedUser && ( + { + setClaimModalVisible(false); + setSelectedUser(undefined); + }} + onChange={() => actionRef.current?.reload()} + /> + )} + + {/* Password Modal */} + {selectedUser && ( + { + setPasswordModalVisible(false); + setSelectedUser(undefined); + }} + onChange={() => actionRef.current?.reload()} + /> + )} + + {/* Permission Modal */} + { + setPermissionModalVisible(false); + setSelectedUser(undefined); + }} + onChange={() => actionRef.current?.reload()} + /> + + {/* Entity Change Drawer */} + { + setEntityChangeDrawerVisible(false); + setSelectedUser(undefined); + }} + /> + + ); +}; + +export default UserTable; diff --git a/apps/react-admin/src/pages/management/notifications/my-notification-modal.tsx b/apps/react-admin/src/pages/management/notifications/my-notification-modal.tsx new file mode 100644 index 000000000..396bfd140 --- /dev/null +++ b/apps/react-admin/src/pages/management/notifications/my-notification-modal.tsx @@ -0,0 +1,25 @@ +import { Modal } from "antd"; +import type { Notification } from "#/notifications"; +import Editor from "@/components/editor"; + +interface Props { + visible: boolean; + notification?: Notification; + onClose: () => void; +} + +const MyNotificationModal: React.FC = ({ visible, notification, onClose }) => { + return ( + + + + ); +}; + +export default MyNotificationModal; diff --git a/apps/react-admin/src/pages/management/notifications/my-notification-table.tsx b/apps/react-admin/src/pages/management/notifications/my-notification-table.tsx new file mode 100644 index 000000000..898664d47 --- /dev/null +++ b/apps/react-admin/src/pages/management/notifications/my-notification-table.tsx @@ -0,0 +1,275 @@ +import { useRef, useState } from "react"; +import { Button, Card, Dropdown, Modal, Space, type MenuProps } from "antd"; +import { DeleteOutlined, DownOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { ProTable, type ActionType, type ProColumns } from "@ant-design/pro-table"; +import { useMutation, useQueryClient } from "@tanstack/react-query"; +import { type Notification, NotificationReadState, NotificationType } from "#/notifications"; +import { + deleteMyNotifilerApi, + getMyNotifilersApi, + markReadStateApi, +} from "@/api/management/notifications/my-notifications"; +import MyNotificationModal from "./my-notification-modal"; +import { formatToDateTime } from "@/utils/abp"; +import { Icon } from "@iconify/react"; +import { toast } from "sonner"; +import { useNotificationSerializer } from "@/utils/abp/notifications/useNotificationSerializer"; + +const MyNotificationTable: React.FC = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const [modal, contextHolder] = Modal.useModal(); + const queryClient = useQueryClient(); + + const { deserialize } = useNotificationSerializer(); + const [selectedRows, setSelectedRows] = useState([]); + const [modalVisible, setModalVisible] = useState(false); + const [selectedNotification, setSelectedNotification] = useState(); + + // Delete notification mutation + const { mutateAsync: deleteNotification } = useMutation({ + mutationFn: deleteMyNotifilerApi, + onSuccess: () => { + toast.success($t("AbpUi.SuccessfullyDeleted")); + queryClient.invalidateQueries({ queryKey: ["notifications"] }); + actionRef.current?.reload(); + }, + }); + + // Mark read state mutation + const { mutateAsync: markReadState } = useMutation({ + mutationFn: markReadStateApi, + onSuccess: () => { + queryClient.invalidateQueries({ queryKey: ["notifications"] }); + actionRef.current?.reload(); + }, + }); + + const handleDelete = (notification: Notification) => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpUi.ItemWillBeDeletedMessageWithFormat", { 0: notification.title }), + onOk: () => deleteNotification(notification.id), + }); + }; + + const handleRead = async (ids: string[], state: NotificationReadState) => { + await markReadState({ idList: ids, state }); + queryClient.invalidateQueries({ queryKey: ["notifications"] }); + setSelectedRows([]); + }; + + const handleClickNotification = (notification: Notification) => { + setSelectedNotification(notification); + setModalVisible(true); + handleRead([notification.id], NotificationReadState.Read); + }; + + const bulkActionMenu: MenuProps["items"] = [ + { + key: "read", + icon: , + label: $t("Notifications.Read"), + onClick: () => + handleRead( + selectedRows.map((row) => row.id), + NotificationReadState.Read, + ), + }, + { + key: "unread", + icon: , + label: $t("Notifications.UnRead"), + onClick: () => + handleRead( + selectedRows.map((row) => row.id), + NotificationReadState.UnRead, + ), + }, + ]; + + const rowActionMenu = (record: Notification): MenuProps["items"] => [ + { + key: "read", + icon: , + label: $t("Notifications.Read"), + onClick: () => handleRead([record.id], NotificationReadState.Read), + }, + { + key: "unread", + icon: , + label: $t("Notifications.UnRead"), + onClick: () => handleRead([record.id], NotificationReadState.UnRead), + }, + ]; + + const columns: ProColumns[] = [ + { + title: $t("Notifications.Notifications:State"), + dataIndex: "readState", + valueType: "select", + fieldProps: { + allowClear: true, + options: [ + { + label: $t("Notifications.Read"), + value: NotificationReadState.Read, + }, + { + label: $t("Notifications.UnRead"), + value: NotificationReadState.UnRead, + }, + ], + }, + initialValue: NotificationReadState.UnRead, + hideInTable: true, + }, + { + title: $t("AbpUi.Search"), + dataIndex: "filter", + valueType: "text", + hideInTable: true, // hide in table + }, + { + title: $t("Notifications.Notifications:Type"), + dataIndex: "type", + + hideInSearch: true, + valueEnum: { + [NotificationType.Application]: $t("Notifications.NotificationType:Application"), + [NotificationType.ServiceCallback]: $t("Notifications.NotificationType:ServiceCallback"), + [NotificationType.System]: $t("Notifications.NotificationType:System"), + [NotificationType.User]: $t("Notifications.NotificationType:User"), + }, + }, + { + title: $t("Notifications.Notifications:SendTime"), + dataIndex: "creationTime", + hideInSearch: true, + render: (_, record) => formatToDateTime(record.creationTime), + }, + { + title: $t("Notifications.Notifications:Title"), + dataIndex: "title", + hideInSearch: true, + render: (_, record) => ( +
+ + +
+ ), + }, + { + title: $t("Notifications.Notifications:Content"), + dataIndex: "message", + hideInSearch: true, + render: (_, record) => ( + + ), + }, + { + title: $t("AbpUi.Actions"), + fixed: "right", + hideInSearch: true, + width: 200, + render: (_, record) => ( + + + + + + + ), + }, + ]; + + return ( + <> + {contextHolder} + + + headerTitle={$t("Notifications.Notifications")} + actionRef={actionRef} + rowKey="id" + columns={columns} + rowSelection={{ + onChange: (_, rows) => setSelectedRows(rows), + }} + toolBarRender={() => [ + selectedRows.length > 0 && ( + + + + ), + ]} + request={async (params) => { + const { current, pageSize, filter, readState } = params; + const query = await queryClient.fetchQuery({ + queryKey: ["notifications", params], + queryFn: async () => + getMyNotifilersApi({ + maxResultCount: pageSize, + skipCount: ((current || 1) - 1) * (pageSize || 0), + filter, + readState, + }), + }); + return { + data: query.items.map((item) => { + const notification = deserialize(item); + return { + ...item, + ...notification, + }; + }), + success: true, + total: query.totalCount, + }; + }} + pagination={{ + showSizeChanger: true, + }} + scroll={{ x: "max-content" }} + search={{ + labelWidth: "auto", + defaultCollapsed: false, + }} + /> + + setModalVisible(false)} + /> + + ); +}; + +export default MyNotificationTable; diff --git a/apps/react-admin/src/pages/management/permissions/definitions/permission-group-definition-modal.tsx b/apps/react-admin/src/pages/management/permissions/definitions/permission-group-definition-modal.tsx new file mode 100644 index 000000000..2e2c4ed6b --- /dev/null +++ b/apps/react-admin/src/pages/management/permissions/definitions/permission-group-definition-modal.tsx @@ -0,0 +1,159 @@ +import { useEffect, useState } from "react"; +import { Form, Input, Modal, Tabs } from "antd"; +import { useTranslation } from "react-i18next"; +import type { PermissionGroupDefinitionDto } from "#/management/permissions/groups"; +import type { PropertyInfo } from "@/components/abp/properties/types"; +import { createApi, getApi, updateApi } from "@/api/management/permissions/groups"; +import LocalizableInput from "@/components/abp/localizable-input/localizable-input"; +import PropertyTable from "@/components/abp/properties/property-table"; +import { toast } from "sonner"; +import { useMutation, useQueryClient } from "@tanstack/react-query"; + +interface Props { + visible: boolean; + onClose: () => void; + onChange: (data: PermissionGroupDefinitionDto) => void; + groupName?: string; +} + +type TabKeys = "basic" | "props"; + +const defaultModel: PermissionGroupDefinitionDto = {} as PermissionGroupDefinitionDto; + +const PermissionGroupDefinitionModal: React.FC = ({ visible, onClose, onChange, groupName }) => { + const { t: $t } = useTranslation(); + const queryClient = useQueryClient(); + const [form] = Form.useForm(); + const [formModel, setFormModel] = useState({ ...defaultModel }); + const [isEditModel, setIsEditModel] = useState(false); + const [activeTab, setActiveTab] = useState("basic"); + + // 获取权限组详情 getApi 用 useMutation + const { mutateAsync: fetchGroup, isPending: isFetching } = useMutation({ + mutationFn: getApi, + onMutate: () => { + setIsEditModel(true); + }, + onSuccess: (dto) => { + setFormModel(dto); + form.setFieldsValue(dto); + }, + }); + + // 创建权限组 + const { mutateAsync: createGroup, isPending: isCreating } = useMutation({ + mutationFn: createApi, + onSuccess: (res) => { + toast.success($t("AbpUi.SavedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["permissionGroups"] }); + onChange(res); + onClose(); + }, + }); + + // 更新权限组 + const { mutateAsync: updateGroup, isPending: isUpdating } = useMutation({ + mutationFn: (data: PermissionGroupDefinitionDto) => updateApi(data.name, data), + onSuccess: (res) => { + toast.success($t("AbpUi.SavedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["permissionGroups"] }); + onChange(res); + onClose(); + }, + }); + + useEffect(() => { + if (visible) { + setIsEditModel(false); + setActiveTab("basic"); + setFormModel({ ...defaultModel }); + form.resetFields(); + + if (groupName) { + fetchGroup(groupName); + } + } + }, [visible, groupName]); + + const handleOk = async () => { + try { + const values = await form.validateFields(); + const submitData = { + ...values, + extraProperties: formModel.extraProperties, + }; + + if (isEditModel) { + await updateGroup(submitData); + } else { + await createGroup(submitData); + } + } catch (error) { + console.error(error); + } + }; + + const handlePropChange = (prop: PropertyInfo) => { + setFormModel((prev) => ({ + ...prev, + extraProperties: { + ...prev.extraProperties, + [prop.key]: prop.value, + }, + })); + }; + + const handlePropDelete = (prop: PropertyInfo) => { + setFormModel((prev) => { + const newProps = { ...prev.extraProperties }; + delete newProps[prop.key]; + return { + ...prev, + extraProperties: newProps, + }; + }); + }; + + return ( + +
+ setActiveTab(key as TabKeys)}> + + + + + + + + + + + + + +
+ ); +}; + +export default PermissionGroupDefinitionModal; diff --git a/apps/react-admin/src/pages/management/permissions/definitions/permission-group-definition-table.tsx b/apps/react-admin/src/pages/management/permissions/definitions/permission-group-definition-table.tsx new file mode 100644 index 000000000..77730f051 --- /dev/null +++ b/apps/react-admin/src/pages/management/permissions/definitions/permission-group-definition-table.tsx @@ -0,0 +1,219 @@ +import { useCallback, useRef, useState } from "react"; +import { Button, Card, Dropdown, Modal } from "antd"; +import { EditOutlined, DeleteOutlined, PlusOutlined, EllipsisOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import type { PermissionGroupDefinitionDto } from "#/management/permissions/groups"; +import { type ActionType, ProTable, type ProColumns } from "@ant-design/pro-table"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import { localizationSerializer } from "@/utils/abp/localization-serializer"; +import { deleteApi, getListApi } from "@/api/management/permissions/groups"; +import { GroupDefinitionsPermissions, PermissionDefinitionsPermissions } from "@/constants/management/permissions"; +import PermissionGroupDefinitionModal from "./permission-group-definition-modal"; +import PermissionDefinitionModal from "../permissions/permission-definition-modal"; +import { useLocalizer } from "@/hooks/abp/use-localization"; +import { toast } from "sonner"; +import { Iconify } from "@/components/icon"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; + +const PermissionGroupDefinitionTable: React.FC = () => { + const { t: $t } = useTranslation(); + const actionRef = useRef(); + const queryClient = useQueryClient(); + const [modal, contextHolder] = Modal.useModal(); + const { deserialize } = localizationSerializer(); + + // Modal states + const [groupModalVisible, setGroupModalVisible] = useState(false); + const [permissionModalVisible, setPermissionModalVisible] = useState(false); + const [selectedGroup, setSelectedGroup] = useState(); + const [selectedGroupForPermission, setSelectedGroupForPermission] = useState(); + const { Lr } = useLocalizer( + undefined, + useCallback(() => { + actionRef.current?.reload(); + setPermissionModalVisible(false); + setGroupModalVisible(false); + }, []), + ); + + const [searchParams, setSearchParams] = useState<{ filter?: string }>({}); + + // 获取权限组列表 + const { data, isLoading } = useQuery({ + queryKey: ["permissionGroups", searchParams], + queryFn: async () => { + const { items } = await getListApi(searchParams); + return items.map((item) => { + const localizableString = deserialize(item.displayName); + return { + ...item, + displayName: Lr(localizableString.resourceName, localizableString.name), + }; + }); + }, + }); + + // 删除权限组 + const { mutateAsync: deleteGroup } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["permissionGroups"] }); + }, + }); + + const handleCreate = () => { + setSelectedGroup(undefined); + setGroupModalVisible(true); + }; + + const handleUpdate = (group: PermissionGroupDefinitionDto) => { + setSelectedGroup(group); + setGroupModalVisible(true); + }; + + const handleDelete = (group: PermissionGroupDefinitionDto) => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpUi.ItemWillBeDeletedMessageWithFormat", { 0: group.name }), + onOk: () => deleteGroup(group.name), + }); + }; + + const handleMenuClick = (key: string, group: PermissionGroupDefinitionDto) => { + if (key === "permissions") { + setSelectedGroupForPermission(group.name); + setPermissionModalVisible(true); + } + }; + + const columns: ProColumns[] = [ + { + title: $t("AbpUi.Search"), + dataIndex: "filter", + valueType: "text", + hideInTable: true, // hide in table + }, + { + title: $t("AbpPermissionManagement.DisplayName:Name"), + dataIndex: "name", + width: "auto", + hideInSearch: true, + }, + { + title: $t("AbpPermissionManagement.DisplayName:DisplayName"), + dataIndex: "displayName", + width: "auto", + hideInSearch: true, + }, + { + title: $t("AbpUi.Actions"), + width: 220, + fixed: "right", + hideInSearch: true, + render: (_, record) => ( +
+
+ {hasAccessByCodes([GroupDefinitionsPermissions.Update]) && ( + + )} +
+ {!record.isStatic && ( + <> +
+ {hasAccessByCodes([GroupDefinitionsPermissions.Delete]) && ( + + )} +
+
+ , + label: $t("AbpPermissionManagement.PermissionDefinitions:AddNew"), + } + : null, + ].filter((item) => item !== null), // 过滤 + onClick: ({ key }) => handleMenuClick(key as string, record), + }} + > +
+ + )} +
+ ), + }, + ]; + + return ( + <> + {contextHolder} + + + headerTitle={$t("AbpPermissionManagement.GroupDefinitions")} + actionRef={actionRef} + columns={columns} + dataSource={data} + loading={isLoading} + rowKey="name" + pagination={{ + showSizeChanger: true, + total: data?.length, + }} + search={{ + labelWidth: "auto", + span: 12, + defaultCollapsed: true, + }} + toolBarRender={() => [ + hasAccessByCodes([GroupDefinitionsPermissions.Create]) && ( + + ), + ]} + request={async (params) => { + const { filter } = params; + setSearchParams({ filter }); + // 强制重新请求数据 + await queryClient.invalidateQueries({ queryKey: ["permissionGroups"] }); + return { data, success: true, total: data?.length }; + }} + /> + + setGroupModalVisible(false)} + onChange={() => { + setGroupModalVisible(false); + actionRef.current?.reload(); + }} + /> + + { + console.log("close"); + setPermissionModalVisible(false); + }} + onChange={() => { + setPermissionModalVisible(false); + actionRef.current?.reload(); + }} + groupName={selectedGroupForPermission} + /> + + ); +}; + +export default PermissionGroupDefinitionTable; diff --git a/apps/react-admin/src/pages/management/permissions/permissions/permission-definition-modal.tsx b/apps/react-admin/src/pages/management/permissions/permissions/permission-definition-modal.tsx new file mode 100644 index 000000000..17ba7eaf4 --- /dev/null +++ b/apps/react-admin/src/pages/management/permissions/permissions/permission-definition-modal.tsx @@ -0,0 +1,272 @@ +import { useEffect, useState } from "react"; +import { Modal, Form, Input, Checkbox, Select, Tabs, TreeSelect } from "antd"; +import { createApi, getListApi as getPermissionsApi, updateApi } from "@/api/management/permissions/definitions"; +import { getListApi as getGroupsApi } from "@/api/management/permissions/groups"; +import { toast } from "sonner"; +import { useTranslation } from "react-i18next"; +import { useTypesMap } from "./types"; +import type { PermissionDefinitionDto } from "#/management/permissions/definitions"; +// import type { PermissionGroupDefinitionDto } from "#/permissions/groups"; +import { listToTree } from "@/utils/tree"; +import { useLocalizer } from "@/hooks/abp/use-localization"; +import { localizationSerializer } from "@/utils/abp/localization-serializer"; +import type { PropertyInfo } from "@/components/abp/properties/types"; +import LocalizableInput from "@/components/abp/localizable-input/localizable-input"; +import PropertyTable from "@/components/abp/properties/property-table"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; + +const { TabPane } = Tabs; +const { Option } = Select; + +interface PermissionDefinitionModalProps { + visible: boolean; + onClose: () => void; + onChange: () => void; + permission?: PermissionDefinitionDto; + groupName?: string; +} + +interface PermissionTreeVo { + children: PermissionTreeVo[]; + displayName: string; + groupName: string; + name: string; + disabled?: boolean; +} + +type TabKeys = "basic" | "props"; + +const defaultModel: PermissionDefinitionDto = {} as PermissionDefinitionDto; + +const PermissionDefinitionModal: React.FC = ({ + visible, + onClose, + onChange, + permission, + groupName, +}) => { + const { t: $t } = useTranslation(); + const queryClient = useQueryClient(); + const [form] = Form.useForm(); + const { multiTenancySideOptions, providerOptions } = useTypesMap($t); + const [activeTab, setActiveTab] = useState("basic"); + const [formModel, setFormModel] = useState({ ...defaultModel }); + const { Lr } = useLocalizer(); + const { deserialize } = localizationSerializer(); + + // 查询权限组列表 + const { data: availableGroups = [] } = useQuery({ + queryKey: ["permissionGroups", groupName], + queryFn: async () => { + const { items } = await getGroupsApi({ filter: groupName }); + return items + .filter((group) => !group.isStatic) + .map((group) => { + const localizableGroup = deserialize(group.displayName); + return { + ...group, + displayName: Lr(localizableGroup.resourceName, localizableGroup.name), + }; + }); + }, + + enabled: visible, + }); + + // 查询权限列表 + const { data: availablePermissions = [] } = useQuery({ + queryKey: ["permissions", formModel.groupName], + queryFn: async () => { + const { items } = await getPermissionsApi({ groupName: formModel.groupName }); + const permissions = items.map((permission) => { + const localizablePermission = deserialize(permission.displayName); + return { + ...permission, + disabled: permission.name === formModel.name, + displayName: Lr(localizablePermission.resourceName, localizablePermission.name), + }; + }); + return listToTree(permissions, { id: "name", pid: "parentName" }); + }, + enabled: visible && !!formModel.groupName, + }); + + // 创建权限 + const { mutateAsync: createPermission, isPending: isCreating } = useMutation({ + mutationFn: createApi, + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["permissions"] }); + queryClient.invalidateQueries({ queryKey: ["permissionGroups"] }); + onChange(); + onClose(); + }, + }); + + // 更新权限 + const { mutateAsync: updatePermission, isPending: isUpdating } = useMutation({ + mutationFn: (data: PermissionDefinitionDto) => updateApi(data.name, data), + onSuccess: () => { + toast.success($t("AbpUi.SavedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["permissions"] }); + queryClient.invalidateQueries({ queryKey: ["permissionGroups"] }); + onChange(); + onClose(); + }, + }); + + useEffect(() => { + if (visible) { + setActiveTab("basic"); + form.resetFields(); + + if (permission) { + const initialModel = { + ...permission, + extraProperties: permission.extraProperties || {}, + }; + setFormModel(initialModel); + form.setFieldsValue(initialModel); + } else { + setFormModel({ ...defaultModel }); + if (groupName) { + form.setFieldsValue({ groupName }); + } + } + } + }, [visible, permission, groupName]); + + const handleOk = async () => { + try { + const values = await form.validateFields(); + const submitData = { + ...values, + extraProperties: formModel.extraProperties, + }; + + if (permission) { + await updatePermission(submitData); + } else { + await createPermission(submitData); + } + } catch (error) { + console.error(error); + } + }; + + const handleGroupChange = (groupName?: string) => { + setFormModel((prev) => ({ ...prev, groupName: groupName || "" })); + }; + + const handlePropChange = (prop: PropertyInfo) => { + setFormModel((prev) => ({ + ...prev, + extraProperties: { + ...prev.extraProperties, + [prop.key]: prop.value, + }, + })); + }; + + const handlePropDelete = (prop: PropertyInfo) => { + setFormModel((prev) => { + const newProps = { ...prev.extraProperties }; + delete newProps[prop.key]; + return { + ...prev, + extraProperties: newProps, + }; + }); + }; + + return ( + +
+ setActiveTab(key as TabKeys)}> + + + {$t("AbpPermissionManagement.DisplayName:IsEnabled")} + + + + + {availablePermissions.length > 0 && ( + + + + )} + + + + + + + + + + + + + + + + + + +
+ ); +}; + +export default PermissionDefinitionModal; diff --git a/apps/react-admin/src/pages/management/permissions/permissions/permission-definition-table.tsx b/apps/react-admin/src/pages/management/permissions/permissions/permission-definition-table.tsx new file mode 100644 index 000000000..39179f7cf --- /dev/null +++ b/apps/react-admin/src/pages/management/permissions/permissions/permission-definition-table.tsx @@ -0,0 +1,288 @@ +import { useCallback, useRef, useState } from "react"; +import { Button, Card, Modal, Space, Table, Tag } from "antd"; +import { EditOutlined, DeleteOutlined, PlusOutlined } from "@ant-design/icons"; +import { useTranslation } from "react-i18next"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; + +import type { MultiTenancySides, PermissionDefinitionDto } from "#/management/permissions/definitions"; +import { type ActionType, ProTable, type ProColumns } from "@ant-design/pro-table"; + +import { localizationSerializer } from "@/utils/abp/localization-serializer"; + +import { deleteApi, getListApi as getPermissionsApi } from "@/api/management/permissions/definitions"; +import { getListApi as getGroupsApi } from "@/api/management/permissions/groups"; +import { GroupDefinitionsPermissions } from "@/constants/management/permissions"; +import { hasAccessByCodes } from "@/utils/abp/access-checker"; +import PermissionDefinitionModal from "./permission-definition-modal"; +import { useLocalizer } from "@/hooks/abp/use-localization"; +import { useTypesMap } from "./types"; +import { listToTree } from "@/utils/tree"; +import type { ExtraPropertyDictionary } from "#/abp-core"; +import type { ColumnsType } from "antd/es/table"; +import { toast } from "sonner"; + +interface PermissionVo { + children: PermissionVo[]; + displayName: string; + groupName: string; + isEnabled: boolean; + isStatic: boolean; + multiTenancySide: MultiTenancySides; + name: string; + parentName?: string; + providers: string[]; + stateCheckers: string; + extraProperties: ExtraPropertyDictionary; +} + +interface PermissionGroupVo { + displayName: string; + name: string; + permissions: PermissionVo[]; +} + +const PermissionDefinitionTable: React.FC = () => { + const { t: $t } = useTranslation(); + const [modal, contextHolder] = Modal.useModal(); + const actionRef = useRef(); + const queryClient = useQueryClient(); + const [modalVisible, setModalVisible] = useState(false); + const [selectedPermission, setSelectedPermission] = useState(); + + const [searchParams, setSearchParams] = useState<{ filter?: string }>({}); + + const { Lr } = useLocalizer( + undefined, + useCallback(() => { + actionRef.current?.reload(); + setModalVisible(false); + }, []), + ); + + const { deserialize } = localizationSerializer(); + const { multiTenancySidesMap, providersMap } = useTypesMap($t); + + // 删除权限操作 + const { mutateAsync: deletePermission } = useMutation({ + mutationFn: deleteApi, + onSuccess: () => { + toast.success($t("AbpUi.DeletedSuccessfully")); + queryClient.invalidateQueries({ queryKey: ["permissions", "permissionGroups"] }); + }, + }); + + // 获取权限数据 + const { data, isLoading } = useQuery({ + queryKey: ["permissions", "permissionGroups", searchParams], + queryFn: async () => { + const [groupRes, permissionRes] = await Promise.all([ + getGroupsApi(searchParams), + getPermissionsApi(searchParams), + ]); + + const groups: PermissionGroupVo[] = groupRes.items.map((group) => { + const localizableGroup = deserialize(group.displayName); + const permissions = permissionRes.items + .filter((permission) => permission.groupName === group.name) + .map((permission) => { + const localizablePermission = deserialize(permission.displayName); + return { + ...permission, + displayName: Lr(localizablePermission.resourceName, localizablePermission.name), + }; + }); + return { + ...group, + displayName: Lr(localizableGroup.resourceName, localizableGroup.name), + permissions: listToTree(permissions, { + id: "name", + pid: "parentName", + }), + }; + }); + + return groups; + }, + }); + + const handleDelete = async (permission: PermissionDefinitionDto) => { + modal.confirm({ + title: $t("AbpUi.AreYouSure"), + content: $t("AbpUi.ItemWillBeDeletedMessageWithFormat", { 0: permission.name }), + onOk: () => deletePermission(permission.name), + }); + }; + + const mainColumns: ProColumns[] = [ + { + title: $t("abp.sequence"), + dataIndex: "index", + valueType: "index", + width: 50, + render: (_, __, index) => index + 1, + }, + { + title: $t("AbpUi.Search"), + dataIndex: "filter", + valueType: "text", + hideInTable: true, // hide in table + }, + { + title: $t("AbpPermissionManagement.DisplayName:Name"), + dataIndex: "name", + width: 150, + hideInSearch: true, + }, + { + title: $t("AbpPermissionManagement.DisplayName:DisplayName"), + dataIndex: "displayName", + width: 150, + hideInSearch: true, + }, + ]; + + const subColumns: ColumnsType = [ + { + title: $t("AbpPermissionManagement.DisplayName:Name"), + dataIndex: "name", + width: 200, + ellipsis: true, + }, + { + title: $t("AbpPermissionManagement.DisplayName:DisplayName"), + dataIndex: "displayName", + width: 200, + }, + { + align: "center", + minWidth: 100, + // slots: { default: 'tenant' }, + title: $t("AbpPermissionManagement.DisplayName:MultiTenancySide"), + render: (_, record) => ( + + {multiTenancySidesMap[record.multiTenancySide]} + + ), + }, + { + title: $t("AbpPermissionManagement.DisplayName:Providers"), + width: 200, + render: (_, record) => ( + + {record.providers.map((provider) => ( + + {providersMap[provider]} + + ))} + + ), + }, + { + title: $t("AbpUi.Actions"), + width: 180, + fixed: "right", + render: (_, record) => ( + + {hasAccessByCodes([GroupDefinitionsPermissions.Update]) && ( + + )} + {!record.isStatic && hasAccessByCodes([GroupDefinitionsPermissions.Delete]) && ( + + )} + + ), + }, + ]; + + const expandedRowRender = (group: PermissionGroupVo) => { + return ( + + columns={subColumns} + dataSource={group.permissions} + pagination={false} + rowKey={(record) => record.name} + indentSize={30} + expandable={{ + defaultExpandAllRows: false, + childrenColumnName: "children", // 指定子项字段 + }} + /> + ); + }; + + // 工具栏 + const toolBarRender = () => [ + hasAccessByCodes([GroupDefinitionsPermissions.Create]) && ( + + ), + ]; + + return ( + <> + {contextHolder} + + + + headerTitle={$t("AbpPermissionManagement.PermissionDefinitions")} + actionRef={actionRef} + columns={mainColumns} + dataSource={data} + loading={isLoading} + rowKey={(record) => record.name} + expandable={{ expandedRowRender }} + toolBarRender={toolBarRender} + pagination={{ + showSizeChanger: true, + total: data?.length, + }} + search={{ + labelWidth: "auto", + span: 12, //search part width + defaultCollapsed: true, + }} + request={async (params) => { + const { filter } = params; + setSearchParams({ filter: filter }); + //强制重新请求数据(用于table的刷新按钮) + await queryClient.invalidateQueries({ queryKey: ["permissions", "permissionGroups"] }); + return { data, success: true, total: data?.length }; + }} + /> + + { + setModalVisible(false); + setSelectedPermission(undefined); + }} + onChange={() => { + setModalVisible(false); + actionRef.current?.reload(); + }} + /> + + ); +}; + +export default PermissionDefinitionTable; diff --git a/apps/react-admin/src/pages/management/permissions/permissions/types.ts b/apps/react-admin/src/pages/management/permissions/permissions/types.ts new file mode 100644 index 000000000..a0001a9b8 --- /dev/null +++ b/apps/react-admin/src/pages/management/permissions/permissions/types.ts @@ -0,0 +1,46 @@ +import { MultiTenancySides } from "#/management/permissions/definitions"; +import type { TFunction } from "i18next"; + +export function useTypesMap($t: TFunction) { + const multiTenancySidesMap: { [key: number]: string } = { + [MultiTenancySides.Both]: $t("AbpPermissionManagement.MultiTenancySides:Both"), + [MultiTenancySides.Host]: $t("AbpPermissionManagement.MultiTenancySides:Host"), + [MultiTenancySides.Tenant]: $t("AbpPermissionManagement.MultiTenancySides:Tenant"), + }; + + const multiTenancySideOptions = [ + { + label: multiTenancySidesMap[MultiTenancySides.Tenant], + value: MultiTenancySides.Tenant, + }, + { + label: multiTenancySidesMap[MultiTenancySides.Host], + value: MultiTenancySides.Host, + }, + { + label: multiTenancySidesMap[MultiTenancySides.Both], + value: MultiTenancySides.Both, + }, + ]; + + const providersMap: { [key: string]: string } = { + C: $t("AbpPermissionManagement.Providers:Client"), + O: $t("AbpPermissionManagement.Providers:OrganizationUnit"), + R: $t("AbpPermissionManagement.Providers:Role"), + U: $t("AbpPermissionManagement.Providers:User"), + }; + + const providerOptions = [ + { label: providersMap.R, value: "R" }, + { label: providersMap.U, value: "U" }, + { label: providersMap.O, value: "O" }, + { label: providersMap.C, value: "C" }, + ]; + + return { + multiTenancySideOptions, + multiTenancySidesMap, + providerOptions, + providersMap, + }; +} diff --git a/apps/react-admin/src/pages/management/settings/definitions/setting-definition-modal.tsx b/apps/react-admin/src/pages/management/settings/definitions/setting-definition-modal.tsx new file mode 100644 index 000000000..df581c229 --- /dev/null +++ b/apps/react-admin/src/pages/management/settings/definitions/setting-definition-modal.tsx @@ -0,0 +1,228 @@ +import { useEffect, useState } from "react"; +import { Form, Input, Modal, Tabs, Select, Checkbox } from "antd"; +import TextArea from "antd/es/input/TextArea"; +import { useTranslation } from "react-i18next"; +import type { SettingDefinitionDto } from "#/management/settings/definitions"; +import type { PropertyInfo } from "@/components/abp/properties/types"; +import { useMutation, useQuery, useQueryClient } from "@tanstack/react-query"; +import { createApi, getApi, updateApi } from "@/api/management/settings/definitions"; +import LocalizableInput from "@/components/abp/localizable-input/localizable-input"; +import PropertyTable from "@/components/abp/properties/property-table"; +import { toast } from "sonner"; +import { CircleLoading } from "@/components/loading"; +import { mergeDeepRight } from "ramda"; + +interface Props { + visible: boolean; + settingName?: string; + onClose: () => void; + onChange: (data: SettingDefinitionDto) => void; +} + +type TabKeys = "basic" | "props"; + +const defaultModel = {} as SettingDefinitionDto; + +const SettingDefinitionModal: React.FC = ({ visible, settingName, onClose, onChange }) => { + const { t: $t } = useTranslation(); + const [form] = Form.useForm(); + const queryClient = useQueryClient(); + const [activeTab, setActiveTab] = useState("basic"); + const [formModel, setFormModel] = useState(defaultModel); + + const providerOptions = [ + { label: $t("AbpSettingManagement.Providers:Default"), value: "D" }, + { label: $t("AbpSettingManagement.Providers:Configuration"), value: "C" }, + { label: $t("AbpSettingManagement.Providers:Global"), value: "G" }, + { label: $t("AbpSettingManagement.Providers:Tenant"), value: "T" }, + { label: $t("AbpSettingManagement.Providers:User"), value: "U" }, + ]; + // Fetch setting data if editing + const { data: settingData, isLoading } = useQuery({ + queryKey: ["settingDefinition", settingName], + queryFn: () => { + if (!settingName) { + return Promise.reject(new Error("settingName is undefined")); + } + return getApi(settingName); + }, + enabled: !!settingName && visible, + }); + + useEffect(() => { + if (settingData && settingData.name === settingName) { + setFormModel(settingData); + form.setFieldsValue(settingData); + } + }, [settingData]); + + useEffect(() => { + if (visible) { + setActiveTab("basic"); + } + }, [visible]); + + // Create/Update mutations + const { mutateAsync: createSetting } = useMutation({ + mutationFn: createApi, + onSuccess: (data) => { + toast.success($t("AbpUi.SavedSuccessfully")); + onChange(data); + onClose(); + }, + }); + + const { mutateAsync: updateSetting } = useMutation({ + mutationFn: ({ name, input }: { name: string; input: SettingDefinitionDto }) => updateApi(name, input), + onSuccess: (data) => { + queryClient.invalidateQueries({ queryKey: ["settingDefinition", settingName] }); + toast.success($t("AbpUi.SavedSuccessfully")); + onChange(data); + onClose(); + }, + }); + + const handlePropertyChange = (prop: PropertyInfo) => { + setFormModel((prev) => ({ + ...prev, + extraProperties: { + ...prev.extraProperties, + [prop.key]: prop.value, + }, + })); + }; + + const handlePropertyDelete = (prop: PropertyInfo) => { + setFormModel((prev) => { + const newProperties = { ...prev.extraProperties }; + delete newProperties[prop.key]; + return { + ...prev, + extraProperties: newProperties, + }; + }); + }; + + const handleSubmit = async () => { + if (formModel.isStatic) return; + + try { + await form.validateFields(); + if (settingName) { + await updateSetting({ name: settingName, input: formModel }); + } else { + await createSetting(formModel); + } + } catch (error) { + console.error("Validation failed:", error); + } + }; + + return ( + { + onClose(); + form.resetFields(); + setFormModel(defaultModel); + form.resetFields(); + }} + onClose={() => { + onClose(); + form.resetFields(); + setFormModel(defaultModel); + form.resetFields(); + }} + onOk={handleSubmit} + okButtonProps={{ disabled: formModel.isStatic }} + width="50%" + destroyOnClose + > + {!!settingName && visible && isLoading ? ( + + ) : ( +
{ + setFormModel((prevModel) => { + return mergeDeepRight(prevModel, changedValues); + }); + }} + > + setActiveTab(key as TabKeys)}> + + + + + + + + + + + diff --git a/apps/vben5/packages/@abp/components/src/tinymce/helper.ts b/apps/vben5/packages/@abp/components/src/tinymce/helper.ts new file mode 100644 index 000000000..6b331df4e --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/tinymce/helper.ts @@ -0,0 +1,85 @@ +const validEvents = new Set([ + 'onActivate', + 'onAddUndo', + 'onBeforeAddUndo', + 'onBeforeExecCommand', + 'onBeforeGetContent', + 'onBeforePaste', + 'onBeforeRenderUI', + 'onBeforeSetContent', + 'onBlur', + 'onChange', + 'onClearUndos', + 'onClick', + 'onContextMenu', + 'onCopy', + 'onCut', + 'onDblclick', + 'onDeactivate', + 'onDirty', + 'onDrag', + 'onDragDrop', + 'onDragEnd', + 'onDragGesture', + 'onDragOver', + 'onDrop', + 'onExecCommand', + 'onFocus', + 'onFocusIn', + 'onFocusOut', + 'onGetContent', + 'onHide', + 'onInit', + 'onKeyDown', + 'onKeyPress', + 'onKeyUp', + 'onLoadContent', + 'onMouseDown', + 'onMouseEnter', + 'onMouseLeave', + 'onMouseMove', + 'onMouseOut', + 'onMouseOver', + 'onMouseUp', + 'onNodeChange', + 'onObjectResized', + 'onObjectResizeStart', + 'onObjectSelected', + 'onPaste', + 'onPostProcess', + 'onPostRender', + 'onPreProcess', + 'onProgressState', + 'onRedo', + 'onRemove', + 'onReset', + 'onSaveContent', + 'onSelectionChange', + 'onSetAttrib', + 'onSetContent', + 'onShow', + 'onSubmit', + 'onUndo', + 'onVisualAid', +]); + +const isValidKey = (key: string) => validEvents.has(key); + +export const bindHandlers = ( + initEvent: Event, + listeners: any, + editor: any, +): void => { + Object.keys(listeners) + .filter((key) => isValidKey(key)) + .forEach((key: string) => { + const handler = listeners[key]; + if (typeof handler === 'function') { + if (key === 'onInit') { + handler(initEvent, editor); + } else { + editor.on(key.slice(2), (e: any) => handler(e, editor)); + } + } + }); +}; diff --git a/apps/vben5/packages/@abp/components/src/tinymce/index.ts b/apps/vben5/packages/@abp/components/src/tinymce/index.ts new file mode 100644 index 000000000..5f4575450 --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/tinymce/index.ts @@ -0,0 +1 @@ +export { default as Tinymce } from './Editor.vue'; diff --git a/apps/vben5/packages/@abp/components/src/tinymce/tinymce.ts b/apps/vben5/packages/@abp/components/src/tinymce/tinymce.ts new file mode 100644 index 000000000..1374b4dab --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/tinymce/tinymce.ts @@ -0,0 +1,13 @@ +// Any plugins you want to setting has to be imported +// Detail plugins list see https://www.tinymce.com/docs/plugins/ +// Custom builds see https://www.tinymce.com/download/custom-builds/ +// colorpicker/contextmenu/textcolor plugin is now built in to the core editor, please remove it from your editor configuration + +export const plugins = [ + 'advlist anchor autolink autosave code codesample directionality fullscreen hr insertdatetime link lists media nonbreaking noneditable pagebreak paste preview print save searchreplace spellchecker tabfocus template textpattern visualblocks visualchars wordcount', +]; + +export const toolbar = [ + 'fontsizeselect lineheight searchreplace bold italic underline strikethrough alignleft aligncenter alignright outdent indent blockquote undo redo removeformat subscript superscript code codesample', + 'hr bullist numlist link preview anchor pagebreak insertdatetime media forecolor backcolor fullscreen', +]; diff --git a/apps/vben5/packages/@abp/components/src/tinymce/useTinymce.ts b/apps/vben5/packages/@abp/components/src/tinymce/useTinymce.ts new file mode 100644 index 000000000..0857db940 --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/tinymce/useTinymce.ts @@ -0,0 +1,13 @@ +let unique = 0; +export function useTinymce() { + function buildShortUUID(prefix = ''): string { + const time = Date.now(); + const random = Math.floor(Math.random() * 1_000_000_000); + unique++; + return `${prefix}_${random}${unique}${String(time)}`; + } + + return { + buildShortUUID, + }; +} diff --git a/apps/vben5/packages/@abp/components/src/vditor/Editor.vue b/apps/vben5/packages/@abp/components/src/vditor/Editor.vue new file mode 100644 index 000000000..dd483da42 --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/vditor/Editor.vue @@ -0,0 +1,173 @@ + + + + + diff --git a/apps/vben5/packages/@abp/components/src/vditor/index.ts b/apps/vben5/packages/@abp/components/src/vditor/index.ts new file mode 100644 index 000000000..7ceb1995b --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/vditor/index.ts @@ -0,0 +1 @@ +export { default as MarkdownEditor } from './Editor.vue'; diff --git a/apps/vben5/packages/@abp/components/src/vditor/vditor.ts b/apps/vben5/packages/@abp/components/src/vditor/vditor.ts new file mode 100644 index 000000000..be6c71ba2 --- /dev/null +++ b/apps/vben5/packages/@abp/components/src/vditor/vditor.ts @@ -0,0 +1,32 @@ +export const toolbar = [ + 'emoji', + 'headings', + 'bold', + 'italic', + 'strike', + 'link', + '|', + 'list', + 'ordered-list', + 'check', + 'outdent', + 'indent', + '|', + 'quote', + 'line', + 'code', + 'inline-code', + 'insert-before', + 'insert-after', + '|', + // 'record', + 'table', + '|', + 'undo', + 'redo', + '|', + 'edit-mode', + // 'content-theme', + 'code-theme', + 'export', +]; diff --git a/apps/vben5/packages/@abp/permission/tsconfig.json b/apps/vben5/packages/@abp/components/tsconfig.json similarity index 100% rename from apps/vben5/packages/@abp/permission/tsconfig.json rename to apps/vben5/packages/@abp/components/tsconfig.json diff --git a/apps/vben5/packages/@abp/core/package.json b/apps/vben5/packages/@abp/core/package.json index ce80edc1a..2374f1ebc 100644 --- a/apps/vben5/packages/@abp/core/package.json +++ b/apps/vben5/packages/@abp/core/package.json @@ -1,6 +1,6 @@ { "name": "@abp/core", - "version": "8.3.2", + "version": "9.0.4", "homepage": "https://github.com/colinin/abp-next-admin", "bugs": "https://github.com/colinin/abp-next-admin/issues", "repository": { @@ -37,12 +37,14 @@ "dependencies": { "@vueuse/core": "catalog:", "dayjs": "catalog:", + "lodash.groupby": "catalog:", "lodash.merge": "catalog:", "pinia": "catalog:", "pinia-plugin-persistedstate": "catalog:", "vue": "catalog:" }, "devDependencies": { + "@types/lodash.groupby": "catalog:", "@types/lodash.merge": "catalog:" } } diff --git a/apps/vben5/packages/@abp/core/src/constants/events.ts b/apps/vben5/packages/@abp/core/src/constants/events.ts new file mode 100644 index 000000000..9ee264faf --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/constants/events.ts @@ -0,0 +1,12 @@ +export const Events = { + /** 收到服务器消息 */ + GetNotification: 'get-notification', + /** 新通知消息 */ + NotificationRecevied: 'sys_notifications_recevied', + /** 权限变更事件 */ + PermissionChange: 'sys_permission_change', + /** 用户登录事件 */ + UserLogin: 'sys_user_login', + /** 用户登出事件 */ + UserLogout: 'sys_user_logout', +}; diff --git a/apps/vben5/packages/@abp/core/src/constants/index.ts b/apps/vben5/packages/@abp/core/src/constants/index.ts index 4d5ffa36a..b624aad55 100644 --- a/apps/vben5/packages/@abp/core/src/constants/index.ts +++ b/apps/vben5/packages/@abp/core/src/constants/index.ts @@ -1 +1,2 @@ +export * from './events'; export * from './validation'; diff --git a/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireAuthenticatedSimpleStateChecker.ts b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireAuthenticatedSimpleStateChecker.ts new file mode 100644 index 000000000..add3d46cf --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireAuthenticatedSimpleStateChecker.ts @@ -0,0 +1,42 @@ +import type { + CurrentUser, + IHasSimpleStateCheckers, + ISimpleStateChecker, + SimpleStateCheckerContext, +} from '../../types/global'; + +import { useAbpStore } from '../../store/abp'; + +export interface RequireAuthenticatedStateChecker { + name: string; +} + +export class RequireAuthenticatedSimpleStateChecker< + TState extends IHasSimpleStateCheckers, + > + implements ISimpleStateChecker, RequireAuthenticatedStateChecker +{ + _currentUser?: CurrentUser; + name = 'A'; + constructor(currentUser?: CurrentUser) { + this._currentUser = currentUser; + } + isEnabled(_context: SimpleStateCheckerContext): boolean { + return this._currentUser?.isAuthenticated ?? false; + } + + serialize(): string { + return JSON.stringify({ + T: this.name, + }); + } +} + +export function useRequireAuthenticatedSimpleStateChecker< + TState extends IHasSimpleStateCheckers, +>(): ISimpleStateChecker { + const abpStore = useAbpStore(); + return new RequireAuthenticatedSimpleStateChecker( + abpStore.application?.currentUser, + ); +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireFeaturesSimpleStateChecker.ts b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireFeaturesSimpleStateChecker.ts new file mode 100644 index 000000000..0de9dda52 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireFeaturesSimpleStateChecker.ts @@ -0,0 +1,59 @@ +import type { IFeatureChecker } from '../../types/features'; +import type { + IHasSimpleStateCheckers, + ISimpleStateChecker, + SimpleStateCheckerContext, +} from '../../types/global'; + +import { useFeatures } from '../useFeatures'; + +export interface RequireFeaturesStateChecker { + featureNames: string[]; + name: string; + requiresAll: boolean; +} + +export class RequireFeaturesSimpleStateChecker< + TState extends IHasSimpleStateCheckers, + > + implements ISimpleStateChecker, RequireFeaturesStateChecker +{ + _featureChecker: IFeatureChecker; + featureNames: string[]; + name: string = 'F'; + requiresAll: boolean; + constructor( + featureChecker: IFeatureChecker, + featureNames: string[], + requiresAll: boolean = false, + ) { + this._featureChecker = featureChecker; + this.featureNames = featureNames; + this.requiresAll = requiresAll; + } + isEnabled(_context: SimpleStateCheckerContext): boolean { + return this._featureChecker.isEnabled(this.featureNames, this.requiresAll); + } + + serialize(): string { + return JSON.stringify({ + A: this.requiresAll, + N: this.featureNames, + T: this.name, + }); + } +} + +export function useRequireFeaturesSimpleStateChecker< + TState extends IHasSimpleStateCheckers, +>( + featureNames: string[], + requiresAll: boolean = false, +): ISimpleStateChecker { + const featureChecker = useFeatures(); + return new RequireFeaturesSimpleStateChecker( + featureChecker, + featureNames, + requiresAll, + ); +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireGlobalFeaturesSimpleStateChecker.ts b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireGlobalFeaturesSimpleStateChecker.ts new file mode 100644 index 000000000..882d5d89d --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequireGlobalFeaturesSimpleStateChecker.ts @@ -0,0 +1,62 @@ +import type { IGlobalFeatureChecker } from '../../types/features'; +import type { + IHasSimpleStateCheckers, + ISimpleStateChecker, + SimpleStateCheckerContext, +} from '../../types/global'; + +import { useGlobalFeatures } from '../useGlobalFeatures'; + +export interface RequireGlobalFeaturesStateChecker { + globalFeatureNames: string[]; + name: string; + requiresAll: boolean; +} + +export class RequireGlobalFeaturesSimpleStateChecker< + TState extends IHasSimpleStateCheckers, + > + implements ISimpleStateChecker, RequireGlobalFeaturesStateChecker +{ + _globalFeatureChecker: IGlobalFeatureChecker; + globalFeatureNames: string[]; + name: string = 'G'; + requiresAll: boolean; + constructor( + globalFeatureChecker: IGlobalFeatureChecker, + globalFeatureNames: string[], + requiresAll: boolean = false, + ) { + this._globalFeatureChecker = globalFeatureChecker; + this.globalFeatureNames = globalFeatureNames; + this.requiresAll = requiresAll; + } + isEnabled(_context: SimpleStateCheckerContext): boolean { + return this._globalFeatureChecker.isEnabled( + this.globalFeatureNames, + this.requiresAll, + ); + } + + serialize(): string { + return JSON.stringify({ + A: this.requiresAll, + N: this.globalFeatureNames, + T: this.name, + }); + } +} + +export function useRequireGlobalFeaturesSimpleStateChecker< + TState extends IHasSimpleStateCheckers, +>( + globalFeatureNames: string[], + requiresAll: boolean = false, +): ISimpleStateChecker { + const globalFeatureChecker = useGlobalFeatures(); + return new RequireGlobalFeaturesSimpleStateChecker( + globalFeatureChecker, + globalFeatureNames, + requiresAll, + ); +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequirePermissionsSimpleStateChecker.ts b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequirePermissionsSimpleStateChecker.ts new file mode 100644 index 000000000..18b96e326 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/SimpleStateChecking/useRequirePermissionsSimpleStateChecker.ts @@ -0,0 +1,123 @@ +import type { + IHasSimpleStateCheckers, + ISimpleBatchStateChecker, + ISimpleStateChecker, + SimpleBatchStateCheckerContext, + SimpleStateCheckerContext, + SimpleStateCheckerResult, +} from '../../types/global'; +import type { IPermissionChecker } from '../../types/permissions'; + +import { useAuthorization } from '../useAuthorization'; + +export class RequirePermissionsSimpleBatchStateCheckerModel< + TState extends IHasSimpleStateCheckers, +> { + permissions: string[]; + requiresAll: boolean; + state: TState; + constructor( + state: TState, + permissions: string[], + requiresAll: boolean = true, + ) { + this.state = state; + this.permissions = permissions; + this.requiresAll = requiresAll; + } +} + +export interface RequirePermissionsStateChecker< + TState extends IHasSimpleStateCheckers, +> { + model: RequirePermissionsSimpleBatchStateCheckerModel; + name: string; +} + +export class RequirePermissionsSimpleStateChecker< + TState extends IHasSimpleStateCheckers, + > + implements ISimpleStateChecker, RequirePermissionsStateChecker +{ + _permissionChecker: IPermissionChecker; + model: RequirePermissionsSimpleBatchStateCheckerModel; + name: string = 'P'; + constructor( + permissionChecker: IPermissionChecker, + model: RequirePermissionsSimpleBatchStateCheckerModel, + ) { + this.model = model; + this._permissionChecker = permissionChecker; + } + isEnabled(_context: SimpleStateCheckerContext): boolean { + return this._permissionChecker.isGranted( + this.model.permissions, + this.model.requiresAll, + ); + } + + serialize(): string { + return JSON.stringify({ + A: this.model.requiresAll, + N: this.model.permissions, + T: this.name, + }); + } +} + +export class RequirePermissionsSimpleBatchStateChecker< + TState extends IHasSimpleStateCheckers, +> implements ISimpleBatchStateChecker +{ + _permissionChecker: IPermissionChecker; + models: RequirePermissionsSimpleBatchStateCheckerModel[]; + name: string = 'P'; + constructor( + permissionChecker: IPermissionChecker, + models: RequirePermissionsSimpleBatchStateCheckerModel[], + ) { + this.models = models; + this._permissionChecker = permissionChecker; + } + isEnabled(context: SimpleBatchStateCheckerContext) { + const result = {} as SimpleStateCheckerResult; + context.states.forEach((state) => { + const model = this.models.find((x) => x.state === state); + if (model) { + result[model.state] = this._permissionChecker.isGranted( + model.permissions, + model.requiresAll, + ); + } + }); + return result; + } + + serialize(): string | undefined { + return undefined; + } +} + +export function useRequirePermissionsSimpleStateChecker< + TState extends IHasSimpleStateCheckers, +>( + model: RequirePermissionsSimpleBatchStateCheckerModel, +): ISimpleStateChecker { + const permissionChecker = useAuthorization(); + return new RequirePermissionsSimpleStateChecker( + permissionChecker, + model, + ); +} + +export function useRequirePermissionsSimpleBatchStateChecker< + TState extends IHasSimpleStateCheckers, +>( + models: RequirePermissionsSimpleBatchStateCheckerModel[], +): ISimpleBatchStateChecker { + const permissionChecker = useAuthorization(); + return new RequirePermissionsSimpleBatchStateChecker( + permissionChecker, + models, + ); +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/index.ts b/apps/vben5/packages/@abp/core/src/hooks/index.ts index 2d4c33225..cf94b1a90 100644 --- a/apps/vben5/packages/@abp/core/src/hooks/index.ts +++ b/apps/vben5/packages/@abp/core/src/hooks/index.ts @@ -1,4 +1,10 @@ +export * from './useAuthorization'; +export * from './useEventBus'; +export * from './useFeatures'; +export * from './useGlobalFeatures'; export * from './useLocalization'; +export * from './useLocalizationSerializer'; export * from './useSettings'; +export * from './useSimpleStateCheck'; export * from './useValidation'; export * from './useWindowSizeFn'; diff --git a/apps/vben5/packages/@abp/core/src/hooks/useAuthorization.ts b/apps/vben5/packages/@abp/core/src/hooks/useAuthorization.ts new file mode 100644 index 000000000..af25aa55a --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/useAuthorization.ts @@ -0,0 +1,36 @@ +import type { IPermissionChecker } from '../types/permissions'; + +import { computed } from 'vue'; + +import { useAbpStore } from '../store/abp'; + +export function useAuthorization(): IPermissionChecker { + const abpStore = useAbpStore(); + const getGrantedPolicies = computed(() => { + return abpStore.application?.auth.grantedPolicies ?? {}; + }); + + function isGranted(name: string | string[], requiresAll?: boolean): boolean { + const grantedPolicies = getGrantedPolicies.value; + if (Array.isArray(name)) { + if (requiresAll === undefined || requiresAll === true) { + return name.every((name) => grantedPolicies[name]); + } + return name.some((name) => grantedPolicies[name]); + } + return grantedPolicies[name] ?? false; + } + + function authorize(name: string | string[]): void { + if (!isGranted(name)) { + throw new Error( + `Authorization failed! Given policy has not granted: ${name}`, + ); + } + } + + return { + authorize, + isGranted, + }; +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/useEventBus.ts b/apps/vben5/packages/@abp/core/src/hooks/useEventBus.ts new file mode 100644 index 000000000..a3339d12a --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/useEventBus.ts @@ -0,0 +1,30 @@ +import type { EventType, Handler, WildcardHandler } from '../utils/mitt'; + +import mitt from '../utils/mitt'; + +const emitter = mitt(); + +interface EventBus { + /** 发布事件 */ + publish(type: '*', event?: any): void; + /** 发布事件 */ + publish(type: EventType, event?: T): void; + + /** 订阅事件 */ + subscribe(type: '*', handler: WildcardHandler): void; + /** 订阅事件 */ + subscribe(type: EventType, handler: Handler): void; + + /** 退订事件 */ + unSubscribe(type: '*', handler: WildcardHandler): void; + /** 退订事件 */ + unSubscribe(type: EventType, handler: Handler): void; +} + +export function useEventBus(): EventBus { + return { + publish: emitter.emit, + subscribe: emitter.on, + unSubscribe: emitter.off, + }; +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/useFeatures.ts b/apps/vben5/packages/@abp/core/src/hooks/useFeatures.ts new file mode 100644 index 000000000..9b1048f3e --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/useFeatures.ts @@ -0,0 +1,72 @@ +import type { FeatureValue, IFeatureChecker } from '../types/features'; + +import { ref, watch } from 'vue'; + +import { useAbpStore } from '../store/abp'; + +export function useFeatures(): IFeatureChecker { + const abpStore = useAbpStore(); + + const features = ref([]); + + watch( + () => abpStore.application, + (application) => { + if (!application?.features.values) { + features.value = []; + return; + } + const featuresSet: FeatureValue[] = []; + Object.keys(application.features.values).forEach((name) => { + if (application.features.values[name]) { + featuresSet.push({ + name, + value: application.features.values[name], + }); + } + }); + features.value = featuresSet; + }, + { + deep: true, + immediate: true, + }, + ); + + function get(name: string): FeatureValue | undefined { + return features.value.find((feature) => name === feature.name); + } + + function _isEnabled(name: string): boolean { + const setting = get(name); + return setting?.value.toLowerCase() === 'true'; + } + + const featureChecker: IFeatureChecker = { + getOrEmpty(name: string) { + return get(name)?.value ?? ''; + }, + + isEnabled(featureNames: string | string[], requiresAll?: boolean) { + if (Array.isArray(featureNames)) { + if (featureNames.length === 0) return true; + if (requiresAll === undefined || requiresAll === true) { + for (const featureName of featureNames) { + if (!_isEnabled(featureName)) return false; + } + return true; + } + + for (const featureName of featureNames) { + if (_isEnabled(featureName)) return true; + } + } else { + return _isEnabled(featureNames); + } + + return false; + }, + }; + + return featureChecker; +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/useGlobalFeatures.ts b/apps/vben5/packages/@abp/core/src/hooks/useGlobalFeatures.ts new file mode 100644 index 000000000..49149a3ca --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/useGlobalFeatures.ts @@ -0,0 +1,52 @@ +import { computed } from 'vue'; + +import { useAbpStore } from '../store/abp'; +import { isNullOrWhiteSpace } from '../utils/string'; + +export function useGlobalFeatures() { + const abpStore = useAbpStore(); + const getGlobalFeatures = computed(() => { + if (!abpStore.application) { + return []; + } + const enabledFeatures = + abpStore.application.globalFeatures.enabledFeatures ?? []; + return enabledFeatures; + }); + + function get(name: string): string | undefined { + return getGlobalFeatures.value.find((feature) => name === feature); + } + + function _isEnabled(name: string): boolean { + const feature = get(name); + return !isNullOrWhiteSpace(feature); + } + + function isEnabled( + featureNames: string | string[], + requiresAll?: boolean, + ): boolean { + if (Array.isArray(featureNames)) { + if (featureNames.length === 0) return true; + if (requiresAll === undefined || requiresAll === true) { + for (const featureName of featureNames) { + if (!_isEnabled(featureName)) return false; + } + return true; + } + + for (const featureName of featureNames) { + if (_isEnabled(featureName)) return true; + } + } else { + return _isEnabled(featureNames); + } + + return false; + } + + return { + isEnabled, + }; +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/useLocalization.ts b/apps/vben5/packages/@abp/core/src/hooks/useLocalization.ts index 0067107c5..a9e21b08d 100644 --- a/apps/vben5/packages/@abp/core/src/hooks/useLocalization.ts +++ b/apps/vben5/packages/@abp/core/src/hooks/useLocalization.ts @@ -1,6 +1,6 @@ import type { Dictionary, StringLocalizer } from '../types'; -import { computed } from 'vue'; +import { computed, ref, watch } from 'vue'; import merge from 'lodash.merge'; @@ -9,24 +9,47 @@ import { format } from '../utils/string'; export function useLocalization(resourceNames?: string | string[]) { const abpStore = useAbpStore(); - const getResource = computed(() => { - if (!abpStore.application) { - return {}; - } - const { values } = abpStore.application.localization; + const localizations = ref>>({}); + + watch( + () => abpStore.localization, + (localization) => { + if (!localization?.resources) { + localizations.value = {}; + return; + } + const localizationResource: Dictionary< + string, + Dictionary + > = {}; + Object.keys(localization.resources).forEach((resourceName) => { + if (localization.resources[resourceName]) { + localizationResource[resourceName] = + localization.resources[resourceName].texts; + } + }); + localizations.value = localizationResource; + }, + { + deep: true, + immediate: true, + }, + ); + + const getResource = computed(() => { let resource: { [key: string]: string } = {}; if (resourceNames) { if (Array.isArray(resourceNames)) { resourceNames.forEach((name) => { - resource = merge(resource, values[name]); + resource = merge(resource, localizations.value[name]); }); } else { - resource = merge(resource, values[resourceNames]); + resource = merge(resource, localizations.value[resourceNames]); } } else { - Object.keys(values).forEach((rs) => { - resource = merge(resource, values[rs]); + Object.keys(localizations.value).forEach((rs) => { + resource = merge(resource, localizations.value[rs]); }); } @@ -34,11 +57,7 @@ export function useLocalization(resourceNames?: string | string[]) { }); const getResourceByName = computed(() => { return (resource: string): Dictionary => { - if (!abpStore.application) { - return {}; - } - const { values } = abpStore.application.localization; - return values[resource] ?? {}; + return localizations.value[resource] ?? {}; }; }); diff --git a/apps/vben5/packages/@abp/core/src/hooks/useLocalizationSerializer.ts b/apps/vben5/packages/@abp/core/src/hooks/useLocalizationSerializer.ts new file mode 100644 index 000000000..7b37a5008 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/useLocalizationSerializer.ts @@ -0,0 +1,109 @@ +import type { LocalizableStringInfo } from '../types'; + +import { isNullOrWhiteSpace } from '../utils/string'; + +interface ValidateOptions { + required?: boolean; +} + +interface ILocalizableStringSerializer { + deserialize(value?: string): LocalizableStringInfo; + serialize(value?: LocalizableStringInfo): string; + validate(value?: string, opt?: ValidateOptions): boolean; +} + +export function useLocalizationSerializer(): ILocalizableStringSerializer { + function Validate(value?: string, opt?: ValidateOptions): boolean { + if (!value || isNullOrWhiteSpace(value)) { + if (!opt || opt.required === undefined || opt.required === true) { + return false; + } + return true; + } + if (value.length < 3 || value[1] !== ':') { + return false; + } + const type = value[0]; + switch (type) { + case 'F': { + return !isNullOrWhiteSpace(value.slice(2).trim()); + } + case 'L': { + const commaPosition = value.indexOf(',', 2); + if (commaPosition === -1) { + return false; + } + const name = value.slice(Math.max(0, commaPosition + 1)); + if (isNullOrWhiteSpace(name)) { + return false; + } + return true; + } + default: { + return false; + } + } + } + + function Serialize(value?: LocalizableStringInfo): string { + if (!value) return ''; + return `L:${value.resourceName},${value.name}`; + } + + function Deserialize(value?: string): LocalizableStringInfo { + if (!value || isNullOrWhiteSpace(value)) { + return { + name: '', + resourceName: '', + }; + } + if (value.length < 2 || value[1] !== ':') { + return { + name: value, + resourceName: '', + }; + } + const type = value[0]; + switch (type) { + case 'F': { + return { + name: value.slice(2), + resourceName: 'Fixed', + }; + } + case 'L': { + const commaPosition = value.indexOf(',', 2); + if (commaPosition === -1) { + return { + name: value, + resourceName: 'Default', + }; + } + const resourceName = value.slice(2, commaPosition); + const name = value.slice(Math.max(0, commaPosition + 1)); + if (isNullOrWhiteSpace(resourceName)) { + return { + name: value, + resourceName: 'Default', + }; + } + return { + name, + resourceName, + }; + } + default: { + return { + name: value, + resourceName: 'Default', + }; + } + } + } + + return { + deserialize: Deserialize, + serialize: Serialize, + validate: Validate, + }; +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/useSettings.ts b/apps/vben5/packages/@abp/core/src/hooks/useSettings.ts index a573d3c23..cca3d77e2 100644 --- a/apps/vben5/packages/@abp/core/src/hooks/useSettings.ts +++ b/apps/vben5/packages/@abp/core/src/hooks/useSettings.ts @@ -1,37 +1,47 @@ import type { ISettingProvider, SettingValue } from '../types/settings'; -import { computed } from 'vue'; +import { ref, watch } from 'vue'; import { useAbpStore } from '../store'; export function useSettings(): ISettingProvider { - const getSettings = computed(() => { - const abpStore = useAbpStore(); - if (!abpStore.application) { - return []; - } - const { values: settings } = abpStore.application.setting; - const settingValues = Object.keys(settings).map((key): SettingValue => { - return { - name: key, - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion - value: settings[key]!, - }; - }); - return settingValues; - }); + const abpStore = useAbpStore(); + + const settings = ref([]); + + watch( + () => abpStore.application, + (application) => { + if (!application?.setting.values) { + settings.value = []; + return; + } + const settingsSet: SettingValue[] = []; + Object.keys(application.setting.values).forEach((name) => { + if (application.setting.values[name]) { + settingsSet.push({ + name, + value: application.setting.values[name], + }); + } + }); + settings.value = settingsSet; + }, + { + deep: true, + immediate: true, + }, + ); function get(name: string): SettingValue | undefined { - return getSettings.value.find((setting) => name === setting.name); + return settings.value.find((setting) => name === setting.name); } function getAll(...names: string[]): SettingValue[] { if (names) { - return getSettings.value.filter((setting) => - names.includes(setting.name), - ); + return settings.value.filter((setting) => names.includes(setting.name)); } - return getSettings.value; + return settings.value; } function getOrDefault(name: string, defaultValue: T): string | T { diff --git a/apps/vben5/packages/@abp/core/src/hooks/useSimpleStateCheck.ts b/apps/vben5/packages/@abp/core/src/hooks/useSimpleStateCheck.ts new file mode 100644 index 000000000..f7b681b67 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/hooks/useSimpleStateCheck.ts @@ -0,0 +1,136 @@ +import type { + IHasSimpleStateCheckers, + ISimpleStateChecker, + ISimpleStateCheckerSerializer, +} from '../types/global'; + +import { isNullOrUnDef } from '../utils/is'; +import { isNullOrWhiteSpace } from '../utils/string'; +import { useRequireAuthenticatedSimpleStateChecker } from './SimpleStateChecking/useRequireAuthenticatedSimpleStateChecker'; +import { useRequireFeaturesSimpleStateChecker } from './SimpleStateChecking/useRequireFeaturesSimpleStateChecker'; +import { useRequireGlobalFeaturesSimpleStateChecker } from './SimpleStateChecking/useRequireGlobalFeaturesSimpleStateChecker'; +import { useRequirePermissionsSimpleStateChecker } from './SimpleStateChecking/useRequirePermissionsSimpleStateChecker'; + +export function useSimpleStateCheck< + TState extends IHasSimpleStateCheckers, +>(): ISimpleStateCheckerSerializer { + function deserialize>( + jsonObject: any, + state: TState, + ): ISimpleStateChecker | undefined { + if (isNullOrUnDef(jsonObject) || !Reflect.has(jsonObject, 'T')) { + return undefined; + } + switch (String(jsonObject.T)) { + case 'A': { + return useRequireAuthenticatedSimpleStateChecker(); + } + case 'F': { + const features = jsonObject.N as string[]; + if (features === undefined) { + throw new Error( + `'N' is not an array in the serialized state checker! JsonObject: ${ + jsonObject + }`, + ); + } + return useRequireFeaturesSimpleStateChecker( + features, + jsonObject.A === true, + ); + } + case 'G': { + const globalFeatures = jsonObject.N as string[]; + if (globalFeatures === undefined) { + throw new Error( + `'N' is not an array in the serialized state checker! JsonObject: ${ + jsonObject + }`, + ); + } + return useRequireGlobalFeaturesSimpleStateChecker( + globalFeatures, + jsonObject.A === true, + ); + } + case 'P': { + const permissions = jsonObject.N as string[]; + if (permissions === undefined) { + throw new Error( + `'N' is not an array in the serialized state checker! JsonObject: ${ + jsonObject + }`, + ); + } + return useRequirePermissionsSimpleStateChecker({ + permissions, + requiresAll: jsonObject.A === true, + state, + }); + } + default: { + return undefined; + } + } + } + + function deserializeArray>( + value: string, + state: TState, + ): ISimpleStateChecker[] { + if (isNullOrWhiteSpace(value)) return []; + const jsonObject = JSON.parse(value); + if (isNullOrUnDef(jsonObject)) return []; + if (Array.isArray(jsonObject)) { + if (jsonObject.length === 0) return []; + return jsonObject + .map((json) => deserialize(json, state)) + .filter((checker) => !isNullOrUnDef(checker)) + .map((checker) => checker); + } + const stateChecker = deserialize(jsonObject, state); + if (!stateChecker) return []; + return [stateChecker]; + } + + function serialize>( + checker: ISimpleStateChecker, + ): string | undefined { + return checker.serialize(); + } + + function serializeArray>( + stateCheckers: ISimpleStateChecker[], + ): string | undefined { + if (stateCheckers.length === 0) return undefined; + if (stateCheckers.length === 1) { + const stateChecker = stateCheckers[0]; + const single = stateChecker?.serialize(); + if (isNullOrUnDef(single)) return undefined; + return `[${single}]`; + } + let serializedCheckers: string = ''; + stateCheckers.forEach((checker) => { + const serializedChecker = checker.serialize(); + if (!isNullOrUnDef(serializedChecker)) { + serializedCheckers += `${serializedChecker},`; + } + }); + if (serializedCheckers.endsWith(',')) { + serializedCheckers = serializedCheckers.slice( + 0, + Math.max(0, serializedCheckers.length - 1), + ); + } + return serializedCheckers.length > 0 + ? `[${serializedCheckers}]` + : undefined; + } + + return { + deserialize, + deserializeArray, + serialize, + serializeArray, + }; +} diff --git a/apps/vben5/packages/@abp/core/src/hooks/useValidation.ts b/apps/vben5/packages/@abp/core/src/hooks/useValidation.ts index 8a04e63e7..4e18afba0 100644 --- a/apps/vben5/packages/@abp/core/src/hooks/useValidation.ts +++ b/apps/vben5/packages/@abp/core/src/hooks/useValidation.ts @@ -17,7 +17,7 @@ import { ValidationEnum } from '../constants'; import { isEmail, isPhone } from '../utils/regex'; import { useLocalization } from './useLocalization'; -export function useValidation() { +export function useValidation(): RuleCreator { const { L } = useLocalization(['AbpValidation']); function _getFieldName(field: Field) { return __getFieldName( @@ -129,7 +129,7 @@ export function useValidation() { required?: boolean, ): Rule { const message = field.name - ? L(useNameEnum, [_getFieldName(field), field.minimum, field.maximum]) + ? L(useNameEnum, [_getFieldName(field), field.maximum, field.minimum]) : L(notNameEnum, [field.minimum, field.maximum]); return { message, @@ -397,9 +397,13 @@ export function useValidation() { ), ]; }, + mapEnumValidMessage( + enumName: string, + args?: any[] | Record | undefined, + ) { + return L(enumName, args); + }, }; - return { - ruleCreator, - }; + return ruleCreator; } diff --git a/apps/vben5/packages/@abp/core/src/store/abp.ts b/apps/vben5/packages/@abp/core/src/store/abp.ts index 8d035181d..f17801928 100644 --- a/apps/vben5/packages/@abp/core/src/store/abp.ts +++ b/apps/vben5/packages/@abp/core/src/store/abp.ts @@ -52,7 +52,12 @@ export const useAbpStore = defineStore( localization.value = val; } + function $reset() { + application.value = undefined; + } + return { + $reset, application, getI18nLocales, localization, diff --git a/apps/vben5/packages/@abp/core/src/types/dto.ts b/apps/vben5/packages/@abp/core/src/types/dto.ts index 41d17932f..7adcb9e67 100644 --- a/apps/vben5/packages/@abp/core/src/types/dto.ts +++ b/apps/vben5/packages/@abp/core/src/types/dto.ts @@ -1,15 +1,15 @@ -import { - type Clock, - type CurrentCulture, - type CurrentTenant, - type CurrentUser, - type Dictionary, - type ExtraPropertyDictionary, - type IHasExtraProperties, - type LanguageInfo, - type MultiTenancyInfo, - type NameValue, - type TimeZone, +import type { + Clock, + CurrentCulture, + CurrentTenant, + CurrentUser, + Dictionary, + ExtraPropertyDictionary, + IHasExtraProperties, + LanguageInfo, + MultiTenancyInfo, + NameValue, + TimeZone, } from './global'; /** 包装器数据传输对象 */ interface WrapResult { @@ -47,6 +47,7 @@ interface RemoteServiceErrorInfo { } /** 扩展属性数据传输对象 */ interface ExtensibleObject { + [key: string]: any; /** 扩展属性 */ extraProperties: ExtraPropertyDictionary; } @@ -102,7 +103,7 @@ interface FullAuditedEntityWithUserDto deleter: TUserDto; } /** 实体扩展属性数据传输对象 */ -interface ExtensibleEntityDto extends ExtensibleObject, EntityDto {} +interface ExtensibleEntityDto extends EntityDto, ExtensibleObject {} /** 实体新增扩展属性数据传输对象 */ interface ExtensibleCreationAuditedEntityDto extends CreationAuditedEntityDto, @@ -121,12 +122,12 @@ interface ExtensibleAuditedEntityWithUserDto ExtensibleEntityDto {} /** 实体审计全属性扩展数据传输对象 */ interface ExtensibleFullAuditedEntityDto - extends FullAuditedEntityDto, - ExtensibleEntityDto {} + extends ExtensibleEntityDto, + FullAuditedEntityDto {} /** 实体审计用户全属性扩展数据传输对象 */ interface ExtensibleFullAuditedEntityWithUserDto - extends FullAuditedEntityWithUserDto, - ExtensibleEntityDto {} + extends ExtensibleEntityDto, + FullAuditedEntityWithUserDto {} /** 最大请求数据传输对象 */ interface LimitedResultRequestDto { /** 最大返回数据大小 */ @@ -134,8 +135,8 @@ interface LimitedResultRequestDto { } /** 最大请求扩展数据传输对象 */ interface ExtensibleLimitedResultRequestDto - extends LimitedResultRequestDto, - ExtensibleObject {} + extends ExtensibleObject, + LimitedResultRequestDto {} /** 排序请求数据传输对象 */ interface SortedResultRequest { /** 排序字段 @@ -160,8 +161,8 @@ interface PagedAndSortedResultRequestDto SortedResultRequest {} /** 分页排序请求扩展数据传输对象 */ interface ExtensiblePagedAndSortedResultRequestDto - extends PagedAndSortedResultRequestDto, - ExtensibleObject {} + extends ExtensibleObject, + PagedAndSortedResultRequestDto {} /** 列表数据传输对象 */ interface ListResultDto { /** 返回项目列表 */ @@ -169,8 +170,8 @@ interface ListResultDto { } /** 列表扩展数据传输对象 */ interface ExtensibleListResultDto - extends ListResultDto, - ExtensibleObject {} + extends ExtensibleObject, + ListResultDto {} /** 分页列表数据传输对象 */ interface PagedResultDto extends ListResultDto { /** 符合条件的最大数量 */ @@ -178,12 +179,12 @@ interface PagedResultDto extends ListResultDto { } /** 分页列表扩展数据传输对象 */ interface ExtensiblePagedResultDto - extends PagedResultDto, - ExtensibleObject {} + extends ExtensibleObject, + PagedResultDto {} /** 分页列表扩展数据传输对象 */ interface ExtensiblePagedResultRequestDto - extends PagedResultRequestDto, - ExtensibleObject {} + extends ExtensibleObject, + PagedResultRequestDto {} /** 应用程序本地化资源数据传输对象 */ interface ApplicationLocalizationResourceDto { /** 继承资源名称列表 */ diff --git a/apps/vben5/packages/@abp/core/src/types/error.ts b/apps/vben5/packages/@abp/core/src/types/error.ts new file mode 100644 index 000000000..a51bf5d9e --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/types/error.ts @@ -0,0 +1,14 @@ +interface RemoteServiceValidationErrorInfo { + members: string[]; + message: string; +} + +interface RemoteServiceErrorInfo { + code?: string; + data?: Record; + details?: string; + message?: string; + validationErrors?: RemoteServiceValidationErrorInfo[]; +} + +export type { RemoteServiceErrorInfo }; diff --git a/apps/vben5/packages/@abp/core/src/types/features.ts b/apps/vben5/packages/@abp/core/src/types/features.ts new file mode 100644 index 000000000..d46b26a58 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/types/features.ts @@ -0,0 +1,27 @@ +import type { NameValue } from './global'; + +type FeatureValue = NameValue; + +/** + * 特性检查接口 + */ +interface IFeatureChecker { + /** + * 获取特性值 + * @param name 特性名称 + * @returns 返回设定的特性值,不存在则为空字符串 + */ + getOrEmpty(name: string): string; + /** + * 是否启用特性 + * @param featureNames 特性名称 + * @param requiresAll 是否全部符合 + */ + isEnabled(featureNames: string | string[], requiresAll?: boolean): boolean; +} + +interface IGlobalFeatureChecker { + isEnabled(featureNames: string | string[], requiresAll?: boolean): boolean; +} + +export type { FeatureValue, IFeatureChecker, IGlobalFeatureChecker }; diff --git a/apps/vben5/packages/@abp/core/src/types/global.ts b/apps/vben5/packages/@abp/core/src/types/global.ts index b0ab7d8b1..4230d7337 100644 --- a/apps/vben5/packages/@abp/core/src/types/global.ts +++ b/apps/vben5/packages/@abp/core/src/types/global.ts @@ -43,6 +43,7 @@ interface IHasExtraProperties { } /** 选择项 */ interface ISelectionStringValueItem { + [key: string]: any; /** 选择项显示文本多语言对象 */ displayText: LocalizableStringInfo; /** 选择项值 */ @@ -206,31 +207,35 @@ interface CurrentUser { userName: string; } -// eslint-disable-next-line no-use-before-define +interface IHasSimpleStateCheckers< + TState extends IHasSimpleStateCheckers, +> { + // eslint-disable-next-line no-use-before-define + stateCheckers: ISimpleStateChecker[]; +} + +type SimpleStateRecord< + TState extends IHasSimpleStateCheckers, + TValue, +> = { + [P in TState]: TValue; +}; + type SimpleStateCheckerResult> = - Map; + SimpleStateRecord; interface SimpleStateCheckerContext< - // eslint-disable-next-line no-use-before-define TState extends IHasSimpleStateCheckers, > { state: TState; } interface SimpleBatchStateCheckerContext< - // eslint-disable-next-line no-use-before-define TState extends IHasSimpleStateCheckers, > { states: TState[]; } -interface IHasSimpleStateCheckers< - TState extends IHasSimpleStateCheckers, -> { - // eslint-disable-next-line no-use-before-define - stateCheckers: ISimpleStateChecker[]; -} - interface ISimpleStateChecker> { isEnabled(context: SimpleStateCheckerContext): boolean; serialize(): string | undefined; diff --git a/apps/vben5/packages/@abp/core/src/types/index.ts b/apps/vben5/packages/@abp/core/src/types/index.ts index cde3fc4a5..e31262935 100644 --- a/apps/vben5/packages/@abp/core/src/types/index.ts +++ b/apps/vben5/packages/@abp/core/src/types/index.ts @@ -1,6 +1,10 @@ export * from './dto'; +export * from './error'; +export * from './features'; export * from './global'; export * from './localization'; +export * from './openid'; +export * from './permissions'; export * from './rules'; export * from './settings'; export * from './table'; diff --git a/apps/vben5/packages/@abp/core/src/types/openid.ts b/apps/vben5/packages/@abp/core/src/types/openid.ts new file mode 100644 index 000000000..e5bfca3f8 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/types/openid.ts @@ -0,0 +1,28 @@ +interface OpenIdConfiguration { + authorization_endpoint: string; + backchannel_logout_session_supported: boolean; + backchannel_logout_supported: boolean; + check_session_iframe: string; + claims_supported: string[]; + code_challenge_methods_supported: string[]; + device_authorization_endpoint: string; + end_session_endpoint: string; + frontchannel_logout_session_supported: boolean; + frontchannel_logout_supported: boolean; + grant_types_supported: string[]; + id_token_signing_alg_values_supported: string[]; + introspection_endpoint: string; + issuer: string; + jwks_uri: string; + request_parameter_supported: boolean; + response_modes_supported: string[]; + response_types_supported: string[]; + revocation_endpoint: string; + scopes_supported: string[]; + subject_types_supported: string[]; + token_endpoint: string; + token_endpoint_auth_methods_supported: string[]; + userinfo_endpoint: string; +} + +export type { OpenIdConfiguration }; diff --git a/apps/vben5/packages/@abp/core/src/types/permissions.ts b/apps/vben5/packages/@abp/core/src/types/permissions.ts new file mode 100644 index 000000000..cfc062872 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/types/permissions.ts @@ -0,0 +1,6 @@ +interface IPermissionChecker { + authorize(name: string | string[]): void; + isGranted(name: string | string[], requiresAll?: boolean): boolean; +} + +export type { IPermissionChecker }; diff --git a/apps/vben5/packages/@abp/core/src/types/rules.ts b/apps/vben5/packages/@abp/core/src/types/rules.ts index aef6ed573..3737cc5fb 100644 --- a/apps/vben5/packages/@abp/core/src/types/rules.ts +++ b/apps/vben5/packages/@abp/core/src/types/rules.ts @@ -45,6 +45,11 @@ interface RuleCreator { fieldOnlyAcceptsFilesExtensions(field: FieldContains): Rule[]; /** 字段{0}不可为空 */ fieldRequired(field: Field): Rule[]; + /** 获取一个错误枚举验证消息 */ + mapEnumValidMessage( + enumName: string, + args?: any[] | Record | undefined, + ): string; } export type { RuleCreator }; diff --git a/apps/vben5/packages/@abp/core/src/utils/array.ts b/apps/vben5/packages/@abp/core/src/utils/array.ts new file mode 100644 index 000000000..b766b0680 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/utils/array.ts @@ -0,0 +1 @@ +export { default as groupBy } from 'lodash.groupby'; diff --git a/apps/vben5/packages/@abp/core/src/utils/index.ts b/apps/vben5/packages/@abp/core/src/utils/index.ts index 202185507..4c7bf48a5 100644 --- a/apps/vben5/packages/@abp/core/src/utils/index.ts +++ b/apps/vben5/packages/@abp/core/src/utils/index.ts @@ -1,4 +1,7 @@ +export * from './array'; export * from './date'; +export * from './is'; +export * from './mitt'; export * from './regex'; export * from './string'; export * from './tree'; diff --git a/apps/vben5/packages/@abp/core/src/utils/is.ts b/apps/vben5/packages/@abp/core/src/utils/is.ts new file mode 100644 index 000000000..c760f4afa --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/utils/is.ts @@ -0,0 +1,19 @@ +export function isNullAndUnDef(val: unknown): val is null | undefined { + return isUnDef(val) && isNull(val); +} + +export function isNullOrUnDef(val: unknown): val is null | undefined { + return isUnDef(val) || isNull(val); +} + +export function isDef(val?: T): val is T { + return val !== undefined; +} + +export function isUnDef(val?: T): val is T { + return !isDef(val); +} + +export function isNull(value: any): value is null { + return value === null; +} diff --git a/apps/vben5/packages/@abp/core/src/utils/mitt.ts b/apps/vben5/packages/@abp/core/src/utils/mitt.ts new file mode 100644 index 000000000..28668e4d2 --- /dev/null +++ b/apps/vben5/packages/@abp/core/src/utils/mitt.ts @@ -0,0 +1,107 @@ +/* eslint-disable array-callback-return */ +/** + * copy to https://github.com/developit/mitt + * Expand clear method + */ + +export type EventType = string | symbol; + +// An event handler can take an optional event argument +// and should not return a value +export type Handler = (event?: T) => void; +export type WildcardHandler = (type: EventType, event?: any) => void; + +// An array of all currently registered event handlers for a type +export type EventHandlerList = Array; +export type WildCardEventHandlerList = Array; + +// A map of event types and their corresponding event handlers. +export type EventHandlerMap = Map< + EventType, + EventHandlerList | WildCardEventHandlerList +>; + +export interface Emitter { + all: EventHandlerMap; + + clear(): void; + emit(type: '*', event?: any): void; + + emit(type: EventType, event?: T): void; + off(type: '*', handler: WildcardHandler): void; + + off(type: EventType, handler: Handler): void; + on(type: '*', handler: WildcardHandler): void; + on(type: EventType, handler: Handler): void; +} + +/** + * Mitt: Tiny (~200b) functional event emitter / pubsub. + * @name mitt + * @returns {Mitt} Emitter + */ +export default function mitt(all?: EventHandlerMap): Emitter { + all = all || new Map(); + + return { + /** + * A Map of event names to registered handler functions. + */ + all, + + /** + * Clear all + */ + clear() { + this.all.clear(); + }, + + /** + * Invoke all handlers for the given type. + * If present, `"*"` handlers are invoked after type-matched handlers. + * + * Note: Manually firing "*" handlers is not supported. + * + * @param {string|symbol} type The event type to invoke + * @param {Any} [evt] Any value (object is recommended and powerful), passed to each handler + * @memberOf mitt + */ + emit(type: EventType, evt: T) { + [...((all?.get(type) || []) as EventHandlerList)].map((handler) => { + handler(evt); + }); + [...((all?.get('*') || []) as WildCardEventHandlerList)].map( + (handler) => { + handler(type, evt); + }, + ); + }, + + /** + * Remove an event handler for the given type. + * @param {string|symbol} type Type of event to unregister `handler` from, or `"*"` + * @param {Function} handler Handler function to remove + * @memberOf mitt + */ + off(type: EventType, handler: Handler) { + const handlers = all?.get(type); + if (handlers) { + handlers.splice(handlers.indexOf(handler) >>> 0, 1); + } + }, + + /** + * Register an event handler for the given type. + * @param {string|symbol} type Type of event to listen for, or `"*"` for all events + * @param {Function} handler Function to call in response to given event + * @memberOf mitt + */ + on(type: EventType, handler: Handler) { + const handlers = all?.get(type); + const added = handlers && handlers.push(handler); + if (!added) { + all?.set(type, [handler]); + } + }, + }; +} diff --git a/apps/vben5/packages/@abp/core/src/utils/tree.ts b/apps/vben5/packages/@abp/core/src/utils/tree.ts index be64f1c92..7af084394 100644 --- a/apps/vben5/packages/@abp/core/src/utils/tree.ts +++ b/apps/vben5/packages/@abp/core/src/utils/tree.ts @@ -18,20 +18,28 @@ export function listToTree( config: Partial = {}, ): T[] { const conf = getConfig(config) as TreeHelperConfig; - const nodeMap = new Map(); - const result: T[] = []; + const map: { [key: string]: any } = {}; + const roots: any[] = []; const { id, pid, children } = conf; - for (const node of list) { - node[children] = node[children] || []; - nodeMap.set(node[id], node); - } - for (const node of list) { - const parent = nodeMap.get(node[pid]); - (parent ? parent[children] : result).push(node); - if (parent) { - parent.hasChildren = true; + // 将每个元素放入map中,方便通过id查找 + list.forEach((item) => { + map[item[id]] = { ...item, [children]: [] }; + }); + + // 构建树形结构 + list.forEach((item) => { + const parentId = item[pid]; + if (parentId === null || parentId === undefined) { + // 根节点 + roots.push(map[item[id]]); + } else { + // 非根节点,将其添加到父节点的children数组中 + if (map[parentId]) { + map[parentId][children].push(map[item[id]]); + } } - } - return result; + }); + + return roots; } diff --git a/apps/vben5/packages/@abp/features/package.json b/apps/vben5/packages/@abp/features/package.json new file mode 100644 index 000000000..c44657431 --- /dev/null +++ b/apps/vben5/packages/@abp/features/package.json @@ -0,0 +1,39 @@ +{ + "name": "@abp/features", + "version": "9.0.4", + "homepage": "https://github.com/colinin/abp-next-admin", + "bugs": "https://github.com/colinin/abp-next-admin/issues", + "repository": { + "type": "git", + "url": "git+https://github.com/colinin/abp-next-admin.git", + "directory": "packages/@abp/features" + }, + "license": "MIT", + "type": "module", + "sideEffects": [ + "**/*.css" + ], + "exports": { + ".": { + "types": "./src/index.ts", + "default": "./src/index.ts" + } + }, + "dependencies": { + "@abp/core": "workspace:*", + "@abp/request": "workspace:*", + "@abp/ui": "workspace:*", + "@ant-design/icons-vue": "catalog:", + "@vben/access": "workspace:*", + "@vben/common-ui": "workspace:*", + "@vben/hooks": "workspace:*", + "@vben/icons": "workspace:*", + "@vben/locales": "workspace:*", + "@vben/utils": "workspace:*", + "ant-design-vue": "catalog:", + "dayjs": "catalog:", + "vue": "catalog:*", + "vxe-table": "catalog:" + }, + "devDependencies": {} +} diff --git a/apps/vben5/packages/@abp/features/src/api/index.ts b/apps/vben5/packages/@abp/features/src/api/index.ts new file mode 100644 index 000000000..4287d4768 --- /dev/null +++ b/apps/vben5/packages/@abp/features/src/api/index.ts @@ -0,0 +1,3 @@ +export { useFeatureDefinitionsApi } from './useFeatureDefinitionsApi'; +export { useFeatureGroupDefinitionsApi } from './useFeatureGroupDefinitionsApi'; +export { useFeaturesApi } from './useFeaturesApi'; diff --git a/apps/vben5/packages/@abp/features/src/api/useFeatureDefinitionsApi.ts b/apps/vben5/packages/@abp/features/src/api/useFeatureDefinitionsApi.ts new file mode 100644 index 000000000..165af3aff --- /dev/null +++ b/apps/vben5/packages/@abp/features/src/api/useFeatureDefinitionsApi.ts @@ -0,0 +1,100 @@ +import type { ListResultDto } from '@abp/core'; + +import type { + FeatureDefinitionCreateDto, + FeatureDefinitionDto, + FeatureDefinitionGetListInput, + FeatureDefinitionUpdateDto, +} from '../types/definitions'; + +import { useRequest } from '@abp/request'; + +export function useFeatureDefinitionsApi() { + const { cancel, request } = useRequest(); + + /** + * 删除功能定义 + * @param name 功能名称 + */ + function deleteApi(name: string): Promise { + return request(`/api/feature-management/definitions/${name}`, { + method: 'DELETE', + }); + } + + /** + * 查询功能定义 + * @param name 功能名称 + * @returns 功能定义数据传输对象 + */ + function getApi(name: string): Promise { + return request( + `/api/feature-management/definitions/${name}`, + { + method: 'GET', + }, + ); + } + + /** + * 查询功能定义列表 + * @param input 功能过滤条件 + * @returns 功能定义数据传输对象列表 + */ + function getListApi( + input?: FeatureDefinitionGetListInput, + ): Promise> { + return request>( + `/api/feature-management/definitions`, + { + method: 'GET', + params: input, + }, + ); + } + + /** + * 创建功能定义 + * @param input 功能定义参数 + * @returns 功能定义数据传输对象 + */ + function createApi( + input: FeatureDefinitionCreateDto, + ): Promise { + return request( + '/api/feature-management/definitions', + { + data: input, + method: 'POST', + }, + ); + } + + /** + * 更新功能定义 + * @param name 功能名称 + * @param input 功能定义参数 + * @returns 功能定义数据传输对象 + */ + function updateApi( + name: string, + input: FeatureDefinitionUpdateDto, + ): Promise { + return request( + `/api/feature-management/definitions/${name}`, + { + data: input, + method: 'PUT', + }, + ); + } + + return { + cancel, + createApi, + deleteApi, + getApi, + getListApi, + updateApi, + }; +} diff --git a/apps/vben5/packages/@abp/features/src/api/useFeatureGroupDefinitionsApi.ts b/apps/vben5/packages/@abp/features/src/api/useFeatureGroupDefinitionsApi.ts new file mode 100644 index 000000000..a3f19ef6c --- /dev/null +++ b/apps/vben5/packages/@abp/features/src/api/useFeatureGroupDefinitionsApi.ts @@ -0,0 +1,100 @@ +import type { ListResultDto } from '@abp/core'; + +import type { + FeatureGroupDefinitionCreateDto, + FeatureGroupDefinitionDto, + FeatureGroupDefinitionGetListInput, + FeatureGroupDefinitionUpdateDto, +} from '../types/groups'; + +import { useRequest } from '@abp/request'; + +export function useFeatureGroupDefinitionsApi() { + const { cancel, request } = useRequest(); + + /** + * 删除功能定义 + * @param name 功能名称 + */ + function deleteApi(name: string): Promise { + return request(`/api/feature-management/definitions/groups/${name}`, { + method: 'DELETE', + }); + } + + /** + * 查询功能定义 + * @param name 功能名称 + * @returns 功能定义数据传输对象 + */ + function getApi(name: string): Promise { + return request( + `/api/feature-management/definitions/groups/${name}`, + { + method: 'GET', + }, + ); + } + + /** + * 查询功能定义列表 + * @param input 功能过滤条件 + * @returns 功能定义数据传输对象列表 + */ + function getListApi( + input?: FeatureGroupDefinitionGetListInput, + ): Promise> { + return request>( + `/api/feature-management/definitions/groups`, + { + method: 'GET', + params: input, + }, + ); + } + + /** + * 创建功能定义 + * @param input 功能定义参数 + * @returns 功能定义数据传输对象 + */ + function createApi( + input: FeatureGroupDefinitionCreateDto, + ): Promise { + return request( + '/api/feature-management/definitions/groups', + { + data: input, + method: 'POST', + }, + ); + } + + /** + * 更新功能定义 + * @param name 功能名称 + * @param input 功能定义参数 + * @returns 功能定义数据传输对象 + */ + function updateApi( + name: string, + input: FeatureGroupDefinitionUpdateDto, + ): Promise { + return request( + `/api/feature-management/definitions/groups/${name}`, + { + data: input, + method: 'PUT', + }, + ); + } + + return { + cancel, + createApi, + deleteApi, + getApi, + getListApi, + updateApi, + }; +} diff --git a/apps/vben5/packages/@abp/features/src/api/useFeaturesApi.ts b/apps/vben5/packages/@abp/features/src/api/useFeaturesApi.ts new file mode 100644 index 000000000..116817733 --- /dev/null +++ b/apps/vben5/packages/@abp/features/src/api/useFeaturesApi.ts @@ -0,0 +1,62 @@ +import type { + FeatureProvider, + GetFeatureListResultDto, + UpdateFeaturesDto, +} from '../types/features'; + +import { useRequest } from '@abp/request'; + +export function useFeaturesApi() { + const { cancel, request } = useRequest(); + + /** + * 删除功能 + * @param {FeatureProvider} provider 参数 + * @returns {Promise} + */ + function deleteApi(provider: FeatureProvider): Promise { + return request(`/api/feature-management/features`, { + method: 'DELETE', + params: provider, + }); + } + + /** + * 查询功能 + * @param {FeatureProvider} provider 参数 + * @returns {Promise} 功能实体数据传输对象 + */ + function getApi(provider: FeatureProvider): Promise { + return request( + `/api/feature-management/features`, + { + method: 'GET', + params: provider, + }, + ); + } + + /** + * 更新功能 + * @param {FeatureProvider} provider + * @param {UpdateFeaturesDto} input 参数 + * @returns {Promise} + */ + function updateApi( + provider: FeatureProvider, + input: UpdateFeaturesDto, + ): Promise { + return request(`/api/feature-management/features`, { + data: input, + method: 'PUT', + params: provider, + }); + } + + return { + cancel, + deleteApi, + getApi, + updateApi, + }; +} diff --git a/apps/vben5/packages/@abp/features/src/components/definitions/features/FeatureDefinitionModal.vue b/apps/vben5/packages/@abp/features/src/components/definitions/features/FeatureDefinitionModal.vue new file mode 100644 index 000000000..0fe59c2a4 --- /dev/null +++ b/apps/vben5/packages/@abp/features/src/components/definitions/features/FeatureDefinitionModal.vue @@ -0,0 +1,467 @@ + + +