FINERACT-2282: Support Client filtering by legal form

This commit is contained in:
Adam Saghy
2025-05-16 19:36:48 +02:00
parent ed42fb2410
commit c79de9bb7a
8 changed files with 71 additions and 15 deletions
@@ -56,6 +56,7 @@ public class SearchParameters {
private Long categoryId;
@Getter(AccessLevel.NONE)
private Boolean isSelfUser;
private Integer legalForm;
public Integer getLimit() {
if (limit == null) {
@@ -128,4 +129,16 @@ public class SearchParameters {
public boolean hasCategoryId() {
return this.categoryId != null && this.categoryId != 0;
}
public boolean isPerson() {
return this.legalForm != null && this.legalForm == 1;
}
public boolean isEntity() {
return this.legalForm != null && this.legalForm == 2;
}
public boolean hasLegalForm() {
return this.legalForm != null;
}
}
@@ -197,7 +197,7 @@ public class ClientApiConstants {
officeNameParamName, transferToOfficeIdParamName, transferToOfficeNameParamName, hierarchyParamName, imageIdParamName,
imagePresentParamName, staffIdParamName, staffNameParamName, timelineParamName, groupsParamName, officeOptionsParamName,
staffOptionsParamName, dateOfBirthParamName, genderParamName, clientTypeParamName, clientClassificationParamName,
legalFormParamName, clientNonPersonDetailsParamName, isStaffParamName));
legalFormParamName, clientNonPersonDetailsParamName, isStaffParamName, legalFormParamName));
protected static final Set<String> CLIENT_CHARGES_RESPONSE_DATA_PARAMETERS = new HashSet<>(Arrays.asList(chargeIdParamName,
clientIdParamName, chargeNameParamName, penaltyParamName, chargeTimeTypeParamName, dueAsOfDateParamName,