Browse Source

修改配置:shiro请求拦截、swagger文档生成

master
Augcl 11 months ago
parent
commit
ba32094734
2 changed files with 6 additions and 6 deletions
  1. +1
    -1
      jeecg-boot-base-core/src/main/java/org/jeecg/config/Swagger2Config.java
  2. +5
    -5
      jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java

+ 1
- 1
jeecg-boot-base-core/src/main/java/org/jeecg/config/Swagger2Config.java View File

@ -68,7 +68,7 @@ public class Swagger2Config implements WebMvcConfigurer {
.apiInfo(apiInfo())
.select()
//此包路径下的类才生成接口文档
.apis(RequestHandlerSelectors.basePackage("org.jeecg.modules.demo.officialWebsite"))
.apis(RequestHandlerSelectors.basePackage("org.jeecg.modules.demo.officialWebsite.api"))
//加了ApiOperation注解的类才生成接口文档
.apis(RequestHandlerSelectors.withClassAnnotation(RestController.class))
.apis(RequestHandlerSelectors.withMethodAnnotation(ApiOperation.class))


+ 5
- 5
jeecg-boot-base-core/src/main/java/org/jeecg/config/shiro/ShiroConfig.java View File

@ -76,12 +76,12 @@ public class ShiroConfig {
}
}
// 配置不会被拦截的链接 顺序判断
filterChainDefinitionMap.put("/demo/**", "anon"); //测试增删改查
filterChainDefinitionMap.put("/owClassification/**", "anon"); //officialWebsite-owClassification
filterChainDefinitionMap.put("/owImage/**", "anon"); //officialWebsite-owImage
filterChainDefinitionMap.put("/owProduct/**", "anon"); //officialWebsite-owProduct
filterChainDefinitionMap.put("/owParam/**", "anon"); //officialWebsite-owParam
//officialWebsite
filterChainDefinitionMap.put("/apiOwClassification/**", "anon"); //officialWebsite-owClassification
filterChainDefinitionMap.put("/apiOwImage/**", "anon"); //officialWebsite-owImage
filterChainDefinitionMap.put("/apiOwProduct/**", "anon"); //officialWebsite-owProduct
filterChainDefinitionMap.put("/apiOwParam/**", "anon"); //officialWebsite-owParam
filterChainDefinitionMap.put("/sys/cas/client/validateLogin", "anon"); //cas验证登录
filterChainDefinitionMap.put("/sys/randomImage/**", "anon"); //登录验证码接口排除


Loading…
Cancel
Save