新增web过滤
This commit is contained in:
parent
78c32e0621
commit
017c320843
@ -141,6 +141,22 @@ public class SwaggerConfig {
|
||||
.build();
|
||||
}
|
||||
|
||||
@Bean
|
||||
public Docket createRestApiWeb() {
|
||||
List<ResponseMessage> responseMessageList = responseMessageList();
|
||||
return new Docket(DocumentationType.SWAGGER_2)
|
||||
.globalResponseMessage(RequestMethod.POST, responseMessageList)
|
||||
.globalResponseMessage(RequestMethod.DELETE, responseMessageList)
|
||||
.globalResponseMessage(RequestMethod.PUT, responseMessageList)
|
||||
.globalResponseMessage(RequestMethod.GET, responseMessageList)
|
||||
.groupName(ISystemConstant.API_GROUP_WEB)
|
||||
.apiInfo(apiInfo())
|
||||
.select()
|
||||
.apis(RequestHandlerSelectors.basePackage(swaggerBasePackage))
|
||||
.paths(PathSelectors.ant("/web/**"))
|
||||
.build();
|
||||
}
|
||||
|
||||
private ApiInfo apiInfo() {
|
||||
return new ApiInfoBuilder()
|
||||
.title(swaggerTitle)
|
||||
|
@ -32,6 +32,10 @@ public interface ISystemConstant {
|
||||
* 微信接口前缀
|
||||
*/
|
||||
String API_TAGS_WECHAT_PREFIX = "微信接口-";
|
||||
/**
|
||||
* 网页接口
|
||||
*/
|
||||
String API_TAGS_WEB_PREFIX = "网页接口-";
|
||||
/**
|
||||
* 系统接口分组
|
||||
*/
|
||||
@ -52,10 +56,18 @@ public interface ISystemConstant {
|
||||
* 微信接口分组
|
||||
*/
|
||||
String API_GROUP_WECHAT = "WECHAT";
|
||||
/**
|
||||
* 网页接口分组
|
||||
*/
|
||||
String API_GROUP_WEB = "WEB";
|
||||
/**
|
||||
* api前缀
|
||||
*/
|
||||
String API_PREFIX = "/api";
|
||||
/**
|
||||
* 网页前缀
|
||||
*/
|
||||
String API_WEB_PREFIX = "/web";
|
||||
/**
|
||||
* 路由前缀
|
||||
*/
|
||||
|
Loading…
Reference in New Issue
Block a user