generator-jhipster@6.8.0,整体版
在UserResource中,我尝试过:
@PostMapping("/users")
// @PreAuthorize("hasAuthority(\"" + AuthoritiesConstants.ADMIN + "\")")
// @Secured({ AuthoritiesConstants.ADMIN })
public ResponseEntity<User> createUser(@Valid @RequestBody UserDTO userDTO) throws URISyntaxException {
log.debug("REST request to save User : {}", userDTO);
有帮助吗?