use of org.codelibs.fess.app.pager.GroupPager in project fess by codelibs.
the class ApiAdminGroupAction method settings.
// GET /api/admin/group
// POST /api/admin/group
@Execute
public JsonResponse<ApiResult> settings(final SearchBody body) {
validateApi(body, messages -> {
});
final GroupPager pager = copyBeanToNewBean(body, GroupPager.class);
final List<Group> list = groupService.getGroupList(pager);
return asJson(new ApiResult.ApiConfigsResponse<EditBody>().settings(list.stream().map(entity -> createEditBody(entity)).collect(Collectors.toList())).total(pager.getAllRecordCount()).status(ApiResult.Status.OK).result());
}
Aggregations