|
|
@@ -111,12 +111,12 @@ public class UserController extends BaseController {
|
|
|
authorities.add(Authority.get(AuthorityName.ROLE_SUPERVISOR));
|
|
|
authorities.add(Authority.get(AuthorityName.ROLE_USER));
|
|
|
authorities.add(Authority.get(AuthorityName.ROLE_DISTRICT_STAFF));
|
|
|
- return userService.all2(pageQuery, authorities);
|
|
|
+ return userService.byAuthority(pageQuery, authorities);
|
|
|
}
|
|
|
|
|
|
@PostMapping("/all1")
|
|
|
public Page<ExpertDTO> all1(@RequestBody PageQuery pageQuery) {
|
|
|
- return userService.all1(pageQuery, Collections.singletonList(Authority.get(AuthorityName.ROLE_EXPERT)));
|
|
|
+ return userService.toArtType(pageQuery, Collections.singletonList(Authority.get(AuthorityName.ROLE_EXPERT)));
|
|
|
}
|
|
|
|
|
|
@PostMapping("/expert")
|
|
|
@@ -124,7 +124,7 @@ public class UserController extends BaseController {
|
|
|
List<Authority> authorities = new ArrayList<>();
|
|
|
authorities.add(Authority.get(AuthorityName.ROLE_DISTRICT_STAFF));
|
|
|
authorities.add(Authority.get(AuthorityName.ROLE_EXPERT));
|
|
|
- return userService.all1(pageQuery, authorities);
|
|
|
+ return userService.toArtType(pageQuery, authorities);
|
|
|
}
|
|
|
|
|
|
@PreAuthorize("hasRole('ADMIN')")
|