in service/src/main/java/org/apache/fineract/cn/office/rest/controller/OfficeRestController.java [341:351]
ResponseEntity<EmployeePage> fetchEmployees(@RequestParam(value = "term", required = false) final String term,
@RequestParam(value = "office", required = false) final String officeIdentifier,
@RequestParam(value = "pageIndex", required = false) final Integer pageIndex,
@RequestParam(value = "size", required = false) final Integer size,
@RequestParam(value = "sortColumn", required = false) final String sortColumn,
@RequestParam(value = "sortDirection", required = false) final String sortDirection) {
if (officeIdentifier != null && !this.officeService.officeExists(officeIdentifier)) {
throw ServiceException.notFound("Office {0} not found.", officeIdentifier);
}
return ResponseEntity.ok(this.employeeService.findEmployees(term, officeIdentifier, this.createPageRequest(pageIndex, size, sortColumn, sortDirection)));
}