Commit 9fc6e0f00b7f795e7843e8613f161f84d4a1d528

Authored by xingyu4j
1 parent 02174383

refactor: springdoc 替换 springfox

Showing 469 changed files with 3315 additions and 3719 deletions

Too many changes.

To preserve performance only 100 of 469 files are displayed.

yudao-dependencies/pom.xml
... ... @@ -18,8 +18,8 @@
18 18 <!-- 统一依赖管理 -->
19 19 <spring.boot.version>2.7.6</spring.boot.version>
20 20 <!-- Web 相关 -->
  21 + <springdoc.version>1.6.13</springdoc.version>
21 22 <knife4j.version>3.0.3</knife4j.version>
22   - <swagger-annotations.version>1.6.8</swagger-annotations.version>
23 23 <servlet.versoin>2.5</servlet.versoin>
24 24 <!-- DB 相关 -->
25 25 <druid.version>1.2.15</druid.version>
... ... @@ -158,28 +158,21 @@
158 158 </dependency>
159 159  
160 160 <dependency>
161   - <groupId>com.github.xiaoymin</groupId>
162   - <artifactId>knife4j-spring-boot-starter</artifactId>
163   - <version>${knife4j.version}</version>
164   - <exclusions>
165   - <exclusion>
166   - <artifactId>mapstruct</artifactId>
167   - <groupId>org.mapstruct</groupId> <!-- 避免冲突 -->
168   - </exclusion>
169   - <exclusion>
170   - <artifactId>guava</artifactId>
171   - <groupId>com.google.guava</groupId>
172   - </exclusion>
173   - <exclusion>
174   - <artifactId>swagger-annotations</artifactId>
175   - <groupId>io.swagger</groupId>
176   - </exclusion>
177   - </exclusions>
  161 + <groupId>org.springdoc</groupId>
  162 + <artifactId>springdoc-openapi-webmvc-core</artifactId>
  163 + <version>${springdoc.version}</version>
  164 + </dependency>
  165 +
  166 + <dependency>
  167 + <groupId>org.springdoc</groupId>
  168 + <artifactId>springdoc-openapi-javadoc</artifactId>
  169 + <version>${springdoc.version}</version>
178 170 </dependency>
  171 +
179 172 <dependency>
180   - <groupId>io.swagger</groupId>
181   - <artifactId>swagger-annotations</artifactId>
182   - <version>${swagger-annotations.version}</version>
  173 + <groupId>org.springdoc</groupId>
  174 + <artifactId>springdoc-openapi-security</artifactId>
  175 + <version>${springdoc.version}</version>
183 176 </dependency>
184 177  
185 178 <!-- DB 相关 -->
... ...
yudao-framework/yudao-common/pom.xml
... ... @@ -59,9 +59,13 @@
59 59 </dependency>
60 60  
61 61 <dependency>
62   - <groupId>io.swagger</groupId>
63   - <artifactId>swagger-annotations</artifactId>
64   - <scope>provided</scope> <!-- 设置为 provided,主要是 PageParam 使用到 -->
  62 + <groupId>org.springdoc</groupId>
  63 + <artifactId>springdoc-openapi-webmvc-core</artifactId>
  64 + </dependency>
  65 +
  66 + <dependency>
  67 + <groupId>org.springdoc</groupId>
  68 + <artifactId>springdoc-openapi-javadoc</artifactId>
65 69 </dependency>
66 70  
67 71 <!-- 监控相关 -->
... ...
yudao-framework/yudao-common/src/main/java/cn/iocoder/yudao/framework/common/pojo/PageParam.java
1 1 package cn.iocoder.yudao.framework.common.pojo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.Min;
... ... @@ -9,19 +8,19 @@ import javax.validation.constraints.Max;
9 8 import javax.validation.constraints.NotNull;
10 9 import java.io.Serializable;
11 10  
12   -@ApiModel("分页参数")
  11 +@Schema(title="分页参数")
13 12 @Data
14 13 public class PageParam implements Serializable {
15 14  
16 15 private static final Integer PAGE_NO = 1;
17 16 private static final Integer PAGE_SIZE = 10;
18 17  
19   - @ApiModelProperty(value = "页码,从 1 开始", required = true,example = "1")
  18 + @Schema(title = "页码,从 1 开始", required = true,example = "1")
20 19 @NotNull(message = "页码不能为空")
21 20 @Min(value = 1, message = "页码最小值为 1")
22 21 private Integer pageNo = PAGE_NO;
23 22  
24   - @ApiModelProperty(value = "每页条数,最大值为 100", required = true, example = "10")
  23 + @Schema(title = "每页条数,最大值为 100", required = true, example = "10")
25 24 @NotNull(message = "每页条数不能为空")
26 25 @Min(value = 1, message = "每页条数最小值为 1")
27 26 @Max(value = 100, message = "每页条数最大值为 100")
... ...
yudao-framework/yudao-common/src/main/java/cn/iocoder/yudao/framework/common/pojo/PageResult.java
1 1 package cn.iocoder.yudao.framework.common.pojo;
2   -
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
5 3 import lombok.Data;
6 4  
7 5 import java.io.Serializable;
8 6 import java.util.ArrayList;
9 7 import java.util.List;
10 8  
11   -@ApiModel("分页结果")
  9 +@Schema(title = "分页结果")
12 10 @Data
13 11 public final class PageResult<T> implements Serializable {
14 12  
15   - @ApiModelProperty(value = "数据", required = true)
  13 + @Schema(title = "数据", required = true)
16 14 private List<T> list;
17 15  
18   - @ApiModelProperty(value = "总量", required = true)
  16 + @Schema(title = "总量", required = true)
19 17 private Long total;
20 18  
21 19 public PageResult() {
... ...
yudao-framework/yudao-spring-boot-starter-biz-operatelog/src/main/java/cn/iocoder/yudao/framework/operatelog/core/annotations/OperateLog.java
1 1 package cn.iocoder.yudao.framework.operatelog.core.annotations;
2 2  
3 3 import cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum;
4   -import io.swagger.annotations.Api;
5   -import io.swagger.annotations.ApiOperation;
  4 +import io.swagger.v3.oas.annotations.tags.Tag;
  5 +import io.swagger.v3.oas.annotations.Operation;
6 6  
7 7 import java.lang.annotation.ElementType;
8 8 import java.lang.annotation.Retention;
... ...
yudao-framework/yudao-spring-boot-starter-biz-operatelog/src/main/java/cn/iocoder/yudao/framework/operatelog/core/aop/OperateLogAspect.java
... ... @@ -15,8 +15,8 @@ import cn.iocoder.yudao.framework.operatelog.core.service.OperateLog;
15 15 import cn.iocoder.yudao.framework.operatelog.core.service.OperateLogFrameworkService;
16 16 import cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils;
17 17 import com.google.common.collect.Maps;
18   -import io.swagger.annotations.Api;
19   -import io.swagger.annotations.ApiOperation;
  18 +import io.swagger.v3.oas.annotations.tags.Tag;
  19 +import io.swagger.v3.oas.annotations.Operation;
20 20 import lombok.extern.slf4j.Slf4j;
21 21 import org.aspectj.lang.ProceedingJoinPoint;
22 22 import org.aspectj.lang.annotation.Around;
... ... @@ -71,15 +71,15 @@ public class OperateLogAspect {
71 71 @Resource
72 72 private OperateLogFrameworkService operateLogFrameworkService;
73 73  
74   - @Around("@annotation(apiOperation)")
75   - public Object around(ProceedingJoinPoint joinPoint, ApiOperation apiOperation) throws Throwable {
  74 + @Around("@annotation(operation)")
  75 + public Object around(ProceedingJoinPoint joinPoint, Operation operation) throws Throwable {
76 76 // 可能也添加了 @ApiOperation 注解
77 77 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog operateLog = getMethodAnnotation(joinPoint,
78 78 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog.class);
79   - return around0(joinPoint, operateLog, apiOperation);
  79 + return around0(joinPoint, operateLog, operation);
80 80 }
81 81  
82   - @Around("!@annotation(io.swagger.annotations.ApiOperation) && @annotation(operateLog)")
  82 + @Around("!@annotation(io.swagger.v3.oas.annotations.Operation) && @annotation(operateLog)")
83 83 // 兼容处理,只添加 @OperateLog 注解的情况
84 84 public Object around(ProceedingJoinPoint joinPoint,
85 85 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog operateLog) throws Throwable {
... ... @@ -88,7 +88,7 @@ public class OperateLogAspect {
88 88  
89 89 private Object around0(ProceedingJoinPoint joinPoint,
90 90 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog operateLog,
91   - ApiOperation apiOperation) throws Throwable {
  91 + Operation operation) throws Throwable {
92 92 // 目前,只有管理员,才记录操作日志!所以非管理员,直接调用,不进行记录
93 93 Integer userType = WebFrameworkUtils.getLoginUserType();
94 94 if (!Objects.equals(userType, UserTypeEnum.ADMIN.getValue())) {
... ... @@ -101,10 +101,10 @@ public class OperateLogAspect {
101 101 // 执行原有方法
102 102 Object result = joinPoint.proceed();
103 103 // 记录正常执行时的操作日志
104   - this.log(joinPoint, operateLog, apiOperation, startTime, result, null);
  104 + this.log(joinPoint, operateLog, operation, startTime, result, null);
105 105 return result;
106 106 } catch (Throwable exception) {
107   - this.log(joinPoint, operateLog, apiOperation, startTime, null, exception);
  107 + this.log(joinPoint, operateLog, operation, startTime, null, exception);
108 108 throw exception;
109 109 } finally {
110 110 clearThreadLocal();
... ... @@ -129,7 +129,7 @@ public class OperateLogAspect {
129 129  
130 130 private void log(ProceedingJoinPoint joinPoint,
131 131 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog operateLog,
132   - ApiOperation apiOperation,
  132 + Operation operation,
133 133 LocalDateTime startTime, Object result, Throwable exception) {
134 134 try {
135 135 // 判断不记录的情况
... ... @@ -137,16 +137,16 @@ public class OperateLogAspect {
137 137 return;
138 138 }
139 139 // 真正记录操作日志
140   - this.log0(joinPoint, operateLog, apiOperation, startTime, result, exception);
  140 + this.log0(joinPoint, operateLog, operation, startTime, result, exception);
141 141 } catch (Throwable ex) {
142 142 log.error("[log][记录操作日志时,发生异常,其中参数是 joinPoint({}) operateLog({}) apiOperation({}) result({}) exception({}) ]",
143   - joinPoint, operateLog, apiOperation, result, exception, ex);
  143 + joinPoint, operateLog, operation, result, exception, ex);
144 144 }
145 145 }
146 146  
147 147 private void log0(ProceedingJoinPoint joinPoint,
148 148 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog operateLog,
149   - ApiOperation apiOperation,
  149 + Operation operation,
150 150 LocalDateTime startTime, Object result, Throwable exception) {
151 151 OperateLog operateLogObj = new OperateLog();
152 152 // 补全通用字段
... ... @@ -155,7 +155,7 @@ public class OperateLogAspect {
155 155 // 补充用户信息
156 156 fillUserFields(operateLogObj);
157 157 // 补全模块信息
158   - fillModuleFields(operateLogObj, joinPoint, operateLog, apiOperation);
  158 + fillModuleFields(operateLogObj, joinPoint, operateLog, operation);
159 159 // 补全请求信息
160 160 fillRequestFields(operateLogObj);
161 161 // 补全方法信息
... ... @@ -173,21 +173,21 @@ public class OperateLogAspect {
173 173 private static void fillModuleFields(OperateLog operateLogObj,
174 174 ProceedingJoinPoint joinPoint,
175 175 cn.iocoder.yudao.framework.operatelog.core.annotations.OperateLog operateLog,
176   - ApiOperation apiOperation) {
  176 + Operation operation) {
177 177 // module 属性
178 178 if (operateLog != null) {
179 179 operateLogObj.setModule(operateLog.module());
180 180 }
181 181 if (StrUtil.isEmpty(operateLogObj.getModule())) {
182   - Api api = getClassAnnotation(joinPoint, Api.class);
183   - if (api != null) {
184   - // 优先读取 @API 的 name 属性
185   - if (StrUtil.isNotEmpty(api.value())) {
186   - operateLogObj.setModule(api.value());
  182 + Tag tag = getClassAnnotation(joinPoint, Tag.class);
  183 + if (tag != null) {
  184 + // 优先读取 @Tag 的 name 属性
  185 + if (StrUtil.isNotEmpty(tag.name())) {
  186 + operateLogObj.setModule(tag.name());
187 187 }
188   - // 没有的话,读取 @API 的 tags 属性
189   - if (StrUtil.isEmpty(operateLogObj.getModule()) && ArrayUtil.isNotEmpty(api.tags())) {
190   - operateLogObj.setModule(api.tags()[0]);
  188 + // 没有的话,读取 @API 的 description 属性
  189 + if (StrUtil.isEmpty(operateLogObj.getModule()) && ArrayUtil.isNotEmpty(tag.description())) {
  190 + operateLogObj.setModule(tag.description());
191 191 }
192 192 }
193 193 }
... ... @@ -195,8 +195,8 @@ public class OperateLogAspect {
195 195 if (operateLog != null) {
196 196 operateLogObj.setName(operateLog.name());
197 197 }
198   - if (StrUtil.isEmpty(operateLogObj.getName()) && apiOperation != null) {
199   - operateLogObj.setName(apiOperation.value());
  198 + if (StrUtil.isEmpty(operateLogObj.getName()) && operation != null) {
  199 + operateLogObj.setName(operation.description());
200 200 }
201 201 // type 属性
202 202 if (operateLog != null && ArrayUtil.isNotEmpty(operateLog.type())) {
... ...
yudao-framework/yudao-spring-boot-starter-web/pom.xml
... ... @@ -34,17 +34,18 @@
34 34 </dependency>
35 35  
36 36 <dependency>
37   - <groupId>com.github.xiaoymin</groupId>
38   - <artifactId>knife4j-spring-boot-starter</artifactId>
  37 + <groupId>org.springdoc</groupId>
  38 + <artifactId>springdoc-openapi-webmvc-core</artifactId>
39 39 </dependency>
  40 +
40 41 <dependency>
41   - <groupId>io.swagger</groupId>
42   - <artifactId>swagger-annotations</artifactId>
  42 + <groupId>org.springdoc</groupId>
  43 + <artifactId>springdoc-openapi-javadoc</artifactId>
43 44 </dependency>
44 45  
45 46 <dependency>
46   - <groupId>org.springframework.boot</groupId>
47   - <artifactId>spring-boot-starter-validation</artifactId>
  47 + <groupId>org.springdoc</groupId>
  48 + <artifactId>springdoc-openapi-security</artifactId>
48 49 </dependency>
49 50  
50 51 <dependency>
... ...
yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/swagger/config/YudaoSwaggerAutoConfiguration.java
1 1 package cn.iocoder.yudao.framework.swagger.config;
2 2  
3   -import cn.iocoder.yudao.framework.swagger.core.SpringFoxHandlerProviderBeanPostProcessor;
4   -import com.github.xiaoymin.knife4j.spring.annotations.EnableKnife4j;
  3 +import io.swagger.v3.oas.models.Components;
  4 +import io.swagger.v3.oas.models.ExternalDocumentation;
  5 +import io.swagger.v3.oas.models.OpenAPI;
  6 +import io.swagger.v3.oas.models.info.Info;
  7 +import io.swagger.v3.oas.models.info.License;
  8 +import io.swagger.v3.oas.models.security.SecurityRequirement;
  9 +import io.swagger.v3.oas.models.security.SecurityScheme;
  10 +import org.springdoc.core.GroupedOpenApi;
5 11 import org.springframework.boot.autoconfigure.AutoConfiguration;
6 12 import org.springframework.boot.autoconfigure.condition.ConditionalOnClass;
7 13 import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
8 14 import org.springframework.boot.context.properties.EnableConfigurationProperties;
9 15 import org.springframework.context.annotation.Bean;
10 16 import org.springframework.http.HttpHeaders;
11   -import springfox.documentation.builders.ApiInfoBuilder;
12   -import springfox.documentation.builders.ExampleBuilder;
13   -import springfox.documentation.builders.PathSelectors;
14   -import springfox.documentation.builders.RequestParameterBuilder;
15   -import springfox.documentation.service.*;
16   -import springfox.documentation.spi.DocumentationType;
17   -import springfox.documentation.spi.service.contexts.SecurityContext;
18   -import springfox.documentation.spring.web.plugins.Docket;
19   -import springfox.documentation.swagger2.annotations.EnableSwagger2;
20   -
21   -import java.util.Collections;
22   -import java.util.List;
23   -
24   -import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.HEADER_TENANT_ID;
25   -import static springfox.documentation.builders.RequestHandlerSelectors.basePackage;
26 17  
27 18 /**
28   - * Swagger2 自动配置类
  19 + * Swagger3 自动配置类
29 20 *
30 21 * @author 芋道源码
31 22 */
32 23 @AutoConfiguration
33   -@EnableSwagger2
34   -@EnableKnife4j
35   -@ConditionalOnClass({Docket.class, ApiInfoBuilder.class})
  24 +@ConditionalOnClass({OpenAPI.class})
36 25 // 允许使用 swagger.enable=false 禁用 Swagger
37 26 @ConditionalOnProperty(prefix = "yudao.swagger", value = "enable", matchIfMissing = true)
38 27 @EnableConfigurationProperties(SwaggerProperties.class)
39 28 public class YudaoSwaggerAutoConfiguration {
40 29  
41 30 @Bean
42   - public SpringFoxHandlerProviderBeanPostProcessor springFoxHandlerProviderBeanPostProcessor() {
43   - return new SpringFoxHandlerProviderBeanPostProcessor();
44   - }
  31 + public OpenAPI createRestApi(SwaggerProperties properties) {
  32 + return new OpenAPI()
  33 + .info(new Info().title(properties.getTitle())
  34 + .description(properties.getDescription())
  35 + .version(properties.getVersion())
  36 + .license(new License().name("MIT").url("https://gitee.com/zhijiantianya/ruoyi-vue-pro/blob/master/LICENSE")))
  37 + .externalDocs(new ExternalDocumentation()
  38 + .description(properties.getDescription())
  39 + .url("https://gitee.com/zhijiantianya/ruoyi-vue-pro"));
45 40  
46   - @Bean
47   - public Docket createRestApi(SwaggerProperties properties) {
48   - // 创建 Docket 对象
49   - return new Docket(DocumentationType.SWAGGER_2)
50   - // ① 用来创建该 API 的基本信息,展示在文档的页面中(自定义展示的信息)
51   - .apiInfo(apiInfo(properties))
52   - // ② 设置扫描指定 package 包下的
53   - .select()
54   - .apis(basePackage(properties.getBasePackage()))
55   -// .apis(basePackage("cn.iocoder.yudao.module.system")) // 可用于 swagger 无法展示时使用
56   - .paths(PathSelectors.any())
57   - .build()
58   - // ③ 安全上下文(认证)
59   - .securitySchemes(securitySchemes())
60   - .securityContexts(securityContexts())
61   - // ④ 全局参数(多租户 header)
62   - .globalRequestParameters(globalRequestParameters());
63 41 }
64 42  
65   - // ========== apiInfo ==========
66   -
67   - /**
68   - * API 摘要信息
69   - */
70   - private static ApiInfo apiInfo(SwaggerProperties properties) {
71   - return new ApiInfoBuilder()
72   - .title(properties.getTitle())
73   - .description(properties.getDescription())
74   - .contact(new Contact(properties.getAuthor(), null, null))
75   - .version(properties.getVersion())
  43 + @Bean
  44 + public GroupedOpenApi publicApi() {
  45 + return GroupedOpenApi.builder()
  46 + .group("app")
  47 + .pathsToMatch("/app/**")
76 48 .build();
77 49 }
78 50  
79   - // ========== securitySchemes ==========
80   -
81   - /**
82   - * 安全模式,这里配置通过请求头 Authorization 传递 token 参数
83   - */
84   - private static List<SecurityScheme> securitySchemes() {
85   - return Collections.singletonList(new ApiKey(HttpHeaders.AUTHORIZATION, "Authorization", "header"));
86   - }
87   -
88   - /**
89   - * 安全上下文
90   - *
91   - * @see #securitySchemes()
92   - * @see #authorizationScopes()
93   - */
94   - private static List<SecurityContext> securityContexts() {
95   - return Collections.singletonList(SecurityContext.builder()
96   - .securityReferences(securityReferences())
97   - // 通过 PathSelectors.regex("^(?!auth).*$"),排除包含 "auth" 的接口不需要使用securitySchemes
98   - .operationSelector(o -> o.requestMappingPattern().matches("^(?!auth).*$"))
99   - .build());
100   - }
101   -
102   - private static List<SecurityReference> securityReferences() {
103   - return Collections.singletonList(new SecurityReference(HttpHeaders.AUTHORIZATION, authorizationScopes()));
104   - }
105   -
106   - private static AuthorizationScope[] authorizationScopes() {
107   - return new AuthorizationScope[]{new AuthorizationScope("global", "accessEverything")};
  51 + @Bean
  52 + public GroupedOpenApi adminApi() {
  53 + return GroupedOpenApi.builder()
  54 + .group("admin")
  55 + .pathsToMatch("/admin/**")
  56 + .build();
108 57 }
109 58  
110   - // ========== globalRequestParameters ==========
111   -
112   - private static List<RequestParameter> globalRequestParameters() {
113   - RequestParameterBuilder tenantParameter = new RequestParameterBuilder()
114   - .name(HEADER_TENANT_ID).description("租户编号")
115   - .in(ParameterType.HEADER).example(new ExampleBuilder().value(1L).build());
116   - return Collections.singletonList(tenantParameter.build());
117   - }
118 59  
119 60 }
... ...
yudao-framework/yudao-spring-boot-starter-web/src/main/java/cn/iocoder/yudao/framework/swagger/core/SpringFoxHandlerProviderBeanPostProcessor.java
1   -package cn.iocoder.yudao.framework.swagger.core;
2   -
3   -import cn.hutool.core.util.ReflectUtil;
4   -import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils;
5   -import org.springframework.beans.BeansException;
6   -import org.springframework.beans.factory.config.BeanPostProcessor;
7   -import org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping;
8   -import springfox.documentation.spring.web.plugins.WebFluxRequestHandlerProvider;
9   -import springfox.documentation.spring.web.plugins.WebMvcRequestHandlerProvider;
10   -
11   -import java.util.List;
12   -
13   -/**
14   - * 解决 SpringFox 与 SpringBoot 2.6.x 不兼容的问题
15   - * 该问题对应的 issue 为 https://github.com/springfox/springfox/issues/3462
16   - *
17   - * @author 芋道源码
18   - */
19   -public class SpringFoxHandlerProviderBeanPostProcessor implements BeanPostProcessor {
20   -
21   - @Override
22   - public Object postProcessAfterInitialization(Object bean, String beanName) throws BeansException {
23   - if (bean instanceof WebMvcRequestHandlerProvider || bean instanceof WebFluxRequestHandlerProvider) {
24   - customizeSpringfoxHandlerMappings(getHandlerMappings(bean));
25   - }
26   - return bean;
27   - }
28   -
29   - private <T extends RequestMappingInfoHandlerMapping> void customizeSpringfoxHandlerMappings(List<T> mappings) {
30   - // 移除,只保留 patternParser
31   - List<T> copy = CollectionUtils.filterList(mappings, mapping -> mapping.getPatternParser() == null);
32   - // 添加到 mappings 中
33   - mappings.clear();
34   - mappings.addAll(copy);
35   - }
36   -
37   - @SuppressWarnings("unchecked")
38   - private List<RequestMappingInfoHandlerMapping> getHandlerMappings(Object bean) {
39   - return (List<RequestMappingInfoHandlerMapping>)
40   - ReflectUtil.getFieldValue(bean, "handlerMappings");
41   - }
42   -
43   -}
  1 +//package cn.iocoder.yudao.framework.swagger.core;
  2 +//
  3 +//import cn.hutool.core.util.ReflectUtil;
  4 +//import cn.iocoder.yudao.framework.common.util.collection.CollectionUtils;
  5 +//import org.springframework.beans.BeansException;
  6 +//import org.springframework.beans.factory.config.BeanPostProcessor;
  7 +//import org.springframework.web.servlet.mvc.method.RequestMappingInfoHandlerMapping;
  8 +//import springfox.documentation.spring.web.plugins.WebFluxRequestHandlerProvider;
  9 +//import springfox.documentation.spring.web.plugins.WebMvcRequestHandlerProvider;
  10 +//
  11 +//import java.util.List;
  12 +//
  13 +///**
  14 +// * 解决 SpringFox 与 SpringBoot 2.6.x 不兼容的问题
  15 +// * 该问题对应的 issue 为 https://github.com/springfox/springfox/issues/3462
  16 +// *
  17 +// * @author 芋道源码
  18 +// */
  19 +//public class SpringFoxHandlerProviderBeanPostProcessor implements BeanPostProcessor {
  20 +//
  21 +// @Override
  22 +// public Object postProcessAfterInitialization(Object bean, String beanName) throws BeansException {
  23 +// if (bean instanceof WebMvcRequestHandlerProvider || bean instanceof WebFluxRequestHandlerProvider) {
  24 +// customizeSpringfoxHandlerMappings(getHandlerMappings(bean));
  25 +// }
  26 +// return bean;
  27 +// }
  28 +//
  29 +// private <T extends RequestMappingInfoHandlerMapping> void customizeSpringfoxHandlerMappings(List<T> mappings) {
  30 +// // 移除,只保留 patternParser
  31 +// List<T> copy = CollectionUtils.filterList(mappings, mapping -> mapping.getPatternParser() == null);
  32 +// // 添加到 mappings 中
  33 +// mappings.clear();
  34 +// mappings.addAll(copy);
  35 +// }
  36 +//
  37 +// @SuppressWarnings("unchecked")
  38 +// private List<RequestMappingInfoHandlerMapping> getHandlerMappings(Object bean) {
  39 +// return (List<RequestMappingInfoHandlerMapping>)
  40 +// ReflectUtil.getFieldValue(bean, "handlerMappings");
  41 +// }
  42 +//
  43 +//}
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/BpmFormController.java
... ... @@ -6,9 +6,9 @@ import cn.iocoder.yudao.module.bpm.dal.dataobject.definition.BpmFormDO;
6 6 import cn.iocoder.yudao.module.bpm.service.definition.BpmFormService;
7 7 import cn.iocoder.yudao.framework.common.pojo.CommonResult;
8 8 import cn.iocoder.yudao.framework.common.pojo.PageResult;
9   -import io.swagger.annotations.Api;
10   -import io.swagger.annotations.ApiImplicitParam;
11   -import io.swagger.annotations.ApiOperation;
  9 +import io.swagger.v3.oas.annotations.tags.Tag;
  10 +import io.swagger.v3.oas.annotations.Parameter;
  11 +import io.swagger.v3.oas.annotations.Operation;
12 12 import org.springframework.security.access.prepost.PreAuthorize;
13 13 import org.springframework.validation.annotation.Validated;
14 14 import org.springframework.web.bind.annotation.*;
... ... @@ -19,7 +19,7 @@ import java.util.List;
19 19  
20 20 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
21 21  
22   -@Api(tags = "管理后台 - 动态表单")
  22 +@Tag(name = "管理后台 - 动态表单")
23 23 @RestController
24 24 @RequestMapping("/bpm/form")
25 25 @Validated
... ... @@ -29,14 +29,14 @@ public class BpmFormController {
29 29 private BpmFormService formService;
30 30  
31 31 @PostMapping("/create")
32   - @ApiOperation("创建动态表单")
  32 + @Operation(summary = "创建动态表单")
33 33 @PreAuthorize("@ss.hasPermission('bpm:form:create')")
34 34 public CommonResult<Long> createForm(@Valid @RequestBody BpmFormCreateReqVO createReqVO) {
35 35 return success(formService.createForm(createReqVO));
36 36 }
37 37  
38 38 @PutMapping("/update")
39   - @ApiOperation("更新动态表单")
  39 + @Operation(summary = "更新动态表单")
40 40 @PreAuthorize("@ss.hasPermission('bpm:form:update')")
41 41 public CommonResult<Boolean> updateForm(@Valid @RequestBody BpmFormUpdateReqVO updateReqVO) {
42 42 formService.updateForm(updateReqVO);
... ... @@ -44,8 +44,8 @@ public class BpmFormController {
44 44 }
45 45  
46 46 @DeleteMapping("/delete")
47   - @ApiOperation("删除动态表单")
48   - @ApiImplicitParam(name = "id", value = "编号", required = true, dataTypeClass = Long.class)
  47 + @Operation(summary = "删除动态表单")
  48 + @Parameter(name = "id", description = "编号", required = true)
49 49 @PreAuthorize("@ss.hasPermission('bpm:form:delete')")
50 50 public CommonResult<Boolean> deleteForm(@RequestParam("id") Long id) {
51 51 formService.deleteForm(id);
... ... @@ -53,8 +53,8 @@ public class BpmFormController {
53 53 }
54 54  
55 55 @GetMapping("/get")
56   - @ApiOperation("获得动态表单")
57   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  56 + @Operation(summary = "获得动态表单")
  57 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
58 58 @PreAuthorize("@ss.hasPermission('bpm:form:query')")
59 59 public CommonResult<BpmFormRespVO> getForm(@RequestParam("id") Long id) {
60 60 BpmFormDO form = formService.getForm(id);
... ... @@ -62,14 +62,14 @@ public class BpmFormController {
62 62 }
63 63  
64 64 @GetMapping("/list-all-simple")
65   - @ApiOperation(value = "获得动态表单的精简列表", notes = "用于表单下拉框")
  65 + @Operation(summary = "获得动态表单的精简列表", description = "用于表单下拉框")
66 66 public CommonResult<List<BpmFormSimpleRespVO>> getSimpleForms() {
67 67 List<BpmFormDO> list = formService.getFormList();
68 68 return success(BpmFormConvert.INSTANCE.convertList2(list));
69 69 }
70 70  
71 71 @GetMapping("/page")
72   - @ApiOperation("获得动态表单分页")
  72 + @Operation(summary = "获得动态表单分页")
73 73 @PreAuthorize("@ss.hasPermission('bpm:form:query')")
74 74 public CommonResult<PageResult<BpmFormRespVO>> getFormPage(@Valid BpmFormPageReqVO pageVO) {
75 75 PageResult<BpmFormDO> pageResult = formService.getFormPage(pageVO);
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/BpmModelController.java
... ... @@ -6,9 +6,9 @@ import cn.iocoder.yudao.framework.common.util.io.IoUtils;
6 6 import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model.*;
7 7 import cn.iocoder.yudao.module.bpm.convert.definition.BpmModelConvert;
8 8 import cn.iocoder.yudao.module.bpm.service.definition.BpmModelService;
9   -import io.swagger.annotations.Api;
10   -import io.swagger.annotations.ApiImplicitParam;
11   -import io.swagger.annotations.ApiOperation;
  9 +import io.swagger.v3.oas.annotations.tags.Tag;
  10 +import io.swagger.v3.oas.annotations.Parameter;
  11 +import io.swagger.v3.oas.annotations.Operation;
12 12 import org.springframework.security.access.prepost.PreAuthorize;
13 13 import org.springframework.validation.annotation.Validated;
14 14 import org.springframework.web.bind.annotation.*;
... ... @@ -20,7 +20,7 @@ import java.io.IOException;
20 20  
21 21 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
22 22  
23   -@Api(tags = "管理后台 - 流程模型")
  23 +@Tag(name = "管理后台 - 流程模型")
24 24 @RestController
25 25 @RequestMapping("/bpm/model")
26 26 @Validated
... ... @@ -30,14 +30,14 @@ public class BpmModelController {
30 30 private BpmModelService modelService;
31 31  
32 32 @GetMapping("/page")
33   - @ApiOperation(value = "获得模型分页")
  33 + @Operation(summary = "获得模型分页")
34 34 public CommonResult<PageResult<BpmModelPageItemRespVO>> getModelPage(BpmModelPageReqVO pageVO) {
35 35 return success(modelService.getModelPage(pageVO));
36 36 }
37 37  
38 38 @GetMapping("/get")
39   - @ApiOperation("获得模型")
40   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = String.class)
  39 + @Operation(summary = "获得模型")
  40 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
41 41 @PreAuthorize("@ss.hasPermission('bpm:model:query')")
42 42 public CommonResult<BpmModelRespVO> getModel(@RequestParam("id") String id) {
43 43 BpmModelRespVO model = modelService.getModel(id);
... ... @@ -45,14 +45,14 @@ public class BpmModelController {
45 45 }
46 46  
47 47 @PostMapping("/create")
48   - @ApiOperation(value = "新建模型")
  48 + @Operation(summary = "新建模型")
49 49 @PreAuthorize("@ss.hasPermission('bpm:model:create')")
50 50 public CommonResult<String> createModel(@Valid @RequestBody BpmModelCreateReqVO createRetVO) {
51 51 return success(modelService.createModel(createRetVO, null));
52 52 }
53 53  
54 54 @PutMapping("/update")
55   - @ApiOperation(value = "修改模型")
  55 + @Operation(summary = "修改模型")
56 56 @PreAuthorize("@ss.hasPermission('bpm:model:update')")
57 57 public CommonResult<Boolean> updateModel(@Valid @RequestBody BpmModelUpdateReqVO modelVO) {
58 58 modelService.updateModel(modelVO);
... ... @@ -60,7 +60,7 @@ public class BpmModelController {
60 60 }
61 61  
62 62 @PostMapping("/import")
63   - @ApiOperation(value = "导入模型")
  63 + @Operation(summary = "导入模型")
64 64 @PreAuthorize("@ss.hasPermission('bpm:model:import')")
65 65 public CommonResult<String> importModel(@Valid BpmModeImportReqVO importReqVO) throws IOException {
66 66 BpmModelCreateReqVO createReqVO = BpmModelConvert.INSTANCE.convert(importReqVO);
... ... @@ -70,8 +70,8 @@ public class BpmModelController {
70 70 }
71 71  
72 72 @PostMapping("/deploy")
73   - @ApiOperation(value = "部署模型")
74   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = String.class)
  73 + @Operation(summary = "部署模型")
  74 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
75 75 @PreAuthorize("@ss.hasPermission('bpm:model:deploy')")
76 76 public CommonResult<Boolean> deployModel(@RequestParam("id") String id) {
77 77 modelService.deployModel(id);
... ... @@ -79,7 +79,7 @@ public class BpmModelController {
79 79 }
80 80  
81 81 @PutMapping("/update-state")
82   - @ApiOperation(value = "修改模型的状态", notes = "实际更新的部署的流程定义的状态")
  82 + @Operation(summary = "修改模型的状态", description = "实际更新的部署的流程定义的状态")
83 83 @PreAuthorize("@ss.hasPermission('bpm:model:update')")
84 84 public CommonResult<Boolean> updateModelState(@Valid @RequestBody BpmModelUpdateStateReqVO reqVO) {
85 85 modelService.updateModelState(reqVO.getId(), reqVO.getState());
... ... @@ -87,8 +87,8 @@ public class BpmModelController {
87 87 }
88 88  
89 89 @DeleteMapping("/delete")
90   - @ApiOperation("删除模型")
91   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = String.class)
  90 + @Operation(summary = "删除模型")
  91 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
92 92 @PreAuthorize("@ss.hasPermission('bpm:model:delete')")
93 93 public CommonResult<Boolean> deleteModel(@RequestParam("id") String id) {
94 94 modelService.deleteModel(id);
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/BpmProcessDefinitionController.java
... ... @@ -7,9 +7,9 @@ import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process.BpmPro
7 7 import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process.BpmProcessDefinitionPageReqVO;
8 8 import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process.BpmProcessDefinitionRespVO;
9 9 import cn.iocoder.yudao.module.bpm.service.definition.BpmProcessDefinitionService;
10   -import io.swagger.annotations.Api;
11   -import io.swagger.annotations.ApiImplicitParam;
12   -import io.swagger.annotations.ApiOperation;
  10 +import io.swagger.v3.oas.annotations.tags.Tag;
  11 +import io.swagger.v3.oas.annotations.Parameter;
  12 +import io.swagger.v3.oas.annotations.Operation;
13 13 import org.springframework.security.access.prepost.PreAuthorize;
14 14 import org.springframework.validation.annotation.Validated;
15 15 import org.springframework.web.bind.annotation.GetMapping;
... ... @@ -23,7 +23,7 @@ import java.util.List;
23 23  
24 24 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
25 25  
26   -@Api(tags = "管理后台 - 流程定义")
  26 +@Tag(name = "管理后台 - 流程定义")
27 27 @RestController
28 28 @RequestMapping("/bpm/process-definition")
29 29 @Validated
... ... @@ -33,7 +33,7 @@ public class BpmProcessDefinitionController {
33 33 private BpmProcessDefinitionService bpmDefinitionService;
34 34  
35 35 @GetMapping("/page")
36   - @ApiOperation(value = "获得流程定义分页")
  36 + @Operation(summary = "获得流程定义分页")
37 37 @PreAuthorize("@ss.hasPermission('bpm:process-definition:query')")
38 38 public CommonResult<PageResult<BpmProcessDefinitionPageItemRespVO>> getProcessDefinitionPage(
39 39 BpmProcessDefinitionPageReqVO pageReqVO) {
... ... @@ -41,7 +41,7 @@ public class BpmProcessDefinitionController {
41 41 }
42 42  
43 43 @GetMapping ("/list")
44   - @ApiOperation(value = "获得流程定义列表")
  44 + @Operation(summary = "获得流程定义列表")
45 45 @PreAuthorize("@ss.hasPermission('bpm:process-definition:query')")
46 46 public CommonResult<List<BpmProcessDefinitionRespVO>> getProcessDefinitionList(
47 47 BpmProcessDefinitionListReqVO listReqVO) {
... ... @@ -49,8 +49,8 @@ public class BpmProcessDefinitionController {
49 49 }
50 50  
51 51 @GetMapping ("/get-bpmn-xml")
52   - @ApiOperation(value = "获得流程定义的 BPMN XML")
53   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = String.class)
  52 + @Operation(summary = "获得流程定义的 BPMN XML")
  53 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
54 54 @PreAuthorize("@ss.hasPermission('bpm:process-definition:query')")
55 55 public CommonResult<String> getProcessDefinitionBpmnXML(@RequestParam("id") String id) {
56 56 String bpmnXML = bpmDefinitionService.getProcessDefinitionBpmnXML(id);
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/BpmTaskAssignRuleController.java
... ... @@ -5,10 +5,10 @@ import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule.BpmTaskAs
5 5 import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule.BpmTaskAssignRuleRespVO;
6 6 import cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule.BpmTaskAssignRuleUpdateReqVO;
7 7 import cn.iocoder.yudao.module.bpm.service.definition.BpmTaskAssignRuleService;
8   -import io.swagger.annotations.Api;
9   -import io.swagger.annotations.ApiImplicitParam;
10   -import io.swagger.annotations.ApiImplicitParams;
11   -import io.swagger.annotations.ApiOperation;
  8 +import io.swagger.v3.oas.annotations.tags.Tag;
  9 +import io.swagger.v3.oas.annotations.Parameter;
  10 +import io.swagger.v3.oas.annotations.Parameters;
  11 +import io.swagger.v3.oas.annotations.Operation;
12 12 import org.springframework.security.access.prepost.PreAuthorize;
13 13 import org.springframework.validation.annotation.Validated;
14 14 import org.springframework.web.bind.annotation.*;
... ... @@ -19,7 +19,7 @@ import java.util.List;
19 19  
20 20 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
21 21  
22   -@Api(tags = "管理后台 - 任务分配规则")
  22 +@Tag(name = "管理后台 - 任务分配规则")
23 23 @RestController
24 24 @RequestMapping("/bpm/task-assign-rule")
25 25 @Validated
... ... @@ -29,10 +29,10 @@ public class BpmTaskAssignRuleController {
29 29 private BpmTaskAssignRuleService taskAssignRuleService;
30 30  
31 31 @GetMapping("/list")
32   - @ApiOperation(value = "获得任务分配规则列表")
33   - @ApiImplicitParams({
34   - @ApiImplicitParam(name = "modelId", value = "模型编号", example = "1024", dataTypeClass = String.class),
35   - @ApiImplicitParam(name = "processDefinitionId", value = "流程定义的编号", example = "2048", dataTypeClass = String.class)
  32 + @Operation(summary = "获得任务分配规则列表")
  33 + @Parameters({
  34 + @Parameter(name = "modelId", description = "模型编号", example = "1024"),
  35 + @Parameter(name = "processDefinitionId", description = "流程定义的编号", example = "2048")
36 36 })
37 37 @PreAuthorize("@ss.hasPermission('bpm:task-assign-rule:query')")
38 38 public CommonResult<List<BpmTaskAssignRuleRespVO>> getTaskAssignRuleList(
... ... @@ -42,14 +42,14 @@ public class BpmTaskAssignRuleController {
42 42 }
43 43  
44 44 @PostMapping("/create")
45   - @ApiOperation(value = "创建任务分配规则")
  45 + @Operation(summary = "创建任务分配规则")
46 46 @PreAuthorize("@ss.hasPermission('bpm:task-assign-rule:create')")
47 47 public CommonResult<Long> createTaskAssignRule(@Valid @RequestBody BpmTaskAssignRuleCreateReqVO reqVO) {
48 48 return success(taskAssignRuleService.createTaskAssignRule(reqVO));
49 49 }
50 50  
51 51 @PutMapping("/update")
52   - @ApiOperation(value = "更新任务分配规则")
  52 + @Operation(summary = "更新任务分配规则")
53 53 @PreAuthorize("@ss.hasPermission('bpm:task-assign-rule:update')")
54 54 public CommonResult<Boolean> updateTaskAssignRule(@Valid @RequestBody BpmTaskAssignRuleUpdateReqVO reqVO) {
55 55 taskAssignRuleService.updateTaskAssignRule(reqVO);
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/BpmUserGroupController.java
... ... @@ -10,9 +10,9 @@ import cn.iocoder.yudao.module.bpm.service.definition.BpmUserGroupService;
10 10 import cn.iocoder.yudao.framework.common.enums.CommonStatusEnum;
11 11 import cn.iocoder.yudao.framework.common.pojo.CommonResult;
12 12 import cn.iocoder.yudao.framework.common.pojo.PageResult;
13   -import io.swagger.annotations.Api;
14   -import io.swagger.annotations.ApiImplicitParam;
15   -import io.swagger.annotations.ApiOperation;
  13 +import io.swagger.v3.oas.annotations.tags.Tag;
  14 +import io.swagger.v3.oas.annotations.Parameter;
  15 +import io.swagger.v3.oas.annotations.Operation;
16 16 import org.springframework.security.access.prepost.PreAuthorize;
17 17 import org.springframework.validation.annotation.Validated;
18 18 import org.springframework.web.bind.annotation.*;
... ... @@ -23,7 +23,7 @@ import java.util.List;
23 23  
24 24 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
25 25  
26   -@Api(tags = "管理后台 - 用户组")
  26 +@Tag(name = "管理后台 - 用户组")
27 27 @RestController
28 28 @RequestMapping("/bpm/user-group")
29 29 @Validated
... ... @@ -33,14 +33,14 @@ public class BpmUserGroupController {
33 33 private BpmUserGroupService userGroupService;
34 34  
35 35 @PostMapping("/create")
36   - @ApiOperation("创建用户组")
  36 + @Operation(summary = "创建用户组")
37 37 @PreAuthorize("@ss.hasPermission('bpm:user-group:create')")
38 38 public CommonResult<Long> createUserGroup(@Valid @RequestBody BpmUserGroupCreateReqVO createReqVO) {
39 39 return success(userGroupService.createUserGroup(createReqVO));
40 40 }
41 41  
42 42 @PutMapping("/update")
43   - @ApiOperation("更新用户组")
  43 + @Operation(summary = "更新用户组")
44 44 @PreAuthorize("@ss.hasPermission('bpm:user-group:update')")
45 45 public CommonResult<Boolean> updateUserGroup(@Valid @RequestBody BpmUserGroupUpdateReqVO updateReqVO) {
46 46 userGroupService.updateUserGroup(updateReqVO);
... ... @@ -48,8 +48,8 @@ public class BpmUserGroupController {
48 48 }
49 49  
50 50 @DeleteMapping("/delete")
51   - @ApiOperation("删除用户组")
52   - @ApiImplicitParam(name = "id", value = "编号", required = true, dataTypeClass = Long.class)
  51 + @Operation(summary = "删除用户组")
  52 + @Parameter(name = "id", description = "编号", required = true)
53 53 @PreAuthorize("@ss.hasPermission('bpm:user-group:delete')")
54 54 public CommonResult<Boolean> deleteUserGroup(@RequestParam("id") Long id) {
55 55 userGroupService.deleteUserGroup(id);
... ... @@ -57,8 +57,8 @@ public class BpmUserGroupController {
57 57 }
58 58  
59 59 @GetMapping("/get")
60   - @ApiOperation("获得用户组")
61   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  60 + @Operation(summary = "获得用户组")
  61 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
62 62 @PreAuthorize("@ss.hasPermission('bpm:user-group:query')")
63 63 public CommonResult<BpmUserGroupRespVO> getUserGroup(@RequestParam("id") Long id) {
64 64 BpmUserGroupDO userGroup = userGroupService.getUserGroup(id);
... ... @@ -66,7 +66,7 @@ public class BpmUserGroupController {
66 66 }
67 67  
68 68 @GetMapping("/page")
69   - @ApiOperation("获得用户组分页")
  69 + @Operation(summary = "获得用户组分页")
70 70 @PreAuthorize("@ss.hasPermission('bpm:user-group:query')")
71 71 public CommonResult<PageResult<BpmUserGroupRespVO>> getUserGroupPage(@Valid BpmUserGroupPageReqVO pageVO) {
72 72 PageResult<BpmUserGroupDO> pageResult = userGroupService.getUserGroupPage(pageVO);
... ... @@ -74,7 +74,7 @@ public class BpmUserGroupController {
74 74 }
75 75  
76 76 @GetMapping("/list-all-simple")
77   - @ApiOperation(value = "获取用户组精简信息列表", notes = "只包含被开启的用户组,主要用于前端的下拉选项")
  77 + @Operation(summary = "获取用户组精简信息列表", description = "只包含被开启的用户组,主要用于前端的下拉选项")
78 78 public CommonResult<List<BpmUserGroupRespVO>> getSimpleUserGroups() {
79 79 // 获用户门列表,只要开启状态的
80 80 List<BpmUserGroupDO> list = userGroupService.getUserGroupListByStatus(CommonStatusEnum.ENABLE.getStatus());
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/form/BpmFormBaseVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import io.swagger.annotations.*;
5 4 import javax.validation.constraints.*;
6 5  
7 6 /**
... ... @@ -11,15 +10,15 @@ import javax.validation.constraints.*;
11 10 @Data
12 11 public class BpmFormBaseVO {
13 12  
14   - @ApiModelProperty(value = "表单名称", required = true, example = "芋道")
  13 + @Schema(title = "表单名称", required = true, example = "芋道")
15 14 @NotNull(message = "表单名称不能为空")
16 15 private String name;
17 16  
18   - @ApiModelProperty(value = "表单状态", required = true, notes = "参见 CommonStatusEnum 枚举", example = "1")
  17 + @Schema(title = "表单状态", required = true, description = "参见 CommonStatusEnum 枚举", example = "1")
19 18 @NotNull(message = "表单状态不能为空")
20 19 private Integer status;
21 20  
22   - @ApiModelProperty(value = "备注", example = "我是备注")
  21 + @Schema(title = "备注", example = "我是备注")
23 22 private String remark;
24 23  
25 24 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/form/BpmFormCreateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import io.swagger.annotations.*;
5 4  
6 5 import javax.validation.constraints.NotNull;
7 6 import java.util.List;
8 7  
9   -@ApiModel("管理后台 - 动态表单创建 Request VO")
  8 +@Schema(title = "管理后台 - 动态表单创建 Request VO")
10 9 @Data
11 10 @EqualsAndHashCode(callSuper = true)
12 11 @ToString(callSuper = true)
13 12 public class BpmFormCreateReqVO extends BpmFormBaseVO {
14 13  
15   - @ApiModelProperty(value = "表单的配置", required = true, notes = "JSON 字符串")
  14 + @Schema(title = "表单的配置", required = true, description = "JSON 字符串")
16 15 @NotNull(message = "表单的配置不能为空")
17 16 private String conf;
18 17  
19   - @ApiModelProperty(value = "表单项的数组", required = true, notes = "JSON 字符串的数组")
  18 + @Schema(title = "表单项的数组", required = true, description = "JSON 字符串的数组")
20 19 @NotNull(message = "表单项的数组不能为空")
21 20 private List<String> fields;
22 21  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/form/BpmFormPageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
9 8  
10   -@ApiModel("管理后台 - 动态表单分页 Request VO")
  9 +@Schema(title = "管理后台 - 动态表单分页 Request VO")
11 10 @Data
12 11 @EqualsAndHashCode(callSuper = true)
13 12 @ToString(callSuper = true)
14 13 public class BpmFormPageReqVO extends PageParam {
15 14  
16   - @ApiModelProperty(value = "表单名称", example = "芋道")
  15 + @Schema(title = "表单名称", example = "芋道")
17 16 private String name;
18 17  
19 18 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/form/BpmFormRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form;
2   -
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
5 3 import lombok.Data;
6 4 import lombok.EqualsAndHashCode;
7 5 import lombok.ToString;
... ... @@ -10,24 +8,24 @@ import javax.validation.constraints.NotNull;
10 8 import java.time.LocalDateTime;
11 9 import java.util.List;
12 10  
13   -@ApiModel("管理后台 - 动态表单 Response VO")
  11 +@Schema(title = "管理后台 - 动态表单 Response VO")
14 12 @Data
15 13 @EqualsAndHashCode(callSuper = true)
16 14 @ToString(callSuper = true)
17 15 public class BpmFormRespVO extends BpmFormBaseVO {
18 16  
19   - @ApiModelProperty(value = "表单编号", required = true, example = "1024")
  17 + @Schema(title = "表单编号", required = true, example = "1024")
20 18 private Long id;
21 19  
22   - @ApiModelProperty(value = "表单的配置", required = true, notes = "JSON 字符串")
  20 + @Schema(title = "表单的配置", required = true, description = "JSON 字符串")
23 21 @NotNull(message = "表单的配置不能为空")
24 22 private String conf;
25 23  
26   - @ApiModelProperty(value = "表单项的数组", required = true, notes = "JSON 字符串的数组")
  24 + @Schema(title = "表单项的数组", required = true, description = "JSON 字符串的数组")
27 25 @NotNull(message = "表单项的数组不能为空")
28 26 private List<String> fields;
29 27  
30   - @ApiModelProperty(value = "创建时间", required = true)
  28 + @Schema(title = "创建时间", required = true)
31 29 private LocalDateTime createTime;
32 30  
33 31 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/form/BpmFormSimpleRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7   -@ApiModel("管理后台 - 流程表单精简 Response VO")
  6 +@Schema(title = "管理后台 - 流程表单精简 Response VO")
8 7 @Data
9 8 public class BpmFormSimpleRespVO {
10 9  
11   - @ApiModelProperty(value = "表单编号", required = true, example = "1024")
  10 + @Schema(title = "表单编号", required = true, example = "1024")
12 11 private Long id;
13 12  
14   - @ApiModelProperty(value = "表单名称", required = true, example = "芋道")
  13 + @Schema(title = "表单名称", required = true, example = "芋道")
15 14 private String name;
16 15  
17 16 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/form/BpmFormUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.form;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import io.swagger.annotations.*;
5 4 import javax.validation.constraints.*;
6 5 import java.util.List;
7 6  
8   -@ApiModel("管理后台 - 动态表单更新 Request VO")
  7 +@Schema(title = "管理后台 - 动态表单更新 Request VO")
9 8 @Data
10 9 @EqualsAndHashCode(callSuper = true)
11 10 @ToString(callSuper = true)
12 11 public class BpmFormUpdateReqVO extends BpmFormBaseVO {
13 12  
14   - @ApiModelProperty(value = "表单编号", required = true, example = "1024")
  13 + @Schema(title = "表单编号", required = true, example = "1024")
15 14 @NotNull(message = "表单编号不能为空")
16 15 private Long id;
17 16  
18   - @ApiModelProperty(value = "表单的配置", required = true, notes = "JSON 字符串")
  17 + @Schema(title = "表单的配置", required = true, description = "JSON 字符串")
19 18 @NotNull(message = "表单的配置不能为空")
20 19 private String conf;
21 20  
22   - @ApiModelProperty(value = "表单项的数组", required = true, notes = "JSON 字符串的数组")
  21 + @Schema(title = "表单项的数组", required = true, description = "JSON 字符串的数组")
23 22 @NotNull(message = "表单项的数组不能为空")
24 23 private List<String> fields;
25 24  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/group/BpmUserGroupBaseVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.group;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4 4 import java.util.*;
5   -import io.swagger.annotations.*;
6 5 import javax.validation.constraints.*;
7 6  
8 7 /**
... ... @@ -12,19 +11,19 @@ import javax.validation.constraints.*;
12 11 @Data
13 12 public class BpmUserGroupBaseVO {
14 13  
15   - @ApiModelProperty(value = "组名", required = true, example = "芋道")
  14 + @Schema(title = "组名", required = true, example = "芋道")
16 15 @NotNull(message = "组名不能为空")
17 16 private String name;
18 17  
19   - @ApiModelProperty(value = "描述", required = true, example = "芋道源码")
  18 + @Schema(title = "描述", required = true, example = "芋道源码")
20 19 @NotNull(message = "描述不能为空")
21 20 private String description;
22 21  
23   - @ApiModelProperty(value = "成员编号数组", required = true, example = "1,2,3")
  22 + @Schema(title = "成员编号数组", required = true, example = "1,2,3")
24 23 @NotNull(message = "成员编号数组不能为空")
25 24 private Set<Long> memberUserIds;
26 25  
27   - @ApiModelProperty(value = "状态", required = true, example = "1")
  26 + @Schema(title = "状态", required = true, example = "1")
28 27 @NotNull(message = "状态不能为空")
29 28 private Integer status;
30 29  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/group/BpmUserGroupCreateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.group;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import io.swagger.annotations.*;
5 4  
6   -@ApiModel("管理后台 - 用户组创建 Request VO")
  5 +@Schema(title = "管理后台 - 用户组创建 Request VO")
7 6 @Data
8 7 @EqualsAndHashCode(callSuper = true)
9 8 @ToString(callSuper = true)
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/group/BpmUserGroupPageReqVO.java
... ... @@ -2,8 +2,7 @@ package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.group;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4 4 import cn.iocoder.yudao.framework.common.util.date.DateUtils;
5   -import io.swagger.annotations.ApiModel;
6   -import io.swagger.annotations.ApiModelProperty;
  5 +import io.swagger.v3.oas.annotations.media.Schema;
7 6 import lombok.Data;
8 7 import lombok.EqualsAndHashCode;
9 8 import lombok.ToString;
... ... @@ -11,20 +10,20 @@ import org.springframework.format.annotation.DateTimeFormat;
11 10  
12 11 import java.time.LocalDateTime;
13 12  
14   -@ApiModel("管理后台 - 用户组分页 Request VO")
  13 +@Schema(title = "管理后台 - 用户组分页 Request VO")
15 14 @Data
16 15 @EqualsAndHashCode(callSuper = true)
17 16 @ToString(callSuper = true)
18 17 public class BpmUserGroupPageReqVO extends PageParam {
19 18  
20   - @ApiModelProperty(value = "组名", example = "芋道")
  19 + @Schema(title = "组名", example = "芋道")
21 20 private String name;
22 21  
23   - @ApiModelProperty(value = "状态", example = "1")
  22 + @Schema(title = "状态", example = "1")
24 23 private Integer status;
25 24  
26 25 @DateTimeFormat(pattern = DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
27   - @ApiModelProperty(value = "创建时间")
  26 + @Schema(title = "创建时间")
28 27 private LocalDateTime[] createTime;
29 28  
30 29 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/group/BpmUserGroupRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.group;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4 4  
5 5 import java.time.LocalDateTime;
6 6  
7   -import io.swagger.annotations.*;
8 7  
9   -@ApiModel("管理后台 - 用户组 Response VO")
  8 +@Schema(title = "管理后台 - 用户组 Response VO")
10 9 @Data
11 10 @EqualsAndHashCode(callSuper = true)
12 11 @ToString(callSuper = true)
13 12 public class BpmUserGroupRespVO extends BpmUserGroupBaseVO {
14 13  
15   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  14 + @Schema(title = "编号", required = true, example = "1024")
16 15 private Long id;
17 16  
18   - @ApiModelProperty(value = "创建时间", required = true)
  17 + @Schema(title = "创建时间", required = true)
19 18 private LocalDateTime createTime;
20 19  
21 20 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/group/BpmUserGroupSimpleRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.group;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.AllArgsConstructor;
6 5 import lombok.Data;
7 6 import lombok.NoArgsConstructor;
8 7  
9   -@ApiModel("管理后台 - 用户组精简信息 Response VO")
  8 +@Schema(title = "管理后台 - 用户组精简信息 Response VO")
10 9 @Data
11 10 @NoArgsConstructor
12 11 @AllArgsConstructor
13 12 public class BpmUserGroupSimpleRespVO {
14 13  
15   - @ApiModelProperty(value = "用户组编号", required = true, example = "1024")
  14 + @Schema(title = "用户组编号", required = true, example = "1024")
16 15 private Long id;
17 16  
18   - @ApiModelProperty(value = "用户组名字", required = true, example = "芋道")
  17 + @Schema(title = "用户组名字", required = true, example = "芋道")
19 18 private String name;
20 19  
21 20 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/group/BpmUserGroupUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.group;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import io.swagger.annotations.*;
5 4 import javax.validation.constraints.*;
6 5  
7   -@ApiModel("管理后台 - 用户组更新 Request VO")
  6 +@Schema(title = "管理后台 - 用户组更新 Request VO")
8 7 @Data
9 8 @EqualsAndHashCode(callSuper = true)
10 9 @ToString(callSuper = true)
11 10 public class BpmUserGroupUpdateReqVO extends BpmUserGroupBaseVO {
12 11  
13   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  12 + @Schema(title = "编号", required = true, example = "1024")
14 13 @NotNull(message = "编号不能为空")
15 14 private Long id;
16 15  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModeImportReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
... ... @@ -9,13 +8,13 @@ import org.springframework.web.multipart.MultipartFile;
9 8  
10 9 import javax.validation.constraints.NotNull;
11 10  
12   -@ApiModel(value = "管理后台 - 流程模型的导入 Request VO", description = "相比流程模型的新建来说,只是多了一个 bpmnFile 文件")
  11 +@Schema(title = "管理后台 - 流程模型的导入 Request VO", description = "相比流程模型的新建来说,只是多了一个 bpmnFile 文件")
13 12 @Data
14 13 @EqualsAndHashCode(callSuper = true)
15 14 @ToString(callSuper = true)
16 15 public class BpmModeImportReqVO extends BpmModelCreateReqVO {
17 16  
18   - @ApiModelProperty(value = "BPMN 文件", required = true)
  17 + @Schema(title = "BPMN 文件", required = true)
19 18 @NotNull(message = "BPMN 文件不能为空")
20 19 private MultipartFile bpmnFile;
21 20  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelBaseVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2   -
3   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4  
6 5 import javax.validation.constraints.NotEmpty;
... ... @@ -12,30 +11,30 @@ import javax.validation.constraints.NotEmpty;
12 11 @Data
13 12 public class BpmModelBaseVO {
14 13  
15   - @ApiModelProperty(value = "流程标识", required = true, example = "process_yudao")
  14 + @Schema(title = "流程标识", required = true, example = "process_yudao")
16 15 @NotEmpty(message = "流程标识不能为空")
17 16 private String key;
18 17  
19   - @ApiModelProperty(value = "流程名称", required = true, example = "芋道")
  18 + @Schema(title = "流程名称", required = true, example = "芋道")
20 19 @NotEmpty(message = "流程名称不能为空")
21 20 private String name;
22 21  
23   - @ApiModelProperty(value = "流程描述", example = "我是描述")
  22 + @Schema(title = "流程描述", example = "我是描述")
24 23 private String description;
25 24  
26   - @ApiModelProperty(value = "流程分类", notes = "参见 bpm_model_category 数据字典", example = "1")
  25 + @Schema(title = "流程分类", description = "参见 bpm_model_category 数据字典", example = "1")
27 26 @NotEmpty(message = "流程分类不能为空")
28 27 private String category;
29 28  
30   - @ApiModelProperty(value = "表单类型", notes = "参见 bpm_model_form_type 数据字典", example = "1")
  29 + @Schema(title = "表单类型", description = "参见 bpm_model_form_type 数据字典", example = "1")
31 30 private Integer formType;
32   - @ApiModelProperty(value = "表单编号", example = "1024", notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  31 + @Schema(title = "表单编号", example = "1024", description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
33 32 private Long formId;
34   - @ApiModelProperty(value = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
35   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  33 + @Schema(title = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
  34 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
36 35 private String formCustomCreatePath;
37   - @ApiModelProperty(value = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
38   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  36 + @Schema(title = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
  37 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
39 38 private String formCustomViewPath;
40 39  
41 40 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelCreateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import javax.validation.constraints.NotEmpty;
10 9  
11   -@ApiModel("管理后台 - 流程模型的创建 Request VO")
  10 +@Schema(title = "管理后台 - 流程模型的创建 Request VO")
12 11 @Data
13 12 public class BpmModelCreateReqVO {
14 13  
15   - @ApiModelProperty(value = "流程标识", required = true, example = "process_yudao")
  14 + @Schema(title = "流程标识", required = true, example = "process_yudao")
16 15 @NotEmpty(message = "流程标识不能为空")
17 16 private String key;
18 17  
19   - @ApiModelProperty(value = "流程名称", required = true, example = "芋道")
  18 + @Schema(title = "流程名称", required = true, example = "芋道")
20 19 @NotEmpty(message = "流程名称不能为空")
21 20 private String name;
22 21  
23   - @ApiModelProperty(value = "流程描述", example = "我是描述")
  22 + @Schema(title = "流程描述", example = "我是描述")
24 23 private String description;
25 24  
26 25 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelPageItemRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import java.time.LocalDateTime;
10 9  
11   -@ApiModel("管理后台 - 流程模型的分页的每一项 Response VO")
  10 +@Schema(title = "管理后台 - 流程模型的分页的每一项 Response VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmModelPageItemRespVO extends BpmModelBaseVO {
16 15  
17   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  16 + @Schema(title = "编号", required = true, example = "1024")
18 17 private String id;
19 18  
20   - @ApiModelProperty(value = "表单名字", example = "请假表单")
  19 + @Schema(title = "表单名字", example = "请假表单")
21 20 private String formName;
22 21  
23   - @ApiModelProperty(value = "创建时间", required = true)
  22 + @Schema(title = "创建时间", required = true)
24 23 private LocalDateTime createTime;
25 24  
26 25 /**
... ... @@ -28,20 +27,20 @@ public class BpmModelPageItemRespVO extends BpmModelBaseVO {
28 27 */
29 28 private ProcessDefinition processDefinition;
30 29  
31   - @ApiModel("流程定义")
  30 + @Schema(title = "流程定义")
32 31 @Data
33 32 public static class ProcessDefinition {
34 33  
35   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  34 + @Schema(title = "编号", required = true, example = "1024")
36 35 private String id;
37 36  
38   - @ApiModelProperty(value = "版本", required = true, example = "1")
  37 + @Schema(title = "版本", required = true, example = "1")
39 38 private Integer version;
40 39  
41   - @ApiModelProperty(value = "部署时间", required = true)
  40 + @Schema(title = "部署时间", required = true)
42 41 private LocalDateTime deploymentTime;
43 42  
44   - @ApiModelProperty(value = "中断状态", required = true, example = "1", notes = "参见 SuspensionState 枚举")
  43 + @Schema(title = "中断状态", required = true, example = "1", description = "参见 SuspensionState 枚举")
45 44 private Integer suspensionState;
46 45  
47 46 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelPageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
9 8  
10 9  
11   -@ApiModel("管理后台 - 流程模型分页 Request VO")
  10 +@Schema(title = "管理后台 - 流程模型分页 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmModelPageReqVO extends PageParam {
16 15  
17   - @ApiModelProperty(value = "标识", example = "process1641042089407", notes = "精准匹配")
  16 + @Schema(title = "标识", example = "process1641042089407", description = "精准匹配")
18 17 private String key;
19 18  
20   - @ApiModelProperty(value = "名字", example = "芋道", notes = "模糊匹配")
  19 + @Schema(title = "名字", example = "芋道", description = "模糊匹配")
21 20 private String name;
22 21  
23   - @ApiModelProperty(value = "流程分类", notes = "参见 bpm_model_category 数据字典", example = "1")
  22 + @Schema(title = "流程分类", description = "参见 bpm_model_category 数据字典", example = "1")
24 23 private String category;
25 24  
26 25 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import java.time.LocalDateTime;
10 9  
11   -@ApiModel("管理后台 - 流程模型的创建 Request VO")
  10 +@Schema(title = "管理后台 - 流程模型的创建 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmModelRespVO extends BpmModelBaseVO {
16 15  
17   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  16 + @Schema(title = "编号", required = true, example = "1024")
18 17 private String id;
19 18  
20   - @ApiModelProperty(value = "BPMN XML", required = true)
  19 + @Schema(title = "BPMN XML", required = true)
21 20 private String bpmnXml;
22 21  
23   - @ApiModelProperty(value = "创建时间", required = true)
  22 + @Schema(title = "创建时间", required = true)
24 23 private LocalDateTime createTime;
25 24  
26 25 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotEmpty;
8 7  
9   -@ApiModel("管理后台 - 流程模型的更新 Request VO")
  8 +@Schema(title = "管理后台 - 流程模型的更新 Request VO")
10 9 @Data
11 10 public class BpmModelUpdateReqVO {
12 11  
13   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  12 + @Schema(title = "编号", required = true, example = "1024")
14 13 @NotEmpty(message = "编号不能为空")
15 14 private String id;
16 15  
17   - @ApiModelProperty(value = "流程名称", example = "芋道")
  16 + @Schema(title = "流程名称", example = "芋道")
18 17 private String name;
19 18  
20   - @ApiModelProperty(value = "流程描述", example = "我是描述")
  19 + @Schema(title = "流程描述", example = "我是描述")
21 20 private String description;
22 21  
23   - @ApiModelProperty(value = "流程分类", notes = "参见 bpm_model_category 数据字典", example = "1")
  22 + @Schema(title = "流程分类", description = "参见 bpm_model_category 数据字典", example = "1")
24 23 private String category;
25 24  
26   - @ApiModelProperty(value = "BPMN XML", required = true)
  25 + @Schema(title = "BPMN XML", required = true)
27 26 private String bpmnXml;
28 27  
29   - @ApiModelProperty(value = "表单类型", notes = "参见 bpm_model_form_type 数据字典", example = "1")
  28 + @Schema(title = "表单类型", description = "参见 bpm_model_form_type 数据字典", example = "1")
30 29 private Integer formType;
31   - @ApiModelProperty(value = "表单编号", example = "1024", notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  30 + @Schema(title = "表单编号", example = "1024", description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
32 31 private Long formId;
33   - @ApiModelProperty(value = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
34   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  32 + @Schema(title = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
  33 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
35 34 private String formCustomCreatePath;
36   - @ApiModelProperty(value = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
37   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  35 + @Schema(title = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
  36 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
38 37 private String formCustomViewPath;
39 38  
40 39 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/model/BpmModelUpdateStateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.model;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotNull;
8 7  
9   -@ApiModel("管理后台 - 流程模型更新状态 Request VO")
  8 +@Schema(title = "管理后台 - 流程模型更新状态 Request VO")
10 9 @Data
11 10 public class BpmModelUpdateStateReqVO {
12 11  
13   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  12 + @Schema(title = "编号", required = true, example = "1024")
14 13 @NotNull(message = "编号不能为空")
15 14 private String id;
16 15  
17   - @ApiModelProperty(value = "状态", required = true, example = "1", notes = "见 SuspensionState 枚举")
  16 + @Schema(title = "状态", required = true, example = "1", description = "见 SuspensionState 枚举")
18 17 @NotNull(message = "状态不能为空")
19 18 private Integer state;
20 19  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/process/BpmProcessDefinitionListReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
9 8  
10   -@ApiModel("管理后台 - 流程定义列表 Request VO")
  9 +@Schema(title = "管理后台 - 流程定义列表 Request VO")
11 10 @Data
12 11 @ToString(callSuper = true)
13 12 @EqualsAndHashCode(callSuper = true)
14 13 public class BpmProcessDefinitionListReqVO extends PageParam {
15 14  
16   - @ApiModelProperty(value = "中断状态", example = "1", notes = "参见 SuspensionState 枚举")
  15 + @Schema(title = "中断状态", example = "1", description = "参见 SuspensionState 枚举")
17 16 private Integer suspensionState;
18 17  
19 18 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/process/BpmProcessDefinitionPageItemRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import java.time.LocalDateTime;
10 9  
11   -@ApiModel("管理后台 - 流程定义的分页的每一项 Response VO")
  10 +@Schema(title = "管理后台 - 流程定义的分页的每一项 Response VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmProcessDefinitionPageItemRespVO extends BpmProcessDefinitionRespVO {
16 15  
17   - @ApiModelProperty(value = "表单名字", example = "请假表单")
  16 + @Schema(title = "表单名字", example = "请假表单")
18 17 private String formName;
19 18  
20   - @ApiModelProperty(value = "部署时间", required = true)
  19 + @Schema(title = "部署时间", required = true)
21 20 private LocalDateTime deploymentTime;
22 21  
23 22 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/process/BpmProcessDefinitionPageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
9 8  
10   -@ApiModel("管理后台 - 流程定义分页 Request VO")
  9 +@Schema(title = "管理后台 - 流程定义分页 Request VO")
11 10 @Data
12 11 @ToString(callSuper = true)
13 12 @EqualsAndHashCode(callSuper = true)
14 13 public class BpmProcessDefinitionPageReqVO extends PageParam {
15 14  
16   - @ApiModelProperty(value = "标识", example = "process1641042089407", notes = "精准匹配")
  15 + @Schema(title = "标识", example = "process1641042089407", description = "精准匹配")
17 16 private String key;
18 17  
19 18 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/process/BpmProcessDefinitionRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.process;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotEmpty;
8 7 import javax.validation.constraints.NotNull;
9 8 import java.util.List;
10 9  
11   -@ApiModel("管理后台 - 流程定义 Response VO")
  10 +@Schema(title = "管理后台 - 流程定义 Response VO")
12 11 @Data
13 12 public class BpmProcessDefinitionRespVO {
14 13  
15   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  14 + @Schema(title = "编号", required = true, example = "1024")
16 15 private String id;
17 16  
18   - @ApiModelProperty(value = "版本", required = true, example = "1")
  17 + @Schema(title = "版本", required = true, example = "1")
19 18 private Integer version;
20 19  
21   - @ApiModelProperty(value = "流程名称", required = true, example = "芋道")
  20 + @Schema(title = "流程名称", required = true, example = "芋道")
22 21 @NotEmpty(message = "流程名称不能为空")
23 22 private String name;
24 23  
25   - @ApiModelProperty(value = "流程描述", example = "我是描述")
  24 + @Schema(title = "流程描述", example = "我是描述")
26 25 private String description;
27 26  
28   - @ApiModelProperty(value = "流程分类", notes = "参见 bpm_model_category 数据字典", example = "1")
  27 + @Schema(title = "流程分类", description = "参见 bpm_model_category 数据字典", example = "1")
29 28 @NotEmpty(message = "流程分类不能为空")
30 29 private String category;
31 30  
32   - @ApiModelProperty(value = "表单类型", notes = "参见 bpm_model_form_type 数据字典", example = "1")
  31 + @Schema(title = "表单类型", description = "参见 bpm_model_form_type 数据字典", example = "1")
33 32 private Integer formType;
34   - @ApiModelProperty(value = "表单编号", example = "1024", notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  33 + @Schema(title = "表单编号", example = "1024", description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
35 34 private Long formId;
36   - @ApiModelProperty(value = "表单的配置", required = true,
37   - notes = "JSON 字符串。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  35 + @Schema(title = "表单的配置", required = true,
  36 + description = "JSON 字符串。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
38 37 private String formConf;
39   - @ApiModelProperty(value = "表单项的数组", required = true,
40   - notes = "JSON 字符串的数组。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  38 + @Schema(title = "表单项的数组", required = true,
  39 + description = "JSON 字符串的数组。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
41 40 private List<String> formFields;
42   - @ApiModelProperty(value = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
43   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  41 + @Schema(title = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
  42 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
44 43 private String formCustomCreatePath;
45   - @ApiModelProperty(value = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
46   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  44 + @Schema(title = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
  45 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
47 46 private String formCustomViewPath;
48 47  
49   - @ApiModelProperty(value = "中断状态", required = true, example = "1", notes = "参见 SuspensionState 枚举")
  48 + @Schema(title = "中断状态", required = true, example = "1", description = "参见 SuspensionState 枚举")
50 49 private Integer suspensionState;
51 50  
52 51 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/rule/BpmTaskAssignRuleBaseVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule;
2   -
3   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4  
6 5 import javax.validation.constraints.NotEmpty;
... ... @@ -14,11 +13,11 @@ import java.util.Set;
14 13 @Data
15 14 public class BpmTaskAssignRuleBaseVO {
16 15  
17   - @ApiModelProperty(value = "规则类型", required = true, example = "bpm_task_assign_rule_type")
  16 + @Schema(title = "规则类型", required = true, example = "bpm_task_assign_rule_type")
18 17 @NotNull(message = "规则类型不能为空")
19 18 private Integer type;
20 19  
21   - @ApiModelProperty(value = "规则值数组", required = true, example = "1,2,3")
  20 + @Schema(title = "规则值数组", required = true, example = "1,2,3")
22 21 @NotNull(message = "规则值数组不能为空")
23 22 private Set<Long> options;
24 23  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/rule/BpmTaskAssignRuleCreateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import javax.validation.constraints.NotEmpty;
10 9  
11   -@ApiModel("管理后台 - 流程任务分配规则的创建 Request VO")
  10 +@Schema(title = "管理后台 - 流程任务分配规则的创建 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmTaskAssignRuleCreateReqVO extends BpmTaskAssignRuleBaseVO {
16 15  
17   - @ApiModelProperty(value = "流程模型的编号", required = true, example = "1024")
  16 + @Schema(title = "流程模型的编号", required = true, example = "1024")
18 17 @NotEmpty(message = "流程模型的编号不能为空")
19 18 private String modelId;
20 19  
21   - @ApiModelProperty(value = "流程任务定义的编号", required = true, example = "2048")
  20 + @Schema(title = "流程任务定义的编号", required = true, example = "2048")
22 21 @NotEmpty(message = "流程任务定义的编号不能为空")
23 22 private String taskDefinitionKey;
24 23  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/rule/BpmTaskAssignRuleRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9   -@ApiModel("管理后台 - 流程任务分配规则的 Response VO")
  8 +@Schema(title = "管理后台 - 流程任务分配规则的 Response VO")
10 9 @Data
11 10 @EqualsAndHashCode(callSuper = true)
12 11 @ToString(callSuper = true)
13 12 public class BpmTaskAssignRuleRespVO extends BpmTaskAssignRuleBaseVO {
14 13  
15   - @ApiModelProperty(value = "任务分配规则的编号", required = true, example = "1024")
  14 + @Schema(title = "任务分配规则的编号", required = true, example = "1024")
16 15 private Long id;
17 16  
18   - @ApiModelProperty(value = "流程模型的编号", required = true, example = "2048")
  17 + @Schema(title = "流程模型的编号", required = true, example = "2048")
19 18 private String modelId;
20 19  
21   - @ApiModelProperty(value = "流程定义的编号", required = true, example = "4096")
  20 + @Schema(title = "流程定义的编号", required = true, example = "4096")
22 21 private String processDefinitionId;
23 22  
24   - @ApiModelProperty(value = "流程任务定义的编号", required = true, example = "2048")
  23 + @Schema(title = "流程任务定义的编号", required = true, example = "2048")
25 24 private String taskDefinitionKey;
26   - @ApiModelProperty(value = "流程任务定义的名字", required = true, example = "关注芋道")
  25 + @Schema(title = "流程任务定义的名字", required = true, example = "关注芋道")
27 26 private String taskDefinitionName;
28 27  
29 28 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/definition/vo/rule/BpmTaskAssignRuleUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.definition.vo.rule;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import javax.validation.constraints.NotNull;
10 9  
11   -@ApiModel("管理后台 - 流程任务分配规则的更新 Request VO")
  10 +@Schema(title = "管理后台 - 流程任务分配规则的更新 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmTaskAssignRuleUpdateReqVO extends BpmTaskAssignRuleBaseVO {
16 15  
17   - @ApiModelProperty(value = "任务分配规则的编号", required = true, example = "1024")
  16 + @Schema(title = "任务分配规则的编号", required = true, example = "1024")
18 17 @NotNull(message = "任务分配规则的编号不能为空")
19 18 private Long id;
20 19  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/oa/BpmOALeaveController.java
... ... @@ -8,9 +8,9 @@ import cn.iocoder.yudao.module.bpm.dal.dataobject.oa.BpmOALeaveDO;
8 8 import cn.iocoder.yudao.framework.common.pojo.CommonResult;
9 9 import cn.iocoder.yudao.framework.common.pojo.PageResult;
10 10 import cn.iocoder.yudao.module.bpm.service.oa.BpmOALeaveService;
11   -import io.swagger.annotations.Api;
12   -import io.swagger.annotations.ApiImplicitParam;
13   -import io.swagger.annotations.ApiOperation;
  11 +import io.swagger.v3.oas.annotations.tags.Tag;
  12 +import io.swagger.v3.oas.annotations.Parameter;
  13 +import io.swagger.v3.oas.annotations.Operation;
14 14 import org.springframework.security.access.prepost.PreAuthorize;
15 15 import org.springframework.validation.annotation.Validated;
16 16 import org.springframework.web.bind.annotation.*;
... ... @@ -27,7 +27,7 @@ import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUti
27 27 * @author jason
28 28 * @author 芋道源码
29 29 */
30   -@Api(tags = "管理后台 - OA 请假申请")
  30 +@Tag(name = "管理后台 - OA 请假申请")
31 31 @RestController
32 32 @RequestMapping("/bpm/oa/leave")
33 33 @Validated
... ... @@ -38,15 +38,15 @@ public class BpmOALeaveController {
38 38  
39 39 @PostMapping("/create")
40 40 @PreAuthorize("@ss.hasPermission('bpm:oa-leave:create')")
41   - @ApiOperation("创建请求申请")
  41 + @Operation(summary = "创建请求申请")
42 42 public CommonResult<Long> createLeave(@Valid @RequestBody BpmOALeaveCreateReqVO createReqVO) {
43 43 return success(leaveService.createLeave(getLoginUserId(), createReqVO));
44 44 }
45 45  
46 46 @GetMapping("/get")
47 47 @PreAuthorize("@ss.hasPermission('bpm:oa-leave:query')")
48   - @ApiOperation("获得请假申请")
49   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  48 + @Operation(summary = "获得请假申请")
  49 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
50 50 public CommonResult<BpmOALeaveRespVO> getLeave(@RequestParam("id") Long id) {
51 51 BpmOALeaveDO leave = leaveService.getLeave(id);
52 52 return success(BpmOALeaveConvert.INSTANCE.convert(leave));
... ... @@ -54,7 +54,7 @@ public class BpmOALeaveController {
54 54  
55 55 @GetMapping("/page")
56 56 @PreAuthorize("@ss.hasPermission('bpm:oa-leave:query')")
57   - @ApiOperation("获得请假申请分页")
  57 + @Operation(summary = "获得请假申请分页")
58 58 public CommonResult<PageResult<BpmOALeaveRespVO>> getLeavePage(@Valid BpmOALeavePageReqVO pageVO) {
59 59 PageResult<BpmOALeaveDO> pageResult = leaveService.getLeavePage(getLoginUserId(), pageVO);
60 60 return success(BpmOALeaveConvert.INSTANCE.convertPage(pageResult));
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/oa/vo/BpmOALeaveBaseVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.oa.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4 4 import java.time.LocalDateTime;
5   -import io.swagger.annotations.*;
6 5 import javax.validation.constraints.*;
7 6 import org.springframework.format.annotation.DateTimeFormat;
8 7  
... ... @@ -15,19 +14,19 @@ import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_
15 14 @Data
16 15 public class BpmOALeaveBaseVO {
17 16  
18   - @ApiModelProperty(value = "请假的开始时间", required = true)
  17 + @Schema(title = "请假的开始时间", required = true)
19 18 @NotNull(message = "开始时间不能为空")
20 19 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
21 20 private LocalDateTime startTime;
22   - @ApiModelProperty(value = "请假的结束时间", required = true)
  21 + @Schema(title = "请假的结束时间", required = true)
23 22 @NotNull(message = "结束时间不能为空")
24 23 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
25 24 private LocalDateTime endTime;
26 25  
27   - @ApiModelProperty(value = "请假类型", required = true, example = "1", notes = "参见 bpm_oa_type 枚举")
  26 + @Schema(title = "请假类型", required = true, example = "1", description = "参见 bpm_oa_type 枚举")
28 27 private Integer type;
29 28  
30   - @ApiModelProperty(value = "原因", required = true, example = "阅读芋道源码")
  29 + @Schema(title = "原因", required = true, example = "阅读芋道源码")
31 30 private String reason;
32 31  
33 32 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/oa/vo/BpmOALeaveCreateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.oa.vo;
2   -
3   -import io.swagger.annotations.ApiModel;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4 import lombok.EqualsAndHashCode;
6 5 import lombok.ToString;
7 6  
8 7 import javax.validation.constraints.AssertTrue;
9 8  
10   -@ApiModel("管理后台 - 请假申请创建 Request VO")
  9 +@Schema(title = "管理后台 - 请假申请创建 Request VO")
11 10 @Data
12 11 @EqualsAndHashCode(callSuper = true)
13 12 @ToString(callSuper = true)
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/oa/vo/BpmOALeavePageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.oa.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4 4 import java.time.LocalDateTime;
5   -import io.swagger.annotations.*;
6 5 import cn.iocoder.yudao.framework.common.pojo.PageParam;
7 6 import org.springframework.format.annotation.DateTimeFormat;
8 7  
9 8 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
10 9  
11   -@ApiModel("管理后台 - 请假申请分页 Request VO")
  10 +@Schema(title = "管理后台 - 请假申请分页 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmOALeavePageReqVO extends PageParam {
16 15  
17   - @ApiModelProperty(value = "状态", example = "1", notes = "参见 bpm_process_instance_result 枚举")
  16 + @Schema(title = "状态", example = "1", description = "参见 bpm_process_instance_result 枚举")
18 17 private Integer result;
19 18  
20   - @ApiModelProperty(value = "请假类型", example = "1", notes = "参见 bpm_oa_type")
  19 + @Schema(title = "请假类型", example = "1", description = "参见 bpm_oa_type")
21 20 private Integer type;
22 21  
23   - @ApiModelProperty(value = "原因", example = "阅读芋道源码", notes = "模糊匹配")
  22 + @Schema(title = "原因", example = "阅读芋道源码", description = "模糊匹配")
24 23 private String reason;
25 24  
26 25 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
27   - @ApiModelProperty(value = "申请时间")
  26 + @Schema(title = "申请时间")
28 27 private LocalDateTime[] createTime;
29 28  
30 29 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/oa/vo/BpmOALeaveRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.oa.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import io.swagger.annotations.*;
5 4 import org.springframework.format.annotation.DateTimeFormat;
6 5  
7 6 import javax.validation.constraints.NotNull;
... ... @@ -9,24 +8,24 @@ import java.time.LocalDateTime;
9 8  
10 9 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
11 10  
12   -@ApiModel("管理后台 - 请假申请 Response VO")
  11 +@Schema(title = "管理后台 - 请假申请 Response VO")
13 12 @Data
14 13 @EqualsAndHashCode(callSuper = true)
15 14 @ToString(callSuper = true)
16 15 public class BpmOALeaveRespVO extends BpmOALeaveBaseVO {
17 16  
18   - @ApiModelProperty(value = "请假表单主键", required = true, example = "1024")
  17 + @Schema(title = "请假表单主键", required = true, example = "1024")
19 18 private Long id;
20 19  
21   - @ApiModelProperty(value = "状态", required = true, example = "1", notes = "参见 bpm_process_instance_result 枚举")
  20 + @Schema(title = "状态", required = true, example = "1", description = "参见 bpm_process_instance_result 枚举")
22 21 private Integer result;
23 22  
24   - @ApiModelProperty(value = "申请时间", required = true)
  23 + @Schema(title = "申请时间", required = true)
25 24 @NotNull(message = "申请时间不能为空")
26 25 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
27 26 private LocalDateTime createTime;
28 27  
29   - @ApiModelProperty(value = "流程id")
  28 + @Schema(title = "流程id")
30 29 private String processInstanceId;
31 30  
32 31 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmActivityController.java
... ... @@ -3,9 +3,9 @@ package cn.iocoder.yudao.module.bpm.controller.admin.task;
3 3 import cn.iocoder.yudao.framework.common.pojo.CommonResult;
4 4 import cn.iocoder.yudao.module.bpm.controller.admin.task.vo.activity.BpmActivityRespVO;
5 5 import cn.iocoder.yudao.module.bpm.service.task.BpmActivityService;
6   -import io.swagger.annotations.Api;
7   -import io.swagger.annotations.ApiImplicitParam;
8   -import io.swagger.annotations.ApiOperation;
  6 +import io.swagger.v3.oas.annotations.tags.Tag;
  7 +import io.swagger.v3.oas.annotations.Parameter;
  8 +import io.swagger.v3.oas.annotations.Operation;
9 9 import org.springframework.security.access.prepost.PreAuthorize;
10 10 import org.springframework.validation.annotation.Validated;
11 11 import org.springframework.web.bind.annotation.GetMapping;
... ... @@ -18,7 +18,7 @@ import java.util.List;
18 18  
19 19 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
20 20  
21   -@Api(tags = "管理后台 - 流程活动实例")
  21 +@Tag(name = "管理后台 - 流程活动实例")
22 22 @RestController
23 23 @RequestMapping("/bpm/activity")
24 24 @Validated
... ... @@ -28,9 +28,9 @@ public class BpmActivityController {
28 28 private BpmActivityService activityService;
29 29  
30 30 @GetMapping("/list")
31   - @ApiOperation(value = "生成指定流程实例的高亮流程图",
32   - notes = "只高亮进行中的任务。不过要注意,该接口暂时没用,通过前端的 ProcessViewer.vue 界面的 highlightDiagram 方法生成")
33   - @ApiImplicitParam(name = "processInstanceId", value = "流程实例的编号", required = true, dataTypeClass = String.class)
  31 + @Operation(summary = "生成指定流程实例的高亮流程图",
  32 + description = "只高亮进行中的任务。不过要注意,该接口暂时没用,通过前端的 ProcessViewer.vue 界面的 highlightDiagram 方法生成")
  33 + @Parameter(name = "processInstanceId", description = "流程实例的编号", required = true)
34 34 @PreAuthorize("@ss.hasPermission('bpm:task:query')")
35 35 public CommonResult<List<BpmActivityRespVO>> getActivityList(
36 36 @RequestParam("processInstanceId") String processInstanceId) {
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmProcessInstanceController.java
... ... @@ -4,9 +4,9 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult;
4 4 import cn.iocoder.yudao.framework.common.pojo.PageResult;
5 5 import cn.iocoder.yudao.module.bpm.controller.admin.task.vo.instance.*;
6 6 import cn.iocoder.yudao.module.bpm.service.task.BpmProcessInstanceService;
7   -import io.swagger.annotations.Api;
8   -import io.swagger.annotations.ApiImplicitParam;
9   -import io.swagger.annotations.ApiOperation;
  7 +import io.swagger.v3.oas.annotations.tags.Tag;
  8 +import io.swagger.v3.oas.annotations.Parameter;
  9 +import io.swagger.v3.oas.annotations.Operation;
10 10 import org.springframework.security.access.prepost.PreAuthorize;
11 11 import org.springframework.validation.annotation.Validated;
12 12 import org.springframework.web.bind.annotation.*;
... ... @@ -17,7 +17,7 @@ import javax.validation.Valid;
17 17 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
18 18 import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId;
19 19  
20   -@Api(tags = "管理后台 - 流程实例") // 流程实例,通过流程定义创建的一次“申请”
  20 +@Tag(name = "管理后台 - 流程实例") // 流程实例,通过流程定义创建的一次“申请”
21 21 @RestController
22 22 @RequestMapping("/bpm/process-instance")
23 23 @Validated
... ... @@ -27,7 +27,7 @@ public class BpmProcessInstanceController {
27 27 private BpmProcessInstanceService processInstanceService;
28 28  
29 29 @GetMapping("/my-page")
30   - @ApiOperation(value = "获得我的实例分页列表", notes = "在【我的流程】菜单中,进行调用")
  30 + @Operation(summary = "获得我的实例分页列表", description = "在【我的流程】菜单中,进行调用")
31 31 @PreAuthorize("@ss.hasPermission('bpm:process-instance:query')")
32 32 public CommonResult<PageResult<BpmProcessInstancePageItemRespVO>> getMyProcessInstancePage(
33 33 @Valid BpmProcessInstanceMyPageReqVO pageReqVO) {
... ... @@ -35,22 +35,22 @@ public class BpmProcessInstanceController {
35 35 }
36 36  
37 37 @PostMapping("/create")
38   - @ApiOperation("新建流程实例")
  38 + @Operation(summary = "新建流程实例")
39 39 @PreAuthorize("@ss.hasPermission('bpm:process-instance:query')")
40 40 public CommonResult<String> createProcessInstance(@Valid @RequestBody BpmProcessInstanceCreateReqVO createReqVO) {
41 41 return success(processInstanceService.createProcessInstance(getLoginUserId(), createReqVO));
42 42 }
43 43  
44 44 @GetMapping("/get")
45   - @ApiOperation(value = "获得指定流程实例", notes = "在【流程详细】界面中,进行调用")
46   - @ApiImplicitParam(name = "id", value = "流程实例的编号", required = true, dataTypeClass = String.class)
  45 + @Operation(summary = "获得指定流程实例", description = "在【流程详细】界面中,进行调用")
  46 + @Parameter(name = "id", description = "流程实例的编号", required = true)
47 47 @PreAuthorize("@ss.hasPermission('bpm:process-instance:query')")
48 48 public CommonResult<BpmProcessInstanceRespVO> getProcessInstance(@RequestParam("id") String id) {
49 49 return success(processInstanceService.getProcessInstanceVO(id));
50 50 }
51 51  
52 52 @DeleteMapping("/cancel")
53   - @ApiOperation(value = "取消流程实例", notes = "撤回发起的流程")
  53 + @Operation(summary = "取消流程实例", description = "撤回发起的流程")
54 54 @PreAuthorize("@ss.hasPermission('bpm:process-instance:cancel')")
55 55 public CommonResult<Boolean> cancelProcessInstance(@Valid @RequestBody BpmProcessInstanceCancelReqVO cancelReqVO) {
56 56 processInstanceService.cancelProcessInstance(getLoginUserId(), cancelReqVO);
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/BpmTaskController.java
... ... @@ -4,9 +4,9 @@ import cn.iocoder.yudao.framework.common.pojo.CommonResult;
4 4 import cn.iocoder.yudao.framework.common.pojo.PageResult;
5 5 import cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task.*;
6 6 import cn.iocoder.yudao.module.bpm.service.task.BpmTaskService;
7   -import io.swagger.annotations.Api;
8   -import io.swagger.annotations.ApiImplicitParam;
9   -import io.swagger.annotations.ApiOperation;
  7 +import io.swagger.v3.oas.annotations.tags.Tag;
  8 +import io.swagger.v3.oas.annotations.Parameter;
  9 +import io.swagger.v3.oas.annotations.Operation;
10 10 import org.springframework.security.access.prepost.PreAuthorize;
11 11 import org.springframework.validation.annotation.Validated;
12 12 import org.springframework.web.bind.annotation.*;
... ... @@ -19,7 +19,7 @@ import java.util.List;
19 19 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
20 20 import static cn.iocoder.yudao.framework.web.core.util.WebFrameworkUtils.getLoginUserId;
21 21  
22   -@Api(tags = "管理后台 - 流程任务实例")
  22 +@Tag(name = "管理后台 - 流程任务实例")
23 23 @RestController
24 24 @RequestMapping("/bpm/task")
25 25 @Validated
... ... @@ -29,22 +29,22 @@ public class BpmTaskController {
29 29 private BpmTaskService taskService;
30 30  
31 31 @GetMapping("todo-page")
32   - @ApiOperation("获取 Todo 待办任务分页")
  32 + @Operation(summary = "获取 Todo 待办任务分页")
33 33 @PreAuthorize("@ss.hasPermission('bpm:task:query')")
34 34 public CommonResult<PageResult<BpmTaskTodoPageItemRespVO>> getTodoTaskPage(@Valid BpmTaskTodoPageReqVO pageVO) {
35 35 return success(taskService.getTodoTaskPage(getLoginUserId(), pageVO));
36 36 }
37 37  
38 38 @GetMapping("done-page")
39   - @ApiOperation("获取 Done 已办任务分页")
  39 + @Operation(summary = "获取 Done 已办任务分页")
40 40 @PreAuthorize("@ss.hasPermission('bpm:task:query')")
41 41 public CommonResult<PageResult<BpmTaskDonePageItemRespVO>> getDoneTaskPage(@Valid BpmTaskDonePageReqVO pageVO) {
42 42 return success(taskService.getDoneTaskPage(getLoginUserId(), pageVO));
43 43 }
44 44  
45 45 @GetMapping("/list-by-process-instance-id")
46   - @ApiOperation(value = "获得指定流程实例的任务列表", notes = "包括完成的、未完成的")
47   - @ApiImplicitParam(name = "processInstanceId", value = "流程实例的编号", required = true, dataTypeClass = String.class)
  46 + @Operation(summary = "获得指定流程实例的任务列表", description = "包括完成的、未完成的")
  47 + @Parameter(name = "processInstanceId", description = "流程实例的编号", required = true)
48 48 @PreAuthorize("@ss.hasPermission('bpm:task:query')")
49 49 public CommonResult<List<BpmTaskRespVO>> getTaskListByProcessInstanceId(
50 50 @RequestParam("processInstanceId") String processInstanceId) {
... ... @@ -52,7 +52,7 @@ public class BpmTaskController {
52 52 }
53 53  
54 54 @PutMapping("/approve")
55   - @ApiOperation("通过任务")
  55 + @Operation(summary = "通过任务")
56 56 @PreAuthorize("@ss.hasPermission('bpm:task:update')")
57 57 public CommonResult<Boolean> approveTask(@Valid @RequestBody BpmTaskApproveReqVO reqVO) {
58 58 taskService.approveTask(getLoginUserId(), reqVO);
... ... @@ -60,7 +60,7 @@ public class BpmTaskController {
60 60 }
61 61  
62 62 @PutMapping("/reject")
63   - @ApiOperation("不通过任务")
  63 + @Operation(summary = "不通过任务")
64 64 @PreAuthorize("@ss.hasPermission('bpm:task:update')")
65 65 public CommonResult<Boolean> rejectTask(@Valid @RequestBody BpmTaskRejectReqVO reqVO) {
66 66 taskService.rejectTask(getLoginUserId(), reqVO);
... ... @@ -68,7 +68,7 @@ public class BpmTaskController {
68 68 }
69 69  
70 70 @PutMapping("/update-assignee")
71   - @ApiOperation(value = "更新任务的负责人", notes = "用于【流程详情】的【转派】按钮")
  71 + @Operation(summary = "更新任务的负责人", description = "用于【流程详情】的【转派】按钮")
72 72 @PreAuthorize("@ss.hasPermission('bpm:task:update')")
73 73 public CommonResult<Boolean> updateTaskAssignee(@Valid @RequestBody BpmTaskUpdateAssigneeReqVO reqVO) {
74 74 taskService.updateTaskAssignee(getLoginUserId(), reqVO);
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/activity/BpmActivityRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.activity;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import java.time.LocalDateTime;
8 7  
9   -@ApiModel("管理后台 - 流程活动的 Response VO")
  8 +@Schema(title = "管理后台 - 流程活动的 Response VO")
10 9 @Data
11 10 public class BpmActivityRespVO {
12 11  
13   - @ApiModelProperty(value = "流程活动的标识", required = true, example = "1024")
  12 + @Schema(title = "流程活动的标识", required = true, example = "1024")
14 13 private String key;
15   - @ApiModelProperty(value = "流程活动的类型", required = true, example = "StartEvent")
  14 + @Schema(title = "流程活动的类型", required = true, example = "StartEvent")
16 15 private String type;
17 16  
18   - @ApiModelProperty(value = "流程活动的开始时间", required = true)
  17 + @Schema(title = "流程活动的开始时间", required = true)
19 18 private LocalDateTime startTime;
20   - @ApiModelProperty(value = "流程活动的结束时间", required = true)
  19 + @Schema(title = "流程活动的结束时间", required = true)
21 20 private LocalDateTime endTime;
22 21  
23   - @ApiModelProperty(value = "关联的流程任务的编号", example = "2048", notes = "关联的流程任务,只有 UserTask 等类型才有")
  22 + @Schema(title = "关联的流程任务的编号", example = "2048", description = "关联的流程任务,只有 UserTask 等类型才有")
24 23 private String taskId;
25 24  
26 25 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/instance/BpmProcessInstanceCancelReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.instance;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotEmpty;
8 7 import javax.validation.constraints.NotNull;
9 8 import java.util.Map;
10 9  
11   -@ApiModel("管理后台 - 流程实例的取消 Request VO")
  10 +@Schema(title = "管理后台 - 流程实例的取消 Request VO")
12 11 @Data
13 12 public class BpmProcessInstanceCancelReqVO {
14 13  
15   - @ApiModelProperty(value = "流程实例的编号", required = true, example = "1024")
  14 + @Schema(title = "流程实例的编号", required = true, example = "1024")
16 15 @NotEmpty(message = "流程实例的编号不能为空")
17 16 private String id;
18 17  
19   - @ApiModelProperty(value = "取消原因", required = true, example = "不请假了!")
  18 + @Schema(title = "取消原因", required = true, example = "不请假了!")
20 19 @NotEmpty(message = "取消原因不能为空")
21 20 private String reason;
22 21  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/instance/BpmProcessInstanceCreateReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.instance;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotEmpty;
8 7 import java.util.Map;
9 8  
10   -@ApiModel("管理后台 - 流程实例的创建 Request VO")
  9 +@Schema(title = "管理后台 - 流程实例的创建 Request VO")
11 10 @Data
12 11 public class BpmProcessInstanceCreateReqVO {
13 12  
14   - @ApiModelProperty(value = "流程定义的编号", required = true, example = "1024")
  13 + @Schema(title = "流程定义的编号", required = true, example = "1024")
15 14 @NotEmpty(message = "流程定义编号不能为空")
16 15 private String processDefinitionId;
17 16  
18   - @ApiModelProperty(value = "变量实例")
  17 + @Schema(title = "变量实例")
19 18 private Map<String, Object> variables;
20 19  
21 20 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/instance/BpmProcessInstanceMyPageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.instance;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,28 +11,28 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 流程实例的分页 Item Response VO")
  14 +@Schema(title = "管理后台 - 流程实例的分页 Item Response VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class BpmProcessInstanceMyPageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "流程名称", example = "芋道")
  20 + @Schema(title = "流程名称", example = "芋道")
22 21 private String name;
23 22  
24   - @ApiModelProperty(value = "流程定义的编号", example = "2048")
  23 + @Schema(title = "流程定义的编号", example = "2048")
25 24 private String processDefinitionId;
26 25  
27   - @ApiModelProperty(value = "流程实例的状态", notes = "参见 bpm_process_instance_status", example = "1")
  26 + @Schema(title = "流程实例的状态", description = "参见 bpm_process_instance_status", example = "1")
28 27 private Integer status;
29 28  
30   - @ApiModelProperty(value = "流程实例的结果", notes = "参见 bpm_process_instance_result", example = "2")
  29 + @Schema(title = "流程实例的结果", description = "参见 bpm_process_instance_result", example = "2")
31 30 private Integer result;
32 31  
33   - @ApiModelProperty(value = "流程分类", notes = "参见 bpm_model_category 数据字典", example = "1")
  32 + @Schema(title = "流程分类", description = "参见 bpm_model_category 数据字典", example = "1")
34 33 private String category;
35 34  
36   - @ApiModelProperty(value = "创建时间")
  35 + @Schema(title = "创建时间")
37 36 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
38 37 private LocalDateTime[] createTime;
39 38  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/instance/BpmProcessInstancePageItemRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.instance;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import java.time.LocalDateTime;
8 7 import java.util.List;
9 8  
10   -@ApiModel("管理后台 - 流程实例的分页 Item Response VO")
  9 +@Schema(title = "管理后台 - 流程实例的分页 Item Response VO")
11 10 @Data
12 11 public class BpmProcessInstancePageItemRespVO {
13 12  
14   - @ApiModelProperty(value = "流程实例的编号", required = true, example = "1024")
  13 + @Schema(title = "流程实例的编号", required = true, example = "1024")
15 14 private String id;
16 15  
17   - @ApiModelProperty(value = "流程名称", required = true, example = "芋道")
  16 + @Schema(title = "流程名称", required = true, example = "芋道")
18 17 private String name;
19 18  
20   - @ApiModelProperty(value = "流程定义的编号", required = true, example = "2048")
  19 + @Schema(title = "流程定义的编号", required = true, example = "2048")
21 20 private String processDefinitionId;
22 21  
23   - @ApiModelProperty(value = "流程分类", required = true, notes = "参见 bpm_model_category 数据字典", example = "1")
  22 + @Schema(title = "流程分类", required = true, description = "参见 bpm_model_category 数据字典", example = "1")
24 23 private String category;
25 24  
26   - @ApiModelProperty(value = "流程实例的状态", required = true, notes = "参见 bpm_process_instance_status", example = "1")
  25 + @Schema(title = "流程实例的状态", required = true, description = "参见 bpm_process_instance_status", example = "1")
27 26 private Integer status;
28 27  
29   - @ApiModelProperty(value = "流程实例的结果", required = true, notes = "参见 bpm_process_instance_result", example = "2")
  28 + @Schema(title = "流程实例的结果", required = true, description = "参见 bpm_process_instance_result", example = "2")
30 29 private Integer result;
31 30  
32   - @ApiModelProperty(value = "提交时间", required = true)
  31 + @Schema(title = "提交时间", required = true)
33 32 private LocalDateTime createTime;
34 33  
35   - @ApiModelProperty(value = "结束时间", required = true)
  34 + @Schema(title = "结束时间", required = true)
36 35 private LocalDateTime endTime;
37 36  
38 37 /**
... ... @@ -40,14 +39,14 @@ public class BpmProcessInstancePageItemRespVO {
40 39 */
41 40 private List<Task> tasks;
42 41  
43   - @ApiModel("流程任务")
  42 + @Schema(title = "流程任务")
44 43 @Data
45 44 public static class Task {
46 45  
47   - @ApiModelProperty(value = "流程任务的编号", required = true, example = "1024")
  46 + @Schema(title = "流程任务的编号", required = true, example = "1024")
48 47 private String id;
49 48  
50   - @ApiModelProperty(value = "任务名称", required = true, example = "芋道")
  49 + @Schema(title = "任务名称", required = true, example = "芋道")
51 50 private String name;
52 51  
53 52 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/instance/BpmProcessInstanceRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.instance;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import java.time.LocalDateTime;
8 7 import java.util.List;
9 8 import java.util.Map;
10 9  
11   -@ApiModel("管理后台 - 流程实例的 Response VO")
  10 +@Schema(title = "管理后台 - 流程实例的 Response VO")
12 11 @Data
13 12 public class BpmProcessInstanceRespVO {
14 13  
15   - @ApiModelProperty(value = "流程实例的编号", required = true, example = "1024")
  14 + @Schema(title = "流程实例的编号", required = true, example = "1024")
16 15 private String id;
17 16  
18   - @ApiModelProperty(value = "流程名称", required = true, example = "芋道")
  17 + @Schema(title = "流程名称", required = true, example = "芋道")
19 18 private String name;
20 19  
21   - @ApiModelProperty(value = "流程分类", required = true, notes = "参见 bpm_model_category 数据字典", example = "1")
  20 + @Schema(title = "流程分类", required = true, description = "参见 bpm_model_category 数据字典", example = "1")
22 21 private String category;
23 22  
24   - @ApiModelProperty(value = "流程实例的状态", required = true, notes = "参见 bpm_process_instance_status", example = "1")
  23 + @Schema(title = "流程实例的状态", required = true, description = "参见 bpm_process_instance_status", example = "1")
25 24 private Integer status;
26 25  
27   - @ApiModelProperty(value = "流程实例的结果", required = true, notes = "参见 bpm_process_instance_result", example = "2")
  26 + @Schema(title = "流程实例的结果", required = true, description = "参见 bpm_process_instance_result", example = "2")
28 27 private Integer result;
29 28  
30   - @ApiModelProperty(value = "提交时间", required = true)
  29 + @Schema(title = "提交时间", required = true)
31 30 private LocalDateTime createTime;
32 31  
33   - @ApiModelProperty(value = "结束时间", required = true)
  32 + @Schema(title = "结束时间", required = true)
34 33 private LocalDateTime endTime;
35 34  
36   - @ApiModelProperty(value = "提交的表单值", required = true)
  35 + @Schema(title = "提交的表单值", required = true)
37 36 private Map<String, Object> formVariables;
38 37  
39   - @ApiModelProperty(value = "业务的唯一标识", example = "1", notes = "例如说,请假申请的编号")
  38 + @Schema(title = "业务的唯一标识", example = "1", description = "例如说,请假申请的编号")
40 39 private String businessKey;
41 40  
42 41 /**
... ... @@ -49,47 +48,47 @@ public class BpmProcessInstanceRespVO {
49 48 */
50 49 private ProcessDefinition processDefinition;
51 50  
52   - @ApiModel("用户信息")
  51 + @Schema(title = "用户信息")
53 52 @Data
54 53 public static class User {
55 54  
56   - @ApiModelProperty(value = "用户编号", required = true, example = "1")
  55 + @Schema(title = "用户编号", required = true, example = "1")
57 56 private Long id;
58   - @ApiModelProperty(value = "用户昵称", required = true, example = "芋艿")
  57 + @Schema(title = "用户昵称", required = true, example = "芋艿")
59 58 private String nickname;
60 59  
61   - @ApiModelProperty(value = "部门编号", required = true, example = "1")
  60 + @Schema(title = "部门编号", required = true, example = "1")
62 61 private Long deptId;
63   - @ApiModelProperty(value = "部门名称", required = true, example = "研发部")
  62 + @Schema(title = "部门名称", required = true, example = "研发部")
64 63 private String deptName;
65 64  
66 65 }
67 66  
68   - @ApiModel("流程定义信息")
  67 + @Schema(title = "流程定义信息")
69 68 @Data
70 69 public static class ProcessDefinition {
71 70  
72   - @ApiModelProperty(value = "编号", required = true, example = "1024")
  71 + @Schema(title = "编号", required = true, example = "1024")
73 72 private String id;
74 73  
75   - @ApiModelProperty(value = "表单类型", notes = "参见 bpm_model_form_type 数据字典", example = "1")
  74 + @Schema(title = "表单类型", description = "参见 bpm_model_form_type 数据字典", example = "1")
76 75 private Integer formType;
77   - @ApiModelProperty(value = "表单编号", example = "1024", notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  76 + @Schema(title = "表单编号", example = "1024", description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
78 77 private Long formId;
79   - @ApiModelProperty(value = "表单的配置", required = true,
80   - notes = "JSON 字符串。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  78 + @Schema(title = "表单的配置", required = true,
  79 + description = "JSON 字符串。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
81 80 private String formConf;
82   - @ApiModelProperty(value = "表单项的数组", required = true,
83   - notes = "JSON 字符串的数组。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  81 + @Schema(title = "表单项的数组", required = true,
  82 + description = "JSON 字符串的数组。在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
84 83 private List<String> formFields;
85   - @ApiModelProperty(value = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
86   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  84 + @Schema(title = "自定义表单的提交路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/create",
  85 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
87 86 private String formCustomCreatePath;
88   - @ApiModelProperty(value = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
89   - notes = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
  87 + @Schema(title = "自定义表单的查看路径,使用 Vue 的路由地址", example = "/bpm/oa/leave/view",
  88 + description = "在表单类型为 {@link BpmModelFormTypeEnum#CUSTOM} 时,必须非空")
90 89 private String formCustomViewPath;
91 90  
92   - @ApiModelProperty(value = "BPMN XML", required = true)
  91 + @Schema(title = "BPMN XML", required = true)
93 92 private String bpmnXml;
94 93  
95 94 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskApproveReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotEmpty;
8 7  
9   -@ApiModel("管理后台 - 通过流程任务的 Request VO")
  8 +@Schema(title = "管理后台 - 通过流程任务的 Request VO")
10 9 @Data
11 10 public class BpmTaskApproveReqVO {
12 11  
13   - @ApiModelProperty(value = "任务编号", required = true, example = "1024")
  12 + @Schema(title = "任务编号", required = true, example = "1024")
14 13 @NotEmpty(message = "任务编号不能为空")
15 14 private String id;
16 15  
17   - @ApiModelProperty(value = "审批意见", required = true, example = "不错不错!")
  16 + @Schema(title = "审批意见", required = true, example = "不错不错!")
18 17 @NotEmpty(message = "审批意见不能为空")
19 18 private String reason;
20 19  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskDonePageItemRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import java.time.LocalDateTime;
10 9  
11   -@ApiModel("管理后台 - 流程任务的 Done 已完成的分页项 Response VO")
  10 +@Schema(title = "管理后台 - 流程任务的 Done 已完成的分页项 Response VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class BpmTaskDonePageItemRespVO extends BpmTaskTodoPageItemRespVO {
16 15  
17   - @ApiModelProperty(value = "结束时间", required = true)
  16 + @Schema(title = "结束时间", required = true)
18 17 private LocalDateTime endTime;
19   - @ApiModelProperty(value = "持续时间", required = true, example = "1000")
  18 + @Schema(title = "持续时间", required = true, example = "1000")
20 19 private Long durationInMillis;
21 20  
22   - @ApiModelProperty(value = "任务结果", required = true, notes = "参见 bpm_process_instance_result", example = "2")
  21 + @Schema(title = "任务结果", required = true, description = "参见 bpm_process_instance_result", example = "2")
23 22 private Integer result;
24   - @ApiModelProperty(value = "审批建议", required = true, example = "不请假了!")
  23 + @Schema(title = "审批建议", required = true, example = "不请假了!")
25 24 private String reason;
26 25  
27 26 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskDonePageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,20 +11,20 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 流程任务的 Done 已办的分页 Request VO")
  14 +@Schema(title = "管理后台 - 流程任务的 Done 已办的分页 Request VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class BpmTaskDonePageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "流程任务名", example = "芋道")
  20 + @Schema(title = "流程任务名", example = "芋道")
22 21 private String name;
23 22  
24   - @ApiModelProperty(value = "开始的创建收间")
  23 + @Schema(title = "开始的创建收间")
25 24 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
26 25 private LocalDateTime beginCreateTime;
27 26  
28   - @ApiModelProperty(value = "结束的创建时间")
  27 + @Schema(title = "结束的创建时间")
29 28 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
30 29 private LocalDateTime endCreateTime;
31 30  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskRejectReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotEmpty;
8 7  
9   -@ApiModel("管理后台 - 不通过流程任务的 Request VO")
  8 +@Schema(title = "管理后台 - 不通过流程任务的 Request VO")
10 9 @Data
11 10 public class BpmTaskRejectReqVO {
12 11  
13   - @ApiModelProperty(value = "任务编号", required = true, example = "1024")
  12 + @Schema(title = "任务编号", required = true, example = "1024")
14 13 @NotEmpty(message = "任务编号不能为空")
15 14 private String id;
16 15  
17   - @ApiModelProperty(value = "审批意见", required = true, example = "不错不错!")
  16 + @Schema(title = "审批意见", required = true, example = "不错不错!")
18 17 @NotEmpty(message = "审批意见不能为空")
19 18 private String reason;
20 19  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9   -@ApiModel("管理后台 - 流程任务的 Response VO")
  8 +@Schema(title = "管理后台 - 流程任务的 Response VO")
10 9 @Data
11 10 @EqualsAndHashCode(callSuper = true)
12 11 @ToString(callSuper = true)
13 12 public class BpmTaskRespVO extends BpmTaskDonePageItemRespVO {
14 13  
15   - @ApiModelProperty(value = "任务定义的标识", required = true, example = "user-001")
  14 + @Schema(title = "任务定义的标识", required = true, example = "user-001")
16 15 private String definitionKey;
17 16  
18 17 /**
... ... @@ -20,18 +19,18 @@ public class BpmTaskRespVO extends BpmTaskDonePageItemRespVO {
20 19 */
21 20 private User assigneeUser;
22 21  
23   - @ApiModel("用户信息")
  22 + @Schema(title = "用户信息")
24 23 @Data
25 24 public static class User {
26 25  
27   - @ApiModelProperty(value = "用户编号", required = true, example = "1")
  26 + @Schema(title = "用户编号", required = true, example = "1")
28 27 private Long id;
29   - @ApiModelProperty(value = "用户昵称", required = true, example = "芋艿")
  28 + @Schema(title = "用户昵称", required = true, example = "芋艿")
30 29 private String nickname;
31 30  
32   - @ApiModelProperty(value = "部门编号", required = true, example = "1")
  31 + @Schema(title = "部门编号", required = true, example = "1")
33 32 private Long deptId;
34   - @ApiModelProperty(value = "部门名称", required = true, example = "研发部")
  33 + @Schema(title = "部门名称", required = true, example = "研发部")
35 34 private String deptName;
36 35  
37 36 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskTodoPageItemRespVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import java.time.LocalDateTime;
8 7  
9   -@ApiModel("管理后台 - 流程任务的 Running 进行中的分页项 Response VO")
  8 +@Schema(title = "管理后台 - 流程任务的 Running 进行中的分页项 Response VO")
10 9 @Data
11 10 public class BpmTaskTodoPageItemRespVO {
12 11  
13   - @ApiModelProperty(value = "任务编号", required = true, example = "1024")
  12 + @Schema(title = "任务编号", required = true, example = "1024")
14 13 private String id;
15 14  
16   - @ApiModelProperty(value = "任务名字", required = true, example = "芋道")
  15 + @Schema(title = "任务名字", required = true, example = "芋道")
17 16 private String name;
18 17  
19   - @ApiModelProperty(value = "接收时间", required = true)
  18 + @Schema(title = "接收时间", required = true)
20 19 private LocalDateTime claimTime;
21 20  
22   - @ApiModelProperty(value = "创建时间", required = true)
  21 + @Schema(title = "创建时间", required = true)
23 22 private LocalDateTime createTime;
24 23  
25   - @ApiModelProperty(value = "激活状态", required = true, example = "1", notes = "参见 SuspensionState 枚举")
  24 + @Schema(title = "激活状态", required = true, example = "1", description = "参见 SuspensionState 枚举")
26 25 private Integer suspensionState;
27 26  
28 27 /**
... ... @@ -31,22 +30,22 @@ public class BpmTaskTodoPageItemRespVO {
31 30 private ProcessInstance processInstance;
32 31  
33 32 @Data
34   - @ApiModel("流程实例")
  33 + @Schema(title = "流程实例")
35 34 public static class ProcessInstance {
36 35  
37   - @ApiModelProperty(value = "流程实例编号", required = true, example = "1024")
  36 + @Schema(title = "流程实例编号", required = true, example = "1024")
38 37 private String id;
39 38  
40   - @ApiModelProperty(value = "流程实例名称", required = true, example = "芋道")
  39 + @Schema(title = "流程实例名称", required = true, example = "芋道")
41 40 private String name;
42 41  
43   - @ApiModelProperty(value = "发起人的用户编号", required = true, example = "1024")
  42 + @Schema(title = "发起人的用户编号", required = true, example = "1024")
44 43 private Long startUserId;
45 44  
46   - @ApiModelProperty(value = "发起人的用户昵称", required = true, example = "芋艿")
  45 + @Schema(title = "发起人的用户昵称", required = true, example = "芋艿")
47 46 private String startUserNickname;
48 47  
49   - @ApiModelProperty(value = "流程定义的编号", required = true, example = "2048")
  48 + @Schema(title = "流程定义的编号", required = true, example = "2048")
50 49 private String processDefinitionId;
51 50  
52 51 }
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskTodoPageReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,20 +11,20 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 流程任务的 TODO 待办的分页 Request VO")
  14 +@Schema(title = "管理后台 - 流程任务的 TODO 待办的分页 Request VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class BpmTaskTodoPageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "流程任务名", example = "芋道")
  20 + @Schema(title = "流程任务名", example = "芋道")
22 21 private String name;
23 22  
24   - @ApiModelProperty(value = "开始的创建收间")
  23 + @Schema(title = "开始的创建收间")
25 24 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
26 25 private LocalDateTime beginCreateTime;
27 26  
28   - @ApiModelProperty(value = "结束的创建时间")
  27 + @Schema(title = "结束的创建时间")
29 28 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
30 29 private LocalDateTime endCreateTime;
31 30  
... ...
yudao-module-bpm/yudao-module-bpm-biz/src/main/java/cn/iocoder/yudao/module/bpm/controller/admin/task/vo/task/BpmTaskUpdateAssigneeReqVO.java
1 1 package cn.iocoder.yudao.module.bpm.controller.admin.task.vo.task;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
... ... @@ -10,15 +9,15 @@ import net.bytebuddy.implementation.bind.annotation.Empty;
10 9 import javax.validation.constraints.NotEmpty;
11 10 import javax.validation.constraints.NotNull;
12 11  
13   -@ApiModel("管理后台 - 流程任务的更新负责人的 Request VO")
  12 +@Schema(title = "管理后台 - 流程任务的更新负责人的 Request VO")
14 13 @Data
15 14 public class BpmTaskUpdateAssigneeReqVO {
16 15  
17   - @ApiModelProperty(value = "任务编号", required = true, example = "1024")
  16 + @Schema(title = "任务编号", required = true, example = "1024")
18 17 @NotEmpty(message = "任务编号不能为空")
19 18 private String id;
20 19  
21   - @ApiModelProperty(value = "新审批人的用户编号", required = true, example = "2048")
  20 + @Schema(title = "新审批人的用户编号", required = true, example = "2048")
22 21 @NotNull(message = "新审批人的用户编号不能为空")
23 22 private Long assigneeUserId;
24 23  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/CodegenController.java
... ... @@ -16,10 +16,10 @@ import cn.iocoder.yudao.module.infra.convert.codegen.CodegenConvert;
16 16 import cn.iocoder.yudao.module.infra.dal.dataobject.codegen.CodegenColumnDO;
17 17 import cn.iocoder.yudao.module.infra.dal.dataobject.codegen.CodegenTableDO;
18 18 import cn.iocoder.yudao.module.infra.service.codegen.CodegenService;
19   -import io.swagger.annotations.Api;
20   -import io.swagger.annotations.ApiImplicitParam;
21   -import io.swagger.annotations.ApiImplicitParams;
22   -import io.swagger.annotations.ApiOperation;
  19 +import io.swagger.v3.oas.annotations.tags.Tag;
  20 +import io.swagger.v3.oas.annotations.Parameter;
  21 +import io.swagger.v3.oas.annotations.Parameters;
  22 +import io.swagger.v3.oas.annotations.Operation;
23 23 import org.springframework.security.access.prepost.PreAuthorize;
24 24 import org.springframework.validation.annotation.Validated;
25 25 import org.springframework.web.bind.annotation.*;
... ... @@ -36,7 +36,7 @@ import java.util.Map;
36 36 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
37 37 import static cn.iocoder.yudao.framework.security.core.util.SecurityFrameworkUtils.getLoginUserId;
38 38  
39   -@Api(tags = "管理后台 - 代码生成器")
  39 +@Tag(name = "管理后台 - 代码生成器")
40 40 @RestController
41 41 @RequestMapping("/infra/codegen")
42 42 @Validated
... ... @@ -46,11 +46,11 @@ public class CodegenController {
46 46 private CodegenService codegenService;
47 47  
48 48 @GetMapping("/db/table/list")
49   - @ApiOperation(value = "获得数据库自带的表定义列表", notes = "会过滤掉已经导入 Codegen 的表")
50   - @ApiImplicitParams({
51   - @ApiImplicitParam(name = "dataSourceConfigId", value = "数据源配置的编号", required = true, example = "1", dataTypeClass = Long.class),
52   - @ApiImplicitParam(name = "name", value = "表名,模糊匹配", example = "yudao", dataTypeClass = String.class),
53   - @ApiImplicitParam(name = "comment", value = "描述,模糊匹配", example = "芋道", dataTypeClass = String.class)
  49 + @Operation(summary = "获得数据库自带的表定义列表", description = "会过滤掉已经导入 Codegen 的表")
  50 + @Parameters({
  51 + @Parameter(name = "dataSourceConfigId", description = "数据源配置的编号", required = true, example = "1"),
  52 + @Parameter(name = "name", description = "表名,模糊匹配", example = "yudao"),
  53 + @Parameter(name = "comment", description = "描述,模糊匹配", example = "芋道")
54 54 })
55 55 @PreAuthorize("@ss.hasPermission('infra:codegen:query')")
56 56 public CommonResult<List<DatabaseTableRespVO>> getDatabaseTableList(
... ... @@ -61,7 +61,7 @@ public class CodegenController {
61 61 }
62 62  
63 63 @GetMapping("/table/page")
64   - @ApiOperation("获得表定义分页")
  64 + @Operation(summary = "获得表定义分页")
65 65 @PreAuthorize("@ss.hasPermission('infra:codegen:query')")
66 66 public CommonResult<PageResult<CodegenTableRespVO>> getCodeGenTablePage(@Valid CodegenTablePageReqVO pageReqVO) {
67 67 PageResult<CodegenTableDO> pageResult = codegenService.getCodegenTablePage(pageReqVO);
... ... @@ -69,8 +69,8 @@ public class CodegenController {
69 69 }
70 70  
71 71 @GetMapping("/detail")
72   - @ApiOperation("获得表和字段的明细")
73   - @ApiImplicitParam(name = "tableId", value = "表编号", required = true, example = "1024", dataTypeClass = Long.class)
  72 + @Operation(summary = "获得表和字段的明细")
  73 + @Parameter(name = "tableId", description = "表编号", required = true, example = "1024")
74 74 @PreAuthorize("@ss.hasPermission('infra:codegen:query')")
75 75 public CommonResult<CodegenDetailRespVO> getCodegenDetail(@RequestParam("tableId") Long tableId) {
76 76 CodegenTableDO table = codegenService.getCodegenTablePage(tableId);
... ... @@ -79,14 +79,14 @@ public class CodegenController {
79 79 return success(CodegenConvert.INSTANCE.convert(table, columns));
80 80 }
81 81  
82   - @ApiOperation("基于数据库的表结构,创建代码生成器的表和字段定义")
  82 + @Operation(summary = "基于数据库的表结构,创建代码生成器的表和字段定义")
83 83 @PostMapping("/create-list")
84 84 @PreAuthorize("@ss.hasPermission('infra:codegen:create')")
85 85 public CommonResult<List<Long>> createCodegenList(@Valid @RequestBody CodegenCreateListReqVO reqVO) {
86 86 return success(codegenService.createCodegenList(getLoginUserId(), reqVO));
87 87 }
88 88  
89   - @ApiOperation("更新数据库的表和字段定义")
  89 + @Operation(summary = "更新数据库的表和字段定义")
90 90 @PutMapping("/update")
91 91 @PreAuthorize("@ss.hasPermission('infra:codegen:update')")
92 92 public CommonResult<Boolean> updateCodegen(@Valid @RequestBody CodegenUpdateReqVO updateReqVO) {
... ... @@ -94,36 +94,36 @@ public class CodegenController {
94 94 return success(true);
95 95 }
96 96  
97   - @ApiOperation("基于数据库的表结构,同步数据库的表和字段定义")
  97 + @Operation(summary = "基于数据库的表结构,同步数据库的表和字段定义")
98 98 @PutMapping("/sync-from-db")
99   - @ApiImplicitParam(name = "tableId", value = "表编号", required = true, example = "1024", dataTypeClass = Long.class)
  99 + @Parameter(name = "tableId", description = "表编号", required = true, example = "1024")
100 100 @PreAuthorize("@ss.hasPermission('infra:codegen:update')")
101 101 public CommonResult<Boolean> syncCodegenFromDB(@RequestParam("tableId") Long tableId) {
102 102 codegenService.syncCodegenFromDB(tableId);
103 103 return success(true);
104 104 }
105 105  
106   - @ApiOperation("删除数据库的表和字段定义")
  106 + @Operation(summary = "删除数据库的表和字段定义")
107 107 @DeleteMapping("/delete")
108   - @ApiImplicitParam(name = "tableId", value = "表编号", required = true, example = "1024", dataTypeClass = Long.class)
  108 + @Parameter(name = "tableId", description = "表编号", required = true, example = "1024")
109 109 @PreAuthorize("@ss.hasPermission('infra:codegen:delete')")
110 110 public CommonResult<Boolean> deleteCodegen(@RequestParam("tableId") Long tableId) {
111 111 codegenService.deleteCodegen(tableId);
112 112 return success(true);
113 113 }
114 114  
115   - @ApiOperation("预览生成代码")
  115 + @Operation(summary = "预览生成代码")
116 116 @GetMapping("/preview")
117   - @ApiImplicitParam(name = "tableId", value = "表编号", required = true, example = "1024", dataTypeClass = Long.class)
  117 + @Parameter(name = "tableId", description = "表编号", required = true, example = "1024")
118 118 @PreAuthorize("@ss.hasPermission('infra:codegen:preview')")
119 119 public CommonResult<List<CodegenPreviewRespVO>> previewCodegen(@RequestParam("tableId") Long tableId) {
120 120 Map<String, String> codes = codegenService.generationCodes(tableId);
121 121 return success(CodegenConvert.INSTANCE.convert(codes));
122 122 }
123 123  
124   - @ApiOperation("下载生成代码")
  124 + @Operation(summary = "下载生成代码")
125 125 @GetMapping("/download")
126   - @ApiImplicitParam(name = "tableId", value = "表编号", required = true, example = "1024", dataTypeClass = Long.class)
  126 + @Parameter(name = "tableId", description = "表编号", required = true, example = "1024")
127 127 @PreAuthorize("@ss.hasPermission('infra:codegen:download')")
128 128 public void downloadCodegen(@RequestParam("tableId") Long tableId,
129 129 HttpServletResponse response) throws IOException {
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/CodegenCreateListReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import javax.validation.constraints.NotNull;
8 7 import java.util.List;
9 8  
10   -@ApiModel("管理后台 - 基于数据库的表结构,创建代码生成器的表和字段定义 Request VO")
  9 +@Schema(title = "管理后台 - 基于数据库的表结构,创建代码生成器的表和字段定义 Request VO")
11 10 @Data
12 11 public class CodegenCreateListReqVO {
13 12  
14   - @ApiModelProperty(value = "数据源配置的编号", required = true, example = "1")
  13 + @Schema(title = "数据源配置的编号", required = true, example = "1")
15 14 @NotNull(message = "数据源配置的编号不能为空")
16 15 private Long dataSourceConfigId;
17 16  
18   - @ApiModelProperty(value = "表名数组", required = true, example = "[1, 2, 3]")
  17 + @Schema(title = "表名数组", required = true, example = "[1, 2, 3]")
19 18 @NotNull(message = "表名数组不能为空")
20 19 private List<String> tableNames;
21 20  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/CodegenDetailRespVO.java
... ... @@ -2,20 +2,19 @@ package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo;
2 2  
3 3 import cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.column.CodegenColumnRespVO;
4 4 import cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.table.CodegenTableRespVO;
5   -import io.swagger.annotations.ApiModel;
6   -import io.swagger.annotations.ApiModelProperty;
  5 +import io.swagger.v3.oas.annotations.media.Schema;
7 6 import lombok.Data;
8 7  
9 8 import java.util.List;
10 9  
11   -@ApiModel("管理后台 - 代码生成表和字段的明细 Response VO")
  10 +@Schema(title = "管理后台 - 代码生成表和字段的明细 Response VO")
12 11 @Data
13 12 public class CodegenDetailRespVO {
14 13  
15   - @ApiModelProperty("表定义")
  14 + @Schema(name = "表定义")
16 15 private CodegenTableRespVO table;
17 16  
18   - @ApiModelProperty("字段定义")
  17 + @Schema(name = "字段定义")
19 18 private List<CodegenColumnRespVO> columns;
20 19  
21 20 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/CodegenPreviewRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7   -@ApiModel(value = "管理后台 - 代码生成预览 Response VO", description ="注意,每个文件都是一个该对象")
  6 +@Schema(title = "管理后台 - 代码生成预览 Response VO", description ="注意,每个文件都是一个该对象")
8 7 @Data
9 8 public class CodegenPreviewRespVO {
10 9  
11   - @ApiModelProperty(value = "文件路径", required = true, example = "java/cn/iocoder/yudao/adminserver/modules/system/controller/test/SysTestDemoController.java")
  10 + @Schema(title = "文件路径", required = true, example = "java/cn/iocoder/yudao/adminserver/modules/system/controller/test/SysTestDemoController.java")
12 11 private String filePath;
13 12  
14   - @ApiModelProperty(value = "代码", required = true, example = "Hello World")
  13 + @Schema(title = "代码", required = true, example = "Hello World")
15 14 private String code;
16 15  
17 16 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/CodegenUpdateReqVO.java
... ... @@ -4,8 +4,7 @@ import cn.hutool.core.util.ObjectUtil;
4 4 import cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.column.CodegenColumnBaseVO;
5 5 import cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.table.CodegenTableBaseVO;
6 6 import cn.iocoder.yudao.module.infra.enums.codegen.CodegenSceneEnum;
7   -import io.swagger.annotations.ApiModel;
8   -import io.swagger.annotations.ApiModelProperty;
  7 +import io.swagger.v3.oas.annotations.media.Schema;
9 8 import lombok.Data;
10 9 import lombok.EqualsAndHashCode;
11 10 import lombok.ToString;
... ... @@ -15,7 +14,7 @@ import javax.validation.constraints.AssertTrue;
15 14 import javax.validation.constraints.NotNull;
16 15 import java.util.List;
17 16  
18   -@ApiModel("管理后台 - 代码生成表和字段的修改 Request VO")
  17 +@Schema(title = "管理后台 - 代码生成表和字段的修改 Request VO")
19 18 @Data
20 19 public class CodegenUpdateReqVO {
21 20  
... ... @@ -27,14 +26,14 @@ public class CodegenUpdateReqVO {
27 26 @NotNull(message = "字段定义不能为空")
28 27 private List<Column> columns;
29 28  
30   - @ApiModel("更新表定义")
  29 + @Schema(title = "更新表定义")
31 30 @Data
32 31 @EqualsAndHashCode(callSuper = true)
33 32 @ToString(callSuper = true)
34 33 @Valid
35 34 public static class Table extends CodegenTableBaseVO {
36 35  
37   - @ApiModelProperty(value = "编号", required = true, example = "1")
  36 + @Schema(title = "编号", required = true, example = "1")
38 37 private Long id;
39 38  
40 39 @AssertTrue(message = "上级菜单不能为空")
... ... @@ -46,13 +45,13 @@ public class CodegenUpdateReqVO {
46 45  
47 46 }
48 47  
49   - @ApiModel("更新表定义")
  48 + @Schema(title = "更新表定义")
50 49 @Data
51 50 @EqualsAndHashCode(callSuper = true)
52 51 @ToString(callSuper = true)
53 52 public static class Column extends CodegenColumnBaseVO {
54 53  
55   - @ApiModelProperty(value = "编号", required = true, example = "1")
  54 + @Schema(title = "编号", required = true, example = "1")
56 55 private Long id;
57 56  
58 57 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/column/CodegenColumnBaseVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.column;
2   -
3   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4  
6 5 import javax.validation.constraints.NotNull;
... ... @@ -12,73 +11,73 @@ import javax.validation.constraints.NotNull;
12 11 @Data
13 12 public class CodegenColumnBaseVO {
14 13  
15   - @ApiModelProperty(value = "表编号", required = true, example = "1")
  14 + @Schema(title = "表编号", required = true, example = "1")
16 15 @NotNull(message = "表编号不能为空")
17 16 private Long tableId;
18 17  
19   - @ApiModelProperty(value = "字段名", required = true, example = "user_age")
  18 + @Schema(title = "字段名", required = true, example = "user_age")
20 19 @NotNull(message = "字段名不能为空")
21 20 private String columnName;
22 21  
23   - @ApiModelProperty(value = "字段类型", required = true, example = "int(11)")
  22 + @Schema(title = "字段类型", required = true, example = "int(11)")
24 23 @NotNull(message = "字段类型不能为空")
25 24 private String dataType;
26 25  
27   - @ApiModelProperty(value = "字段描述", required = true, example = "年龄")
  26 + @Schema(title = "字段描述", required = true, example = "年龄")
28 27 @NotNull(message = "字段描述不能为空")
29 28 private String columnComment;
30 29  
31   - @ApiModelProperty(value = "是否允许为空", required = true, example = "true")
  30 + @Schema(title = "是否允许为空", required = true, example = "true")
32 31 @NotNull(message = "是否允许为空不能为空")
33 32 private Boolean nullable;
34 33  
35   - @ApiModelProperty(value = "是否主键", required = true, example = "false")
  34 + @Schema(title = "是否主键", required = true, example = "false")
36 35 @NotNull(message = "是否主键不能为空")
37 36 private Boolean primaryKey;
38 37  
39   - @ApiModelProperty(value = "是否自增", required = true, example = "true")
  38 + @Schema(title = "是否自增", required = true, example = "true")
40 39 @NotNull(message = "是否自增不能为空")
41 40 private String autoIncrement;
42 41  
43   - @ApiModelProperty(value = "排序", required = true, example = "10")
  42 + @Schema(title = "排序", required = true, example = "10")
44 43 @NotNull(message = "排序不能为空")
45 44 private Integer ordinalPosition;
46 45  
47   - @ApiModelProperty(value = "Java 属性类型", required = true, example = "userAge")
  46 + @Schema(title = "Java 属性类型", required = true, example = "userAge")
48 47 @NotNull(message = "Java 属性类型不能为空")
49 48 private String javaType;
50 49  
51   - @ApiModelProperty(value = "Java 属性名", required = true, example = "Integer")
  50 + @Schema(title = "Java 属性名", required = true, example = "Integer")
52 51 @NotNull(message = "Java 属性名不能为空")
53 52 private String javaField;
54 53  
55   - @ApiModelProperty(value = "字典类型", example = "sys_gender")
  54 + @Schema(title = "字典类型", example = "sys_gender")
56 55 private String dictType;
57 56  
58   - @ApiModelProperty(value = "数据示例", example = "1024")
  57 + @Schema(title = "数据示例", example = "1024")
59 58 private String example;
60 59  
61   - @ApiModelProperty(value = "是否为 Create 创建操作的字段", required = true, example = "true")
  60 + @Schema(title = "是否为 Create 创建操作的字段", required = true, example = "true")
62 61 @NotNull(message = "是否为 Create 创建操作的字段不能为空")
63 62 private Boolean createOperation;
64 63  
65   - @ApiModelProperty(value = "是否为 Update 更新操作的字段", required = true, example = "false")
  64 + @Schema(title = "是否为 Update 更新操作的字段", required = true, example = "false")
66 65 @NotNull(message = "是否为 Update 更新操作的字段不能为空")
67 66 private Boolean updateOperation;
68 67  
69   - @ApiModelProperty(value = "是否为 List 查询操作的字段", required = true, example = "true")
  68 + @Schema(title = "是否为 List 查询操作的字段", required = true, example = "true")
70 69 @NotNull(message = "是否为 List 查询操作的字段不能为空")
71 70 private Boolean listOperation;
72 71  
73   - @ApiModelProperty(value = "List 查询操作的条件类型", required = true, example = "LIKE", notes = "参见 CodegenColumnListConditionEnum 枚举")
  72 + @Schema(title = "List 查询操作的条件类型", required = true, example = "LIKE", description = "参见 CodegenColumnListConditionEnum 枚举")
74 73 @NotNull(message = "List 查询操作的条件类型不能为空")
75 74 private String listOperationCondition;
76 75  
77   - @ApiModelProperty(value = "是否为 List 查询操作的返回字段", required = true, example = "true")
  76 + @Schema(title = "是否为 List 查询操作的返回字段", required = true, example = "true")
78 77 @NotNull(message = "是否为 List 查询操作的返回字段不能为空")
79 78 private Boolean listOperationResult;
80 79  
81   - @ApiModelProperty(value = "显示类型", required = true, example = "input")
  80 + @Schema(title = "显示类型", required = true, example = "input")
82 81 @NotNull(message = "显示类型不能为空")
83 82 private String htmlType;
84 83  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/column/CodegenColumnRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.column;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import java.time.LocalDateTime;
10 9  
11   -@ApiModel("管理后台 - 代码生成字段定义 Response VO")
  10 +@Schema(title = "管理后台 - 代码生成字段定义 Response VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class CodegenColumnRespVO extends CodegenColumnBaseVO {
16 15  
17   - @ApiModelProperty(value = "编号", required = true, example = "1")
  16 + @Schema(title = "编号", required = true, example = "1")
18 17 private Long id;
19 18  
20   - @ApiModelProperty(value = "创建时间", required = true)
  19 + @Schema(title = "创建时间", required = true)
21 20 private LocalDateTime createTime;
22 21  
23 22 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/table/CodegenTableBaseVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.table;
2   -
3   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4  
6 5 import javax.validation.constraints.NotNull;
... ... @@ -12,46 +11,46 @@ import javax.validation.constraints.NotNull;
12 11 @Data
13 12 public class CodegenTableBaseVO {
14 13  
15   - @ApiModelProperty(value = "生成场景", required = true, example = "1", notes = "参见 CodegenSceneEnum 枚举")
  14 + @Schema(title = "生成场景", required = true, example = "1", description = "参见 CodegenSceneEnum 枚举")
16 15 @NotNull(message = "导入类型不能为空")
17 16 private Integer scene;
18 17  
19   - @ApiModelProperty(value = "表名称", required = true, example = "yudao")
  18 + @Schema(title = "表名称", required = true, example = "yudao")
20 19 @NotNull(message = "表名称不能为空")
21 20 private String tableName;
22 21  
23   - @ApiModelProperty(value = "表描述", required = true, example = "芋道")
  22 + @Schema(title = "表描述", required = true, example = "芋道")
24 23 @NotNull(message = "表描述不能为空")
25 24 private String tableComment;
26 25  
27   - @ApiModelProperty(value = "备注", example = "我是备注")
  26 + @Schema(title = "备注", example = "我是备注")
28 27 private String remark;
29 28  
30   - @ApiModelProperty(value = "模块名", required = true, example = "system")
  29 + @Schema(title = "模块名", required = true, example = "system")
31 30 @NotNull(message = "模块名不能为空")
32 31 private String moduleName;
33 32  
34   - @ApiModelProperty(value = "业务名", required = true, example = "codegen")
  33 + @Schema(title = "业务名", required = true, example = "codegen")
35 34 @NotNull(message = "业务名不能为空")
36 35 private String businessName;
37 36  
38   - @ApiModelProperty(value = "类名称", required = true, example = "CodegenTable")
  37 + @Schema(title = "类名称", required = true, example = "CodegenTable")
39 38 @NotNull(message = "类名称不能为空")
40 39 private String className;
41 40  
42   - @ApiModelProperty(value = "类描述", required = true, example = "代码生成器的表定义")
  41 + @Schema(title = "类描述", required = true, example = "代码生成器的表定义")
43 42 @NotNull(message = "类描述不能为空")
44 43 private String classComment;
45 44  
46   - @ApiModelProperty(value = "作者", required = true, example = "芋道源码")
  45 + @Schema(title = "作者", required = true, example = "芋道源码")
47 46 @NotNull(message = "作者不能为空")
48 47 private String author;
49 48  
50   - @ApiModelProperty(value = "模板类型", required = true, example = "1", notes = "参见 CodegenTemplateTypeEnum 枚举")
  49 + @Schema(title = "模板类型", required = true, example = "1", description = "参见 CodegenTemplateTypeEnum 枚举")
51 50 @NotNull(message = "模板类型不能为空")
52 51 private Integer templateType;
53 52  
54   - @ApiModelProperty(value = "父菜单编号", example = "1024")
  53 + @Schema(title = "父菜单编号", example = "1024")
55 54 private Long parentMenuId;
56 55  
57 56 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/table/CodegenTablePageReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.table;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,19 +11,19 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 表定义分页 Request VO")
  14 +@Schema(title = "管理后台 - 表定义分页 Request VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class CodegenTablePageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "表名称", example = "yudao", notes = "模糊匹配")
  20 + @Schema(title = "表名称", example = "yudao", description = "模糊匹配")
22 21 private String tableName;
23 22  
24   - @ApiModelProperty(value = "表描述", example = "芋道", notes = "模糊匹配")
  23 + @Schema(title = "表描述", example = "芋道", description = "模糊匹配")
25 24 private String tableComment;
26 25  
27   - @ApiModelProperty(value = "创建时间", example = "[2022-07-01 00:00:00,2022-07-01 23:59:59]")
  26 + @Schema(title = "创建时间", example = "[2022-07-01 00:00:00,2022-07-01 23:59:59]")
28 27 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
29 28 private LocalDateTime[] createTime;
30 29  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/table/CodegenTableRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.table;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import java.time.LocalDateTime;
10 9  
11   -@ApiModel("管理后台 - 代码生成表定义 Response VO")
  10 +@Schema(title = "管理后台 - 代码生成表定义 Response VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class CodegenTableRespVO extends CodegenTableBaseVO {
16 15  
17   - @ApiModelProperty(value = "编号", required = true, example = "1")
  16 + @Schema(title = "编号", required = true, example = "1")
18 17 private Long id;
19 18  
20   - @ApiModelProperty(value = "主键编号", required = true, example = "1024")
  19 + @Schema(title = "主键编号", required = true, example = "1024")
21 20 private Integer dataSourceConfigId;
22 21  
23   - @ApiModelProperty(value = "创建时间", required = true)
  22 + @Schema(title = "创建时间", required = true)
24 23 private LocalDateTime createTime;
25 24  
26   - @ApiModelProperty(value = "更新时间", required = true)
  25 + @Schema(title = "更新时间", required = true)
27 26 private LocalDateTime updateTime;
28 27  
29 28 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/codegen/vo/table/DatabaseTableRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.codegen.vo.table;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7   -@ApiModel("管理后台 - 数据库的表定义 Response VO")
  6 +@Schema(title = "管理后台 - 数据库的表定义 Response VO")
8 7 @Data
9 8 public class DatabaseTableRespVO {
10 9  
11   - @ApiModelProperty(value = "表名称", required = true, example = "yuanma")
  10 + @Schema(title = "表名称", required = true, example = "yuanma")
12 11 private String name;
13 12  
14   - @ApiModelProperty(value = "表描述", required = true, example = "芋道源码")
  13 + @Schema(title = "表描述", required = true, example = "芋道源码")
15 14 private String comment;
16 15  
17 16 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/ConfigController.java
... ... @@ -10,9 +10,9 @@ import cn.iocoder.yudao.module.infra.convert.config.ConfigConvert;
10 10 import cn.iocoder.yudao.module.infra.dal.dataobject.config.ConfigDO;
11 11 import cn.iocoder.yudao.module.infra.service.config.ConfigService;
12 12 import cn.iocoder.yudao.module.infra.enums.ErrorCodeConstants;
13   -import io.swagger.annotations.Api;
14   -import io.swagger.annotations.ApiImplicitParam;
15   -import io.swagger.annotations.ApiOperation;
  13 +import io.swagger.v3.oas.annotations.tags.Tag;
  14 +import io.swagger.v3.oas.annotations.Parameter;
  15 +import io.swagger.v3.oas.annotations.Operation;
16 16 import org.springframework.security.access.prepost.PreAuthorize;
17 17 import org.springframework.validation.annotation.Validated;
18 18 import org.springframework.web.bind.annotation.*;
... ... @@ -26,7 +26,7 @@ import java.util.List;
26 26 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
27 27 import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT;
28 28  
29   -@Api(tags = "管理后台 - 参数配置")
  29 +@Tag(name = "管理后台 - 参数配置")
30 30 @RestController
31 31 @RequestMapping("/infra/config")
32 32 @Validated
... ... @@ -36,14 +36,14 @@ public class ConfigController {
36 36 private ConfigService configService;
37 37  
38 38 @PostMapping("/create")
39   - @ApiOperation("创建参数配置")
  39 + @Operation(summary = "创建参数配置")
40 40 @PreAuthorize("@ss.hasPermission('infra:config:create')")
41 41 public CommonResult<Long> createConfig(@Valid @RequestBody ConfigCreateReqVO reqVO) {
42 42 return success(configService.createConfig(reqVO));
43 43 }
44 44  
45 45 @PutMapping("/update")
46   - @ApiOperation("修改参数配置")
  46 + @Operation(summary = "修改参数配置")
47 47 @PreAuthorize("@ss.hasPermission('infra:config:update')")
48 48 public CommonResult<Boolean> updateConfig(@Valid @RequestBody ConfigUpdateReqVO reqVO) {
49 49 configService.updateConfig(reqVO);
... ... @@ -51,8 +51,8 @@ public class ConfigController {
51 51 }
52 52  
53 53 @DeleteMapping("/delete")
54   - @ApiOperation("删除参数配置")
55   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  54 + @Operation(summary = "删除参数配置")
  55 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
56 56 @PreAuthorize("@ss.hasPermission('infra:config:delete')")
57 57 public CommonResult<Boolean> deleteConfig(@RequestParam("id") Long id) {
58 58 configService.deleteConfig(id);
... ... @@ -60,16 +60,16 @@ public class ConfigController {
60 60 }
61 61  
62 62 @GetMapping(value = "/get")
63   - @ApiOperation("获得参数配置")
64   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  63 + @Operation(summary = "获得参数配置")
  64 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
65 65 @PreAuthorize("@ss.hasPermission('infra:config:query')")
66 66 public CommonResult<ConfigRespVO> getConfig(@RequestParam("id") Long id) {
67 67 return success(ConfigConvert.INSTANCE.convert(configService.getConfig(id)));
68 68 }
69 69  
70 70 @GetMapping(value = "/get-value-by-key")
71   - @ApiOperation(value = "根据参数键名查询参数值", notes = "不可见的配置,不允许返回给前端")
72   - @ApiImplicitParam(name = "key", value = "参数键", required = true, example = "yunai.biz.username", dataTypeClass = String.class)
  71 + @Operation(summary = "根据参数键名查询参数值", description = "不可见的配置,不允许返回给前端")
  72 + @Parameter(name = "key", description = "参数键", required = true, example = "yunai.biz.username")
73 73 public CommonResult<String> getConfigKey(@RequestParam("key") String key) {
74 74 ConfigDO config = configService.getConfigByKey(key);
75 75 if (config == null) {
... ... @@ -82,7 +82,7 @@ public class ConfigController {
82 82 }
83 83  
84 84 @GetMapping("/page")
85   - @ApiOperation("获取参数配置分页")
  85 + @Operation(summary = "获取参数配置分页")
86 86 @PreAuthorize("@ss.hasPermission('infra:config:query')")
87 87 public CommonResult<PageResult<ConfigRespVO>> getConfigPage(@Valid ConfigPageReqVO reqVO) {
88 88 PageResult<ConfigDO> page = configService.getConfigPage(reqVO);
... ... @@ -90,7 +90,7 @@ public class ConfigController {
90 90 }
91 91  
92 92 @GetMapping("/export")
93   - @ApiOperation("导出参数配置")
  93 + @Operation(summary = "导出参数配置")
94 94 @PreAuthorize("@ss.hasPermission('infra:config:export')")
95 95 @OperateLog(type = EXPORT)
96 96 public void exportSysConfig(@Valid ConfigExportReqVO reqVO,
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/vo/ConfigBaseVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.config.vo;
2   -
3   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4  
6 5 import javax.validation.constraints.NotBlank;
... ... @@ -15,26 +14,26 @@ import javax.validation.constraints.Size;
15 14 @Data
16 15 public class ConfigBaseVO {
17 16  
18   - @ApiModelProperty(value = "参数分组", required = true, example = "biz")
  17 + @Schema(title = "参数分组", required = true, example = "biz")
19 18 @NotEmpty(message = "参数分组不能为空")
20 19 @Size(max = 50, message = "参数名称不能超过50个字符")
21 20 private String category;
22 21  
23   - @ApiModelProperty(value = "参数名称", required = true, example = "数据库名")
  22 + @Schema(title = "参数名称", required = true, example = "数据库名")
24 23 @NotBlank(message = "参数名称不能为空")
25 24 @Size(max = 100, message = "参数名称不能超过100个字符")
26 25 private String name;
27 26  
28   - @ApiModelProperty(value = "参数键值", required = true, example = "1024")
  27 + @Schema(title = "参数键值", required = true, example = "1024")
29 28 @NotBlank(message = "参数键值不能为空")
30 29 @Size(max = 500, message = "参数键值长度不能超过500个字符")
31 30 private String value;
32 31  
33   - @ApiModelProperty(value = "是否敏感", required = true, example = "true")
  32 + @Schema(title = "是否敏感", required = true, example = "true")
34 33 @NotNull(message = "是否敏感不能为空")
35 34 private Boolean visible;
36 35  
37   - @ApiModelProperty(value = "备注", example = "备注一下很帅气!")
  36 + @Schema(title = "备注", example = "备注一下很帅气!")
38 37 private String remark;
39 38  
40 39 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/vo/ConfigCreateReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.config.vo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6  
8 7 import javax.validation.constraints.NotBlank;
9 8 import javax.validation.constraints.Size;
10 9  
11   -@ApiModel("管理后台 - 参数配置创建 Request VO")
  10 +@Schema(title = "管理后台 - 参数配置创建 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 public class ConfigCreateReqVO extends ConfigBaseVO {
15 14  
16   - @ApiModelProperty(value = "参数键名", required = true, example = "yunai.db.username")
  15 + @Schema(title = "参数键名", required = true, example = "yunai.db.username")
17 16 @NotBlank(message = "参数键名长度不能为空")
18 17 @Size(max = 100, message = "参数键名长度不能超过100个字符")
19 18 private String key;
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/vo/ConfigExportReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.config.vo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import org.springframework.format.annotation.DateTimeFormat;
7 6  
... ... @@ -9,20 +8,20 @@ import java.time.LocalDateTime;
9 8  
10 9 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
11 10  
12   -@ApiModel("管理后台 - 参数配置导出 Request VO")
  11 +@Schema(title = "管理后台 - 参数配置导出 Request VO")
13 12 @Data
14 13 public class ConfigExportReqVO {
15 14  
16   - @ApiModelProperty(value = "参数名称", example = "模糊匹配")
  15 + @Schema(title = "参数名称", example = "模糊匹配")
17 16 private String name;
18 17  
19   - @ApiModelProperty(value = "参数键名", example = "yunai.db.username", notes = "模糊匹配")
  18 + @Schema(title = "参数键名", example = "yunai.db.username", description = "模糊匹配")
20 19 private String key;
21 20  
22   - @ApiModelProperty(value = "参数类型", example = "1", notes = "参见 SysConfigTypeEnum 枚举")
  21 + @Schema(title = "参数类型", example = "1", description = "参见 SysConfigTypeEnum 枚举")
23 22 private Integer type;
24 23  
25   - @ApiModelProperty(value = "创建时间", example = "[2022-07-01 00:00:00,2022-07-01 23:59:59]")
  24 + @Schema(title = "创建时间", example = "[2022-07-01 00:00:00,2022-07-01 23:59:59]")
26 25 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
27 26 private LocalDateTime[] createTime;
28 27  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/vo/ConfigPageReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.config.vo;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,22 +11,22 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 参数配置分页 Request VO")
  14 +@Schema(title = "管理后台 - 参数配置分页 Request VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class ConfigPageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "数据源名称", example = "模糊匹配")
  20 + @Schema(title = "数据源名称", example = "模糊匹配")
22 21 private String name;
23 22  
24   - @ApiModelProperty(value = "参数键名", example = "yunai.db.username", notes = "模糊匹配")
  23 + @Schema(title = "参数键名", example = "yunai.db.username", description = "模糊匹配")
25 24 private String key;
26 25  
27   - @ApiModelProperty(value = "参数类型", example = "1", notes = "参见 SysConfigTypeEnum 枚举")
  26 + @Schema(title = "参数类型", example = "1", description = "参见 SysConfigTypeEnum 枚举")
28 27 private Integer type;
29 28  
30   - @ApiModelProperty(value = "创建时间", example = "[2022-07-01 00:00:00,2022-07-01 23:59:59]")
  29 + @Schema(title = "创建时间", example = "[2022-07-01 00:00:00,2022-07-01 23:59:59]")
31 30 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
32 31 private LocalDateTime[] createTime;
33 32  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/vo/ConfigRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.config.vo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6  
... ... @@ -9,23 +8,23 @@ import javax.validation.constraints.NotBlank;
9 8 import javax.validation.constraints.Size;
10 9 import java.time.LocalDateTime;
11 10  
12   -@ApiModel("管理后台 - 参数配置信息 Response VO")
  11 +@Schema(title = "管理后台 - 参数配置信息 Response VO")
13 12 @Data
14 13 @EqualsAndHashCode(callSuper = true)
15 14 public class ConfigRespVO extends ConfigBaseVO {
16 15  
17   - @ApiModelProperty(value = "参数配置序号", required = true, example = "1024")
  16 + @Schema(title = "参数配置序号", required = true, example = "1024")
18 17 private Long id;
19 18  
20   - @ApiModelProperty(value = "参数键名", required = true, example = "yunai.db.username")
  19 + @Schema(title = "参数键名", required = true, example = "yunai.db.username")
21 20 @NotBlank(message = "参数键名长度不能为空")
22 21 @Size(max = 100, message = "参数键名长度不能超过100个字符")
23 22 private String key;
24 23  
25   - @ApiModelProperty(value = "参数类型", required = true, example = "1", notes = "参见 SysConfigTypeEnum 枚举")
  24 + @Schema(title = "参数类型", required = true, example = "1", description = "参见 SysConfigTypeEnum 枚举")
26 25 private Integer type;
27 26  
28   - @ApiModelProperty(value = "创建时间", required = true, example = "时间戳格式")
  27 + @Schema(title = "创建时间", required = true, example = "时间戳格式")
29 28 private LocalDateTime createTime;
30 29  
31 30 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/config/vo/ConfigUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.config.vo;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
8 7  
9 8 import javax.validation.constraints.NotNull;
10 9  
11   -@ApiModel("管理后台 - 参数配置创建 Request VO")
  10 +@Schema(title = "管理后台 - 参数配置创建 Request VO")
12 11 @Data
13 12 @EqualsAndHashCode(callSuper = true)
14 13 @ToString(callSuper = true)
15 14 public class ConfigUpdateReqVO extends ConfigBaseVO {
16 15  
17   - @ApiModelProperty(value = "参数配置序号", required = true, example = "1024")
  16 + @Schema(title = "参数配置序号", required = true, example = "1024")
18 17 @NotNull(message = "参数配置编号不能为空")
19 18 private Long id;
20 19  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/db/DataSourceConfigController.java
... ... @@ -7,9 +7,9 @@ import cn.iocoder.yudao.module.infra.controller.admin.db.vo.DataSourceConfigUpda
7 7 import cn.iocoder.yudao.module.infra.convert.db.DataSourceConfigConvert;
8 8 import cn.iocoder.yudao.module.infra.dal.dataobject.db.DataSourceConfigDO;
9 9 import cn.iocoder.yudao.module.infra.service.db.DataSourceConfigService;
10   -import io.swagger.annotations.Api;
11   -import io.swagger.annotations.ApiImplicitParam;
12   -import io.swagger.annotations.ApiOperation;
  10 +import io.swagger.v3.oas.annotations.tags.Tag;
  11 +import io.swagger.v3.oas.annotations.Parameter;
  12 +import io.swagger.v3.oas.annotations.Operation;
13 13 import org.springframework.security.access.prepost.PreAuthorize;
14 14 import org.springframework.validation.annotation.Validated;
15 15 import org.springframework.web.bind.annotation.*;
... ... @@ -20,7 +20,7 @@ import java.util.List;
20 20  
21 21 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
22 22  
23   -@Api(tags = "管理后台 - 数据源配置")
  23 +@Tag(name = "管理后台 - 数据源配置")
24 24 @RestController
25 25 @RequestMapping("/infra/data-source-config")
26 26 @Validated
... ... @@ -30,14 +30,14 @@ public class DataSourceConfigController {
30 30 private DataSourceConfigService dataSourceConfigService;
31 31  
32 32 @PostMapping("/create")
33   - @ApiOperation("创建数据源配置")
  33 + @Operation(summary = "创建数据源配置")
34 34 @PreAuthorize("@ss.hasPermission('infra:data-source-config:create')")
35 35 public CommonResult<Long> createDataSourceConfig(@Valid @RequestBody DataSourceConfigCreateReqVO createReqVO) {
36 36 return success(dataSourceConfigService.createDataSourceConfig(createReqVO));
37 37 }
38 38  
39 39 @PutMapping("/update")
40   - @ApiOperation("更新数据源配置")
  40 + @Operation(summary = "更新数据源配置")
41 41 @PreAuthorize("@ss.hasPermission('infra:data-source-config:update')")
42 42 public CommonResult<Boolean> updateDataSourceConfig(@Valid @RequestBody DataSourceConfigUpdateReqVO updateReqVO) {
43 43 dataSourceConfigService.updateDataSourceConfig(updateReqVO);
... ... @@ -45,8 +45,8 @@ public class DataSourceConfigController {
45 45 }
46 46  
47 47 @DeleteMapping("/delete")
48   - @ApiOperation("删除数据源配置")
49   - @ApiImplicitParam(name = "id", value = "编号", required = true, dataTypeClass = Long.class)
  48 + @Operation(summary = "删除数据源配置")
  49 + @Parameter(name = "id", description = "编号", required = true)
50 50 @PreAuthorize("@ss.hasPermission('infra:data-source-config:delete')")
51 51 public CommonResult<Boolean> deleteDataSourceConfig(@RequestParam("id") Long id) {
52 52 dataSourceConfigService.deleteDataSourceConfig(id);
... ... @@ -54,8 +54,8 @@ public class DataSourceConfigController {
54 54 }
55 55  
56 56 @GetMapping("/get")
57   - @ApiOperation("获得数据源配置")
58   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  57 + @Operation(summary = "获得数据源配置")
  58 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
59 59 @PreAuthorize("@ss.hasPermission('infra:data-source-config:query')")
60 60 public CommonResult<DataSourceConfigRespVO> getDataSourceConfig(@RequestParam("id") Long id) {
61 61 DataSourceConfigDO dataSourceConfig = dataSourceConfigService.getDataSourceConfig(id);
... ... @@ -63,7 +63,7 @@ public class DataSourceConfigController {
63 63 }
64 64  
65 65 @GetMapping("/list")
66   - @ApiOperation("获得数据源配置列表")
  66 + @Operation(summary = "获得数据源配置列表")
67 67 @PreAuthorize("@ss.hasPermission('infra:data-source-config:query')")
68 68 public CommonResult<List<DataSourceConfigRespVO>> getDataSourceConfigList() {
69 69 List<DataSourceConfigDO> list = dataSourceConfigService.getDataSourceConfigList();
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/db/DatabaseDocController.java
... ... @@ -13,9 +13,9 @@ import com.baomidou.dynamic.datasource.spring.boot.autoconfigure.DataSourcePrope
13 13 import com.baomidou.dynamic.datasource.spring.boot.autoconfigure.DynamicDataSourceProperties;
14 14 import com.zaxxer.hikari.HikariConfig;
15 15 import com.zaxxer.hikari.HikariDataSource;
16   -import io.swagger.annotations.Api;
17   -import io.swagger.annotations.ApiImplicitParam;
18   -import io.swagger.annotations.ApiOperation;
  16 +import io.swagger.v3.oas.annotations.tags.Tag;
  17 +import io.swagger.v3.oas.annotations.Parameter;
  18 +import io.swagger.v3.oas.annotations.Operation;
19 19 import org.springframework.web.bind.annotation.GetMapping;
20 20 import org.springframework.web.bind.annotation.RequestMapping;
21 21 import org.springframework.web.bind.annotation.RequestParam;
... ... @@ -27,7 +27,7 @@ import java.io.File;
27 27 import java.io.IOException;
28 28 import java.util.Arrays;
29 29  
30   -@Api(tags = "管理后台 - 数据库文档")
  30 +@Tag(name = "管理后台 - 数据库文档")
31 31 @RestController
32 32 @RequestMapping("/infra/db-doc")
33 33 public class DatabaseDocController {
... ... @@ -42,27 +42,24 @@ public class DatabaseDocController {
42 42 private static final String DOC_DESCRIPTION = "文档描述";
43 43  
44 44 @GetMapping("/export-html")
45   - @ApiOperation("导出 html 格式的数据文档")
46   - @ApiImplicitParam(name = "deleteFile", value = "是否删除在服务器本地生成的数据库文档", example = "true",
47   - dataTypeClass = Boolean.class)
  45 + @Operation(summary = "导出 html 格式的数据文档")
  46 + @Parameter(name = "deleteFile", description = "是否删除在服务器本地生成的数据库文档", example = "true")
48 47 public void exportHtml(@RequestParam(defaultValue = "true") Boolean deleteFile,
49 48 HttpServletResponse response) throws IOException {
50 49 doExportFile(EngineFileType.HTML, deleteFile, response);
51 50 }
52 51  
53 52 @GetMapping("/export-word")
54   - @ApiOperation("导出 word 格式的数据文档")
55   - @ApiImplicitParam(name = "deleteFile", value = "是否删除在服务器本地生成的数据库文档", example = "true",
56   - dataTypeClass = Boolean.class)
  53 + @Operation(summary = "导出 word 格式的数据文档")
  54 + @Parameter(name = "deleteFile", description = "是否删除在服务器本地生成的数据库文档", example = "true")
57 55 public void exportWord(@RequestParam(defaultValue = "true") Boolean deleteFile,
58 56 HttpServletResponse response) throws IOException {
59 57 doExportFile(EngineFileType.WORD, deleteFile, response);
60 58 }
61 59  
62 60 @GetMapping("/export-markdown")
63   - @ApiOperation("导出 markdown 格式的数据文档")
64   - @ApiImplicitParam(name = "deleteFile", value = "是否删除在服务器本地生成的数据库文档", example = "true",
65   - dataTypeClass = Boolean.class)
  61 + @Operation(summary = "导出 markdown 格式的数据文档")
  62 + @Parameter(name = "deleteFile", description = "是否删除在服务器本地生成的数据库文档", example = "true")
66 63 public void exportMarkdown(@RequestParam(defaultValue = "true") Boolean deleteFile,
67 64 HttpServletResponse response) throws IOException {
68 65 doExportFile(EngineFileType.MD, deleteFile, response);
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/db/vo/DataSourceConfigBaseVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.db.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import java.util.*;
5   -import io.swagger.annotations.*;
6 4 import javax.validation.constraints.*;
7 5  
8 6 /**
... ... @@ -12,15 +10,15 @@ import javax.validation.constraints.*;
12 10 @Data
13 11 public class DataSourceConfigBaseVO {
14 12  
15   - @ApiModelProperty(value = "数据源名称", required = true, example = "test")
  13 + @Schema(title = "数据源名称", required = true, example = "test")
16 14 @NotNull(message = "数据源名称不能为空")
17 15 private String name;
18 16  
19   - @ApiModelProperty(value = "数据源连接", required = true, example = "jdbc:mysql://127.0.0.1:3306/ruoyi-vue-pro")
  17 + @Schema(title = "数据源连接", required = true, example = "jdbc:mysql://127.0.0.1:3306/ruoyi-vue-pro")
20 18 @NotNull(message = "数据源连接不能为空")
21 19 private String url;
22 20  
23   - @ApiModelProperty(value = "用户名", required = true, example = "root")
  21 + @Schema(title = "用户名", required = true, example = "root")
24 22 @NotNull(message = "用户名不能为空")
25 23 private String username;
26 24  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/db/vo/DataSourceConfigCreateReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.db.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import java.util.*;
5   -import io.swagger.annotations.*;
6 4 import javax.validation.constraints.*;
7 5  
8   -@ApiModel("管理后台 - 数据源配置创建 Request VO")
  6 +@Schema(title = "管理后台 - 数据源配置创建 Request VO")
9 7 @Data
10 8 @EqualsAndHashCode(callSuper = true)
11 9 @ToString(callSuper = true)
12 10 public class DataSourceConfigCreateReqVO extends DataSourceConfigBaseVO {
13 11  
14   - @ApiModelProperty(value = "密码", required = true, example = "123456")
  12 + @Schema(title = "密码", required = true, example = "123456")
15 13 @NotNull(message = "密码不能为空")
16 14 private String password;
17 15  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/db/vo/DataSourceConfigRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.db.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4 4  
5 5 import java.time.LocalDateTime;
6   -import io.swagger.annotations.*;
7 6  
8   -@ApiModel("管理后台 - 数据源配置 Response VO")
  7 +@Schema(title = "管理后台 - 数据源配置 Response VO")
9 8 @Data
10 9 @EqualsAndHashCode(callSuper = true)
11 10 @ToString(callSuper = true)
12 11 public class DataSourceConfigRespVO extends DataSourceConfigBaseVO {
13 12  
14   - @ApiModelProperty(value = "主键编号", required = true, example = "1024")
  13 + @Schema(title = "主键编号", required = true, example = "1024")
15 14 private Integer id;
16 15  
17   - @ApiModelProperty(value = "创建时间", required = true)
  16 + @Schema(title = "创建时间", required = true)
18 17 private LocalDateTime createTime;
19 18  
20 19 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/db/vo/DataSourceConfigUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.db.vo;
2   -
  2 +import io.swagger.v3.oas.annotations.media.Schema;
3 3 import lombok.*;
4   -import java.util.*;
5   -import io.swagger.annotations.*;
6 4 import javax.validation.constraints.*;
7 5  
8   -@ApiModel("管理后台 - 数据源配置更新 Request VO")
  6 +@Schema(title = "管理后台 - 数据源配置更新 Request VO")
9 7 @Data
10 8 @EqualsAndHashCode(callSuper = true)
11 9 @ToString(callSuper = true)
12 10 public class DataSourceConfigUpdateReqVO extends DataSourceConfigBaseVO {
13 11  
14   - @ApiModelProperty(value = "主键编号", required = true, example = "1024")
  12 + @Schema(title = "主键编号", required = true, example = "1024")
15 13 @NotNull(message = "主键编号不能为空")
16 14 private Long id;
17 15  
18   - @ApiModelProperty(value = "密码", required = true, example = "123456")
  16 + @Schema(title = "密码", required = true, example = "123456")
19 17 @NotNull(message = "密码不能为空")
20 18 private String password;
21 19  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/FileConfigController.java
... ... @@ -9,9 +9,9 @@ import cn.iocoder.yudao.module.infra.controller.admin.file.vo.config.FileConfigU
9 9 import cn.iocoder.yudao.module.infra.convert.file.FileConfigConvert;
10 10 import cn.iocoder.yudao.module.infra.dal.dataobject.file.FileConfigDO;
11 11 import cn.iocoder.yudao.module.infra.service.file.FileConfigService;
12   -import io.swagger.annotations.Api;
13   -import io.swagger.annotations.ApiImplicitParam;
14   -import io.swagger.annotations.ApiOperation;
  12 +import io.swagger.v3.oas.annotations.tags.Tag;
  13 +import io.swagger.v3.oas.annotations.Parameter;
  14 +import io.swagger.v3.oas.annotations.Operation;
15 15 import org.springframework.security.access.prepost.PreAuthorize;
16 16 import org.springframework.validation.annotation.Validated;
17 17 import org.springframework.web.bind.annotation.*;
... ... @@ -21,7 +21,7 @@ import javax.validation.Valid;
21 21  
22 22 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
23 23  
24   -@Api(tags = "管理后台 - 文件配置")
  24 +@Tag(name = "管理后台 - 文件配置")
25 25 @RestController
26 26 @RequestMapping("/infra/file-config")
27 27 @Validated
... ... @@ -31,14 +31,14 @@ public class FileConfigController {
31 31 private FileConfigService fileConfigService;
32 32  
33 33 @PostMapping("/create")
34   - @ApiOperation("创建文件配置")
  34 + @Operation(summary = "创建文件配置")
35 35 @PreAuthorize("@ss.hasPermission('infra:file-config:create')")
36 36 public CommonResult<Long> createFileConfig(@Valid @RequestBody FileConfigCreateReqVO createReqVO) {
37 37 return success(fileConfigService.createFileConfig(createReqVO));
38 38 }
39 39  
40 40 @PutMapping("/update")
41   - @ApiOperation("更新文件配置")
  41 + @Operation(summary = "更新文件配置")
42 42 @PreAuthorize("@ss.hasPermission('infra:file-config:update')")
43 43 public CommonResult<Boolean> updateFileConfig(@Valid @RequestBody FileConfigUpdateReqVO updateReqVO) {
44 44 fileConfigService.updateFileConfig(updateReqVO);
... ... @@ -46,7 +46,7 @@ public class FileConfigController {
46 46 }
47 47  
48 48 @PutMapping("/update-master")
49   - @ApiOperation("更新文件配置为 Master")
  49 + @Operation(summary = "更新文件配置为 Master")
50 50 @PreAuthorize("@ss.hasPermission('infra:file-config:update')")
51 51 public CommonResult<Boolean> updateFileConfigMaster(@RequestParam("id") Long id) {
52 52 fileConfigService.updateFileConfigMaster(id);
... ... @@ -54,8 +54,8 @@ public class FileConfigController {
54 54 }
55 55  
56 56 @DeleteMapping("/delete")
57   - @ApiOperation("删除文件配置")
58   - @ApiImplicitParam(name = "id", value = "编号", required = true, dataTypeClass = Long.class)
  57 + @Operation(summary = "删除文件配置")
  58 + @Parameter(name = "id", description = "编号", required = true)
59 59 @PreAuthorize("@ss.hasPermission('infra:file-config:delete')")
60 60 public CommonResult<Boolean> deleteFileConfig(@RequestParam("id") Long id) {
61 61 fileConfigService.deleteFileConfig(id);
... ... @@ -63,8 +63,8 @@ public class FileConfigController {
63 63 }
64 64  
65 65 @GetMapping("/get")
66   - @ApiOperation("获得文件配置")
67   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  66 + @Operation(summary = "获得文件配置")
  67 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
68 68 @PreAuthorize("@ss.hasPermission('infra:file-config:query')")
69 69 public CommonResult<FileConfigRespVO> getFileConfig(@RequestParam("id") Long id) {
70 70 FileConfigDO fileConfig = fileConfigService.getFileConfig(id);
... ... @@ -72,7 +72,7 @@ public class FileConfigController {
72 72 }
73 73  
74 74 @GetMapping("/page")
75   - @ApiOperation("获得文件配置分页")
  75 + @Operation(summary = "获得文件配置分页")
76 76 @PreAuthorize("@ss.hasPermission('infra:file-config:query')")
77 77 public CommonResult<PageResult<FileConfigRespVO>> getFileConfigPage(@Valid FileConfigPageReqVO pageVO) {
78 78 PageResult<FileConfigDO> pageResult = fileConfigService.getFileConfigPage(pageVO);
... ... @@ -80,7 +80,7 @@ public class FileConfigController {
80 80 }
81 81  
82 82 @GetMapping("/test")
83   - @ApiOperation("测试文件配置是否正确")
  83 + @Operation(summary = "测试文件配置是否正确")
84 84 @PreAuthorize("@ss.hasPermission('infra:file-config:query')")
85 85 public CommonResult<String> testFileConfig(@RequestParam("id") Long id) throws Exception {
86 86 String url = fileConfigService.testFileConfig(id);
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/FileController.java
... ... @@ -12,9 +12,9 @@ import cn.iocoder.yudao.module.infra.controller.admin.file.vo.file.FileUploadReq
12 12 import cn.iocoder.yudao.module.infra.convert.file.FileConvert;
13 13 import cn.iocoder.yudao.module.infra.dal.dataobject.file.FileDO;
14 14 import cn.iocoder.yudao.module.infra.service.file.FileService;
15   -import io.swagger.annotations.Api;
16   -import io.swagger.annotations.ApiImplicitParam;
17   -import io.swagger.annotations.ApiOperation;
  15 +import io.swagger.v3.oas.annotations.tags.Tag;
  16 +import io.swagger.v3.oas.annotations.Parameter;
  17 +import io.swagger.v3.oas.annotations.Operation;
18 18 import lombok.extern.slf4j.Slf4j;
19 19 import org.springframework.http.HttpStatus;
20 20 import org.springframework.security.access.prepost.PreAuthorize;
... ... @@ -30,7 +30,7 @@ import javax.validation.Valid;
30 30  
31 31 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
32 32  
33   -@Api(tags = "管理后台 - 文件存储")
  33 +@Tag(name = "管理后台 - 文件存储")
34 34 @RestController
35 35 @RequestMapping("/infra/file")
36 36 @Validated
... ... @@ -41,7 +41,7 @@ public class FileController {
41 41 private FileService fileService;
42 42  
43 43 @PostMapping("/upload")
44   - @ApiOperation("上传文件")
  44 + @Operation(summary = "上传文件")
45 45 @OperateLog(logArgs = false) // 上传文件,没有记录操作日志的必要
46 46 public CommonResult<String> uploadFile(FileUploadReqVO uploadReqVO) throws Exception {
47 47 MultipartFile file = uploadReqVO.getFile();
... ... @@ -50,8 +50,8 @@ public class FileController {
50 50 }
51 51  
52 52 @DeleteMapping("/delete")
53   - @ApiOperation("删除文件")
54   - @ApiImplicitParam(name = "id", value = "编号", required = true, dataTypeClass = Long.class)
  53 + @Operation(summary = "删除文件")
  54 + @Parameter(name = "id", description = "编号", required = true)
55 55 @PreAuthorize("@ss.hasPermission('infra:file:delete')")
56 56 public CommonResult<Boolean> deleteFile(@RequestParam("id") Long id) throws Exception {
57 57 fileService.deleteFile(id);
... ... @@ -60,8 +60,8 @@ public class FileController {
60 60  
61 61 @GetMapping("/{configId}/get/**")
62 62 @PermitAll
63   - @ApiOperation("下载文件")
64   - @ApiImplicitParam(name = "configId", value = "配置编号", required = true, dataTypeClass = Long.class)
  63 + @Operation(summary = "下载文件")
  64 + @Parameter(name = "configId", description = "配置编号", required = true)
65 65 public void getFileContent(HttpServletRequest request,
66 66 HttpServletResponse response,
67 67 @PathVariable("configId") Long configId) throws Exception {
... ... @@ -82,7 +82,7 @@ public class FileController {
82 82 }
83 83  
84 84 @GetMapping("/page")
85   - @ApiOperation("获得文件分页")
  85 + @Operation(summary = "获得文件分页")
86 86 @PreAuthorize("@ss.hasPermission('infra:file:query')")
87 87 public CommonResult<PageResult<FileRespVO>> getFilePage(@Valid FilePageReqVO pageVO) {
88 88 PageResult<FileDO> pageResult = fileService.getFilePage(pageVO);
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/config/FileConfigBaseVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.config;
2   -
3   -import io.swagger.annotations.ApiModelProperty;
  2 +import io.swagger.v3.oas.annotations.media.Schema;
4 3 import lombok.Data;
5 4  
6 5 import javax.validation.constraints.NotNull;
... ... @@ -12,11 +11,11 @@ import javax.validation.constraints.NotNull;
12 11 @Data
13 12 public class FileConfigBaseVO {
14 13  
15   - @ApiModelProperty(value = "配置名", required = true, example = "S3 - 阿里云")
  14 + @Schema(title = "配置名", required = true, example = "S3 - 阿里云")
16 15 @NotNull(message = "配置名不能为空")
17 16 private String name;
18 17  
19   - @ApiModelProperty(value = "备注", example = "我是备注")
  18 + @Schema(title = "备注", example = "我是备注")
20 19 private String remark;
21 20  
22 21 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/config/FileConfigCreateReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.config;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
... ... @@ -9,17 +8,17 @@ import lombok.ToString;
9 8 import javax.validation.constraints.NotNull;
10 9 import java.util.Map;
11 10  
12   -@ApiModel("管理后台 - 文件配置创建 Request VO")
  11 +@Schema(title = "管理后台 - 文件配置创建 Request VO")
13 12 @Data
14 13 @EqualsAndHashCode(callSuper = true)
15 14 @ToString(callSuper = true)
16 15 public class FileConfigCreateReqVO extends FileConfigBaseVO {
17 16  
18   - @ApiModelProperty(value = "存储器", required = true, example = "1", notes = "参见 FileStorageEnum 枚举类")
  17 + @Schema(title = "存储器", required = true, example = "1", description = "参见 FileStorageEnum 枚举类")
19 18 @NotNull(message = "存储器不能为空")
20 19 private Integer storage;
21 20  
22   - @ApiModelProperty(value = "存储配置", required = true, notes = "配置是动态参数,所以使用 Map 接收")
  21 + @Schema(title = "存储配置", required = true, description = "配置是动态参数,所以使用 Map 接收")
23 22 @NotNull(message = "存储配置不能为空")
24 23 private Map<String, Object> config;
25 24  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/config/FileConfigPageReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.config;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,20 +11,20 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 文件配置分页 Request VO")
  14 +@Schema(title = "管理后台 - 文件配置分页 Request VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class FileConfigPageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "配置名", example = "S3 - 阿里云")
  20 + @Schema(title = "配置名", example = "S3 - 阿里云")
22 21 private String name;
23 22  
24   - @ApiModelProperty(value = "存储器", example = "1")
  23 + @Schema(title = "存储器", example = "1")
25 24 private Integer storage;
26 25  
27 26 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
28   - @ApiModelProperty(value = "创建时间")
  27 + @Schema(title = "创建时间")
29 28 private LocalDateTime[] createTime;
30 29  
31 30 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/config/FileConfigRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.config;
2 2  
3 3 import cn.iocoder.yudao.framework.file.core.client.FileClientConfig;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -10,27 +9,27 @@ import lombok.ToString;
10 9 import javax.validation.constraints.NotNull;
11 10 import java.time.LocalDateTime;
12 11  
13   -@ApiModel("管理后台 - 文件配置 Response VO")
  12 +@Schema(title = "管理后台 - 文件配置 Response VO")
14 13 @Data
15 14 @EqualsAndHashCode(callSuper = true)
16 15 @ToString(callSuper = true)
17 16 public class FileConfigRespVO extends FileConfigBaseVO {
18 17  
19   - @ApiModelProperty(value = "编号", required = true, example = "1")
  18 + @Schema(title = "编号", required = true, example = "1")
20 19 private Long id;
21 20  
22   - @ApiModelProperty(value = "存储器", required = true, example = "1", notes = "参见 FileStorageEnum 枚举类")
  21 + @Schema(title = "存储器", required = true, example = "1", description = "参见 FileStorageEnum 枚举类")
23 22 @NotNull(message = "存储器不能为空")
24 23 private Integer storage;
25 24  
26   - @ApiModelProperty(value = "是否为主配置", required = true, example = "true")
  25 + @Schema(title = "是否为主配置", required = true, example = "true")
27 26 @NotNull(message = "是否为主配置不能为空")
28 27 private Boolean master;
29 28  
30   - @ApiModelProperty(value = "存储配置", required = true)
  29 + @Schema(title = "存储配置", required = true)
31 30 private FileClientConfig config;
32 31  
33   - @ApiModelProperty(value = "创建时间", required = true)
  32 + @Schema(title = "创建时间", required = true)
34 33 private LocalDateTime createTime;
35 34  
36 35 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/config/FileConfigUpdateReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.config;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import lombok.EqualsAndHashCode;
7 6 import lombok.ToString;
... ... @@ -9,17 +8,17 @@ import lombok.ToString;
9 8 import javax.validation.constraints.NotNull;
10 9 import java.util.Map;
11 10  
12   -@ApiModel("管理后台 - 文件配置更新 Request VO")
  11 +@Schema(title = "管理后台 - 文件配置更新 Request VO")
13 12 @Data
14 13 @EqualsAndHashCode(callSuper = true)
15 14 @ToString(callSuper = true)
16 15 public class FileConfigUpdateReqVO extends FileConfigBaseVO {
17 16  
18   - @ApiModelProperty(value = "编号", required = true, example = "1")
  17 + @Schema(title = "编号", required = true, example = "1")
19 18 @NotNull(message = "编号不能为空")
20 19 private Long id;
21 20  
22   - @ApiModelProperty(value = "存储配置", required = true, notes = "配置是动态参数,所以使用 Map 接收")
  21 + @Schema(title = "存储配置", required = true, description = "配置是动态参数,所以使用 Map 接收")
23 22 @NotNull(message = "存储配置不能为空")
24 23 private Map<String, Object> config;
25 24  
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/file/FilePageReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.file;
2 2  
3 3 import cn.iocoder.yudao.framework.common.pojo.PageParam;
4   -import io.swagger.annotations.ApiModel;
5   -import io.swagger.annotations.ApiModelProperty;
  4 +import io.swagger.v3.oas.annotations.media.Schema;
6 5 import lombok.Data;
7 6 import lombok.EqualsAndHashCode;
8 7 import lombok.ToString;
... ... @@ -12,20 +11,20 @@ import java.time.LocalDateTime;
12 11  
13 12 import static cn.iocoder.yudao.framework.common.util.date.DateUtils.FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND;
14 13  
15   -@ApiModel("管理后台 - 文件分页 Request VO")
  14 +@Schema(title = "管理后台 - 文件分页 Request VO")
16 15 @Data
17 16 @EqualsAndHashCode(callSuper = true)
18 17 @ToString(callSuper = true)
19 18 public class FilePageReqVO extends PageParam {
20 19  
21   - @ApiModelProperty(value = "文件路径", example = "yudao", notes = "模糊匹配")
  20 + @Schema(title = "文件路径", example = "yudao", description = "模糊匹配")
22 21 private String path;
23 22  
24   - @ApiModelProperty(value = "文件类型", example = "application/octet-stream", notes = "模糊匹配")
  23 + @Schema(title = "文件类型", example = "application/octet-stream", description = "模糊匹配")
25 24 private String type;
26 25  
27 26 @DateTimeFormat(pattern = FORMAT_YEAR_MONTH_DAY_HOUR_MINUTE_SECOND)
28   - @ApiModelProperty(value = "创建时间")
  27 + @Schema(title = "创建时间")
29 28 private LocalDateTime[] createTime;
30 29  
31 30 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/file/FileRespVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.file;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5  
7 6 import java.time.LocalDateTime;
8 7  
9   -@ApiModel(value = "管理后台 - 文件 Response VO", description = "不返回 content 字段,太大")
  8 +@Schema(title = "管理后台 - 文件 Response VO", description = "不返回 content 字段,太大")
10 9 @Data
11 10 public class FileRespVO {
12 11  
13   - @ApiModelProperty(value = "文件编号", required = true, example = "1024")
  12 + @Schema(title = "文件编号", required = true, example = "1024")
14 13 private Long id;
15 14  
16   - @ApiModelProperty(value = "配置编号", required = true, example = "11")
  15 + @Schema(title = "配置编号", required = true, example = "11")
17 16 private Long configId;
18 17  
19   - @ApiModelProperty(value = "文件路径", required = true, example = "yudao.jpg")
  18 + @Schema(title = "文件路径", required = true, example = "yudao.jpg")
20 19 private String path;
21 20  
22   - @ApiModelProperty(value = "原文件名", required = true, example = "yudao.jpg")
  21 + @Schema(title = "原文件名", required = true, example = "yudao.jpg")
23 22 private String name;
24 23  
25   - @ApiModelProperty(value = "文件 URL", required = true, example = "https://www.iocoder.cn/yudao.jpg")
  24 + @Schema(title = "文件 URL", required = true, example = "https://www.iocoder.cn/yudao.jpg")
26 25 private String url;
27 26  
28   - @ApiModelProperty(value = "文件MIME类型", example = "application/octet-stream")
  27 + @Schema(title = "文件MIME类型", example = "application/octet-stream")
29 28 private String type;
30 29  
31   - @ApiModelProperty(value = "文件大小", example = "2048", required = true)
  30 + @Schema(title = "文件大小", example = "2048", required = true)
32 31 private Integer size;
33 32  
34   - @ApiModelProperty(value = "创建时间", required = true)
  33 + @Schema(title = "创建时间", required = true)
35 34 private LocalDateTime createTime;
36 35  
37 36 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/file/vo/file/FileUploadReqVO.java
1 1 package cn.iocoder.yudao.module.infra.controller.admin.file.vo.file;
2 2  
3   -import io.swagger.annotations.ApiModel;
4   -import io.swagger.annotations.ApiModelProperty;
  3 +import io.swagger.v3.oas.annotations.media.Schema;
5 4 import lombok.Data;
6 5 import org.springframework.web.multipart.MultipartFile;
7 6  
8 7 import javax.validation.constraints.NotNull;
9 8  
10   -@ApiModel(value = "管理后台 - 上传文件 Request VO")
  9 +@Schema(title = "管理后台 - 上传文件 Request VO")
11 10 @Data
12 11 public class FileUploadReqVO {
13 12  
14   - @ApiModelProperty(value = "文件附件", required = true)
  13 + @Schema(title = "文件附件", required = true)
15 14 @NotNull(message = "文件附件不能为空")
16 15 private MultipartFile file;
17 16  
18   - @ApiModelProperty(value = "文件附件", example = "yudaoyuanma.png")
  17 + @Schema(title = "文件附件", example = "yudaoyuanma.png")
19 18 private String path;
20 19  
21 20 }
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobController.java
... ... @@ -9,10 +9,10 @@ import cn.iocoder.yudao.module.infra.controller.admin.job.vo.job.*;
9 9 import cn.iocoder.yudao.module.infra.convert.job.JobConvert;
10 10 import cn.iocoder.yudao.module.infra.dal.dataobject.job.JobDO;
11 11 import cn.iocoder.yudao.module.infra.service.job.JobService;
12   -import io.swagger.annotations.Api;
13   -import io.swagger.annotations.ApiImplicitParam;
14   -import io.swagger.annotations.ApiImplicitParams;
15   -import io.swagger.annotations.ApiOperation;
  12 +import io.swagger.v3.oas.annotations.tags.Tag;
  13 +import io.swagger.v3.oas.annotations.Parameter;
  14 +import io.swagger.v3.oas.annotations.Parameters;
  15 +import io.swagger.v3.oas.annotations.Operation;
16 16 import org.quartz.SchedulerException;
17 17 import org.springframework.security.access.prepost.PreAuthorize;
18 18 import org.springframework.validation.annotation.Validated;
... ... @@ -30,7 +30,7 @@ import java.util.List;
30 30 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
31 31 import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT;
32 32  
33   -@Api(tags = "管理后台 - 定时任务")
  33 +@Tag(name = "管理后台 - 定时任务")
34 34 @RestController
35 35 @RequestMapping("/infra/job")
36 36 @Validated
... ... @@ -40,7 +40,7 @@ public class JobController {
40 40 private JobService jobService;
41 41  
42 42 @PostMapping("/create")
43   - @ApiOperation("创建定时任务")
  43 + @Operation(summary = "创建定时任务")
44 44 @PreAuthorize("@ss.hasPermission('infra:job:create')")
45 45 public CommonResult<Long> createJob(@Valid @RequestBody JobCreateReqVO createReqVO)
46 46 throws SchedulerException {
... ... @@ -48,7 +48,7 @@ public class JobController {
48 48 }
49 49  
50 50 @PutMapping("/update")
51   - @ApiOperation("更新定时任务")
  51 + @Operation(summary = "更新定时任务")
52 52 @PreAuthorize("@ss.hasPermission('infra:job:update')")
53 53 public CommonResult<Boolean> updateJob(@Valid @RequestBody JobUpdateReqVO updateReqVO)
54 54 throws SchedulerException {
... ... @@ -57,10 +57,10 @@ public class JobController {
57 57 }
58 58  
59 59 @PutMapping("/update-status")
60   - @ApiOperation("更新定时任务的状态")
61   - @ApiImplicitParams({
62   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class),
63   - @ApiImplicitParam(name = "status", value = "状态", required = true, example = "1", dataTypeClass = Integer.class),
  60 + @Operation(summary = "更新定时任务的状态")
  61 + @Parameters({
  62 + @Parameter(name = "id", description = "编号", required = true, example = "1024"),
  63 + @Parameter(name = "status", description = "状态", required = true, example = "1"),
64 64 })
65 65 @PreAuthorize("@ss.hasPermission('infra:job:update')")
66 66 public CommonResult<Boolean> updateJobStatus(@RequestParam(value = "id") Long id, @RequestParam("status") Integer status)
... ... @@ -70,8 +70,8 @@ public class JobController {
70 70 }
71 71  
72 72 @DeleteMapping("/delete")
73   - @ApiOperation("删除定时任务")
74   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  73 + @Operation(summary = "删除定时任务")
  74 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
75 75 @PreAuthorize("@ss.hasPermission('infra:job:delete')")
76 76 public CommonResult<Boolean> deleteJob(@RequestParam("id") Long id)
77 77 throws SchedulerException {
... ... @@ -80,8 +80,8 @@ public class JobController {
80 80 }
81 81  
82 82 @PutMapping("/trigger")
83   - @ApiOperation("触发定时任务")
84   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  83 + @Operation(summary = "触发定时任务")
  84 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
85 85 @PreAuthorize("@ss.hasPermission('infra:job:trigger')")
86 86 public CommonResult<Boolean> triggerJob(@RequestParam("id") Long id) throws SchedulerException {
87 87 jobService.triggerJob(id);
... ... @@ -89,8 +89,8 @@ public class JobController {
89 89 }
90 90  
91 91 @GetMapping("/get")
92   - @ApiOperation("获得定时任务")
93   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  92 + @Operation(summary = "获得定时任务")
  93 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
94 94 @PreAuthorize("@ss.hasPermission('infra:job:query')")
95 95 public CommonResult<JobRespVO> getJob(@RequestParam("id") Long id) {
96 96 JobDO job = jobService.getJob(id);
... ... @@ -98,8 +98,8 @@ public class JobController {
98 98 }
99 99  
100 100 @GetMapping("/list")
101   - @ApiOperation("获得定时任务列表")
102   - @ApiImplicitParam(name = "ids", value = "编号列表", required = true, dataTypeClass = List.class)
  101 + @Operation(summary = "获得定时任务列表")
  102 + @Parameter(name = "ids", description = "编号列表", required = true)
103 103 @PreAuthorize("@ss.hasPermission('infra:job:query')")
104 104 public CommonResult<List<JobRespVO>> getJobList(@RequestParam("ids") Collection<Long> ids) {
105 105 List<JobDO> list = jobService.getJobList(ids);
... ... @@ -107,7 +107,7 @@ public class JobController {
107 107 }
108 108  
109 109 @GetMapping("/page")
110   - @ApiOperation("获得定时任务分页")
  110 + @Operation(summary = "获得定时任务分页")
111 111 @PreAuthorize("@ss.hasPermission('infra:job:query')")
112 112 public CommonResult<PageResult<JobRespVO>> getJobPage(@Valid JobPageReqVO pageVO) {
113 113 PageResult<JobDO> pageResult = jobService.getJobPage(pageVO);
... ... @@ -115,7 +115,7 @@ public class JobController {
115 115 }
116 116  
117 117 @GetMapping("/export-excel")
118   - @ApiOperation("导出定时任务 Excel")
  118 + @Operation(summary = "导出定时任务 Excel")
119 119 @PreAuthorize("@ss.hasPermission('infra:job:export')")
120 120 @OperateLog(type = EXPORT)
121 121 public void exportJobExcel(@Valid JobExportReqVO exportReqVO,
... ... @@ -127,10 +127,10 @@ public class JobController {
127 127 }
128 128  
129 129 @GetMapping("/get_next_times")
130   - @ApiOperation("获得定时任务的下 n 次执行时间")
131   - @ApiImplicitParams({
132   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class),
133   - @ApiImplicitParam(name = "count", value = "数量", example = "5", dataTypeClass = Long.class)
  130 + @Operation(summary = "获得定时任务的下 n 次执行时间")
  131 + @Parameters({
  132 + @Parameter(name = "id", description = "编号", required = true, example = "1024"),
  133 + @Parameter(name = "count", description = "数量", example = "5")
134 134 })
135 135 @PreAuthorize("@ss.hasPermission('infra:job:query')")
136 136 public CommonResult<List<LocalDateTime>> getJobNextTimes(@RequestParam("id") Long id,
... ...
yudao-module-infra/yudao-module-infra-biz/src/main/java/cn/iocoder/yudao/module/infra/controller/admin/job/JobLogController.java
... ... @@ -11,9 +11,9 @@ import cn.iocoder.yudao.module.infra.controller.admin.job.vo.log.JobLogRespVO;
11 11 import cn.iocoder.yudao.module.infra.convert.job.JobLogConvert;
12 12 import cn.iocoder.yudao.module.infra.dal.dataobject.job.JobLogDO;
13 13 import cn.iocoder.yudao.module.infra.service.job.JobLogService;
14   -import io.swagger.annotations.Api;
15   -import io.swagger.annotations.ApiImplicitParam;
16   -import io.swagger.annotations.ApiOperation;
  14 +import io.swagger.v3.oas.annotations.tags.Tag;
  15 +import io.swagger.v3.oas.annotations.Parameter;
  16 +import io.swagger.v3.oas.annotations.Operation;
17 17 import org.springframework.security.access.prepost.PreAuthorize;
18 18 import org.springframework.validation.annotation.Validated;
19 19 import org.springframework.web.bind.annotation.GetMapping;
... ... @@ -31,7 +31,7 @@ import java.util.List;
31 31 import static cn.iocoder.yudao.framework.common.pojo.CommonResult.success;
32 32 import static cn.iocoder.yudao.framework.operatelog.core.enums.OperateTypeEnum.EXPORT;
33 33  
34   -@Api(tags = "管理后台 - 定时任务日志")
  34 +@Tag(name = "管理后台 - 定时任务日志")
35 35 @RestController
36 36 @RequestMapping("/infra/job-log")
37 37 @Validated
... ... @@ -41,8 +41,8 @@ public class JobLogController {
41 41 private JobLogService jobLogService;
42 42  
43 43 @GetMapping("/get")
44   - @ApiOperation("获得定时任务日志")
45   - @ApiImplicitParam(name = "id", value = "编号", required = true, example = "1024", dataTypeClass = Long.class)
  44 + @Operation(summary = "获得定时任务日志")
  45 + @Parameter(name = "id", description = "编号", required = true, example = "1024")
46 46 @PreAuthorize("@ss.hasPermission('infra:job:query')")
47 47 public CommonResult<JobLogRespVO> getJobLog(@RequestParam("id") Long id) {
48 48 JobLogDO jobLog = jobLogService.getJobLog(id);
... ... @@ -50,8 +50,8 @@ public class JobLogController {
50 50 }
51 51  
52 52 @GetMapping("/list")
53   - @ApiOperation("获得定时任务日志列表")
54   - @ApiImplicitParam(name = "ids", value = "编号列表", required = true, example = "1024,2048", dataTypeClass = List.class)
  53 + @Operation(summary = "获得定时任务日志列表")
  54 + @Parameter(name = "ids", description = "编号列表", required = true, example = "1024,2048")
55 55 @PreAuthorize("@ss.hasPermission('infra:job:query')")
56 56 public CommonResult<List<JobLogRespVO>> getJobLogList(@RequestParam("ids") Collection<Long> ids) {
57 57 List<JobLogDO> list = jobLogService.getJobLogList(ids);
... ... @@ -59,7 +59,7 @@ public class JobLogController {
59 59 }
60 60  
61 61 @GetMapping("/page")
62   - @ApiOperation("获得定时任务日志分页")
  62 + @Operation(summary = "获得定时任务日志分页")
63 63 @PreAuthorize("@ss.hasPermission('infra:job:query')")
64 64 public CommonResult<PageResult<JobLogRespVO>> getJobLogPage(@Valid JobLogPageReqVO pageVO) {
65 65 PageResult<JobLogDO> pageResult = jobLogService.getJobLogPage(pageVO);
... ... @@ -67,7 +67,7 @@ public class JobLogController {
67 67 }
68 68  
69 69 @GetMapping("/export-excel")
70   - @ApiOperation("导出定时任务日志 Excel")
  70 + @Operation(summary = "导出定时任务日志 Excel")
71 71 @PreAuthorize("@ss.hasPermission('infra:job:export')")
72 72 @OperateLog(type = EXPORT)
73 73 public void exportJobLogExcel(@Valid JobLogExportReqVO exportReqVO,
... ...