cs_blocked при создании PaymentInstruction: для категории I ИЛИ V
This commit is contained in:
parent
b96fcaae7d
commit
6590d63026
1 changed files with 3 additions and 3 deletions
|
|
@ -236,7 +236,7 @@ public class PaymentInstructionBuilderV2 {
|
||||||
boolean hasCounterPartyInitiator = false;
|
boolean hasCounterPartyInitiator = false;
|
||||||
for (Registry claim : claims) {
|
for (Registry claim : claims) {
|
||||||
Long counterPartyId = claim.getCounterPartyId();
|
Long counterPartyId = claim.getCounterPartyId();
|
||||||
if (categoryVInitiator(counterPartyId) && companyRoleODEPPresent(counterPartyId)) {
|
if (categoryIOrVInitiator(counterPartyId) && companyRoleODEPPresent(counterPartyId)) {
|
||||||
hasCounterPartyInitiator = true;
|
hasCounterPartyInitiator = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
@ -244,11 +244,11 @@ public class PaymentInstructionBuilderV2 {
|
||||||
return hasCounterPartyInitiator;
|
return hasCounterPartyInitiator;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean categoryVInitiator(Long companyId) {
|
public boolean categoryIOrVInitiator(Long companyId) {
|
||||||
ClearingMemberCategory category = clearingCategoryImdg.getFirstObjectByFieldValues(
|
ClearingMemberCategory category = clearingCategoryImdg.getFirstObjectByFieldValues(
|
||||||
Map.of("companyId", companyId));
|
Map.of("companyId", companyId));
|
||||||
ClearingCategory ctg = IEnumKey.getEnumByKey(ClearingCategory.class, category.getClearingMemberCategory());
|
ClearingCategory ctg = IEnumKey.getEnumByKey(ClearingCategory.class, category.getClearingMemberCategory());
|
||||||
return ctg != null && ctg.equals(ClearingCategory.V);
|
return ctg != null && (ctg.equals(ClearingCategory.V) || ctg.equals(ClearingCategory.I)) ;
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean companyRoleODEPPresent(Long companyId) {
|
public boolean companyRoleODEPPresent(Long companyId) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue