修复进销存合并
This commit is contained in:
+32
-3
@@ -49,6 +49,7 @@ public class YudaoSwaggerAutoConfiguration {
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
// 用来创建该 API 的基本信息,展示在文档的页面中(自定义展示的信息)
|
||||
.apiInfo(apiInfo(properties))
|
||||
.groupName("管理系统")
|
||||
// 设置扫描指定 package 包下的
|
||||
.select()
|
||||
.apis(basePackage(properties.getBasePackage()))
|
||||
@@ -75,7 +76,7 @@ public class YudaoSwaggerAutoConfiguration {
|
||||
.build();
|
||||
pars.add(ticketPar.build());
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
.groupName("ADMIN")
|
||||
.groupName("商城后台")
|
||||
.enable(true)
|
||||
.apiInfo(apiInfo(properties))
|
||||
.select()
|
||||
@@ -103,7 +104,7 @@ public class YudaoSwaggerAutoConfiguration {
|
||||
.build();
|
||||
pars.add(ticketPar.build());
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
.groupName("APP")
|
||||
.groupName("商城前台")
|
||||
.enable(true)
|
||||
.apiInfo(apiInfo(properties))
|
||||
.select()
|
||||
@@ -132,7 +133,7 @@ public class YudaoSwaggerAutoConfiguration {
|
||||
.build();
|
||||
pars.add(ticketPar.build());
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
.groupName("TOOL")
|
||||
.groupName("电商工具")
|
||||
.enable(true)
|
||||
.apiInfo(apiInfo(properties))
|
||||
.select()
|
||||
@@ -146,6 +147,34 @@ public class YudaoSwaggerAutoConfiguration {
|
||||
.securityContexts(securityContexts());
|
||||
}
|
||||
|
||||
@Bean("ERP")
|
||||
@SuppressWarnings("all")
|
||||
public Docket createErpApi() {
|
||||
SwaggerProperties properties = swaggerProperties();
|
||||
ParameterBuilder ticketPar = new ParameterBuilder();
|
||||
List<Parameter> pars = new ArrayList<>();
|
||||
ticketPar.name("token").description("token")
|
||||
.modelRef(new ModelRef("string"))
|
||||
.parameterType("header")
|
||||
.defaultValue("token" + " ")
|
||||
.required(true)
|
||||
.build();
|
||||
pars.add(ticketPar.build());
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
.groupName("进销存")
|
||||
.enable(true)
|
||||
.apiInfo(apiInfo(properties))
|
||||
.select()
|
||||
.apis(RequestHandlerSelectors.basePackage("com.zsw.erp"))
|
||||
.paths(PathSelectors.regex("/error.*").negate())
|
||||
.build()
|
||||
.globalOperationParameters(pars)
|
||||
//添加登陆认证
|
||||
.securitySchemes(securitySchemes())
|
||||
.globalRequestParameters(globalRequestParameters())
|
||||
.securityContexts(securityContexts());
|
||||
}
|
||||
|
||||
// ========== apiInfo ==========
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user