错误 SpringSecurity使用@PreAuthorize进行角色校验无效 解决方法 在类上加上注解@EnableGlobalMethodSecurity(prePostEnabled = true)。