Commit f37b588d authored by fangxinjiang's avatar fangxinjiang

获取用户信息接口隐藏

parent 5c99910e
......@@ -65,7 +65,7 @@ public class YifuResourceServerConfigurerAdapter extends ResourceServerConfigure
permitAllUrl.getUrls().forEach(url -> registry.antMatchers(url).permitAll());
// “/user/getInfoByUsername" URL 访问放行
registry.and()
.authorizeRequests().antMatchers("/user/getInfoByUsername","/api/**","/api-docs/**").permitAll()
.authorizeRequests().antMatchers("/api/**","/api-docs/**").permitAll()
.anyRequest().authenticated().and().csrf().disable();
}
......
......@@ -101,7 +101,7 @@ public class UserController {
}
return R.ok(userService.getUserInfo(user));
}
@Inner
@GetMapping("/getInfoByUsername")
public UserInfo infoAPI(@RequestParam(required = true, name = "username") String username) {
SysUser user = userService.getOne(Wrappers.<SysUser>query().lambda().eq(SysUser::getUsername, username));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment