MIFOSX-322: update apidocs for client pagination and sorting.
This commit is contained in:
+6
-2
@@ -94,7 +94,11 @@ public class ClientReadPlatformServiceImpl implements ClientReadPlatformService
|
||||
// have to scan entire database table.
|
||||
// sql += " order by c.display_name ASC, c.account_no ASC";
|
||||
if (searchParameters.isOrderByRequested()) {
|
||||
sqlBuilder.append(" order by ").append(searchParameters.getOrderBy()).append(' ').append(searchParameters.getSortOrder());
|
||||
sqlBuilder.append(" order by ").append(searchParameters.getOrderBy());
|
||||
|
||||
if (searchParameters.isSortOrderProvided()) {
|
||||
sqlBuilder.append(' ').append(searchParameters.getSortOrder());
|
||||
}
|
||||
}
|
||||
|
||||
if (searchParameters.isLimited()) {
|
||||
@@ -130,7 +134,7 @@ public class ClientReadPlatformServiceImpl implements ClientReadPlatformService
|
||||
}
|
||||
|
||||
if (externalId != null) {
|
||||
extraCriteria += " and external_id like " + ApiParameterHelper.sqlEncodeString(externalId);
|
||||
extraCriteria += " and c.external_id like " + ApiParameterHelper.sqlEncodeString(externalId);
|
||||
}
|
||||
|
||||
if (displayName != null) {
|
||||
|
||||
+5
-1
@@ -56,7 +56,11 @@ public final class SearchParameters {
|
||||
}
|
||||
|
||||
public boolean isOrderByRequested() {
|
||||
return StringUtils.isNotBlank(this.orderBy) && StringUtils.isNotBlank(this.sortOrder);
|
||||
return StringUtils.isNotBlank(this.orderBy);
|
||||
}
|
||||
|
||||
public boolean isSortOrderProvided() {
|
||||
return StringUtils.isNotBlank(this.sortOrder);
|
||||
}
|
||||
|
||||
public String getSqlSearch() {
|
||||
|
||||
Reference in New Issue
Block a user