|
@@ -29,9 +29,12 @@ import java.net.InetAddress;
|
|
|
@Import(BeanValidatorPluginsConfiguration.class)
|
|
|
public class Knife4jConfig implements ApplicationListener<WebServerInitializedEvent> {
|
|
|
|
|
|
+ private boolean isOpen = false;
|
|
|
+
|
|
|
@Bean(value = "videoMonitor")
|
|
|
public Docket videoMonitor() {
|
|
|
return new Docket(DocumentationType.SWAGGER_2)
|
|
|
+ .enable(isOpen)
|
|
|
.useDefaultResponseMessages(false)
|
|
|
.apiInfo(apiInfo())
|
|
|
.groupName("视频监控大屏")
|
|
@@ -45,6 +48,7 @@ public class Knife4jConfig implements ApplicationListener<WebServerInitializedEv
|
|
|
@Bean(value = "yardSystem")
|
|
|
public Docket yardSystem() {
|
|
|
return new Docket(DocumentationType.SWAGGER_2)
|
|
|
+ .enable(isOpen)
|
|
|
.apiInfo(apiInfo())
|
|
|
.groupName("车场系统大屏")
|
|
|
.select()
|
|
@@ -56,6 +60,7 @@ public class Knife4jConfig implements ApplicationListener<WebServerInitializedEv
|
|
|
@Bean(value = "ebaSystem")
|
|
|
public Docket ebaSystem() {
|
|
|
return new Docket(DocumentationType.SWAGGER_2)
|
|
|
+ .enable(isOpen)
|
|
|
.apiInfo(apiInfo())
|
|
|
.groupName("EBA系统大屏")
|
|
|
.select()
|
|
@@ -67,6 +72,7 @@ public class Knife4jConfig implements ApplicationListener<WebServerInitializedEv
|
|
|
@Bean(value = "energyPlatform")
|
|
|
public Docket energyPlatform() {
|
|
|
return new Docket(DocumentationType.SWAGGER_2)
|
|
|
+ .enable(isOpen)
|
|
|
.apiInfo(apiInfo())
|
|
|
.groupName("能耗平台大屏")
|
|
|
.select()
|