fix: 修改请求接口的swagger注解

This commit is contained in:
weihongyang
2022-06-21 13:39:20 +08:00
parent 266ce0c6a7
commit 2902a959f3
10 changed files with 47 additions and 43 deletions

View File

@@ -48,7 +48,10 @@ public class SecurityConfig extends WebSecurityConfigurerAdapter {
.and()
.authorizeRequests()
// 对于登录接口 允许匿名访问
.antMatchers("/login").anonymous()
.antMatchers("/login","/swagger/**","/v2/api-docs",
"/doc.html",
"/swagger-resources/**",
"/swagger-ui/**").anonymous()
// .antMatchers("/testCors").hasAuthority("system:dept:list222")
// 除上面外的所有请求全部需要鉴权认证
.anyRequest().authenticated();