reports-service http://jira.mfd.msk:8088/browse/CLS-358 refactoring predicate
This commit is contained in:
parent
5863500e51
commit
679a7ebd23
2 changed files with 2 additions and 4 deletions
|
|
@ -90,14 +90,13 @@ public class KSRepCashRegisterSumsReportBuilder extends CSVReportBuilder<EmptyPa
|
||||||
}
|
}
|
||||||
if (!WorkflowStatus.Active.equalsByKey(company.getWorkflowStatus())) continue;
|
if (!WorkflowStatus.Active.equalsByKey(company.getWorkflowStatus())) continue;
|
||||||
|
|
||||||
String sql = RegistryCodeSqlBuilder.getInstance(RegistryTradingParams.AM_T).build();
|
|
||||||
ImdgPredicateBuilder pbRegistry = registryImdg.predicateBuilder();
|
ImdgPredicateBuilder pbRegistry = registryImdg.predicateBuilder();
|
||||||
Collection<Registry> registries = registryImdg.getCollectionObjectsByPredicate(
|
Collection<Registry> registries = registryImdg.getCollectionObjectsByPredicate(
|
||||||
pbRegistry.and(
|
pbRegistry.and(
|
||||||
pbRegistry.equals("companyId", statement.getAddresseeId()),
|
pbRegistry.equals("companyId", statement.getAddresseeId()),
|
||||||
pbRegistry.equals("account", statement.getAccount()),
|
pbRegistry.equals("account", statement.getAccount()),
|
||||||
pbRegistry.in("accountType", AccountType.Clrn.getKey(), AccountType.Info.getKey()),
|
pbRegistry.in("accountType", AccountType.Clrn.getKey(), AccountType.Info.getKey()),
|
||||||
pbRegistry.sql(sql)
|
RegistryCodeSqlBuilder.getInstance(RegistryTradingParams.AM_T).buildPredicate(pbRegistry)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
if (registries.isEmpty()) {
|
if (registries.isEmpty()) {
|
||||||
|
|
|
||||||
|
|
@ -100,14 +100,13 @@ public class KSRepDepoRegisterQuantitiesReportBuilder extends CSVReportBuilder<E
|
||||||
}
|
}
|
||||||
if (!WorkflowStatus.Active.equalsByKey(company.getWorkflowStatus())) continue;
|
if (!WorkflowStatus.Active.equalsByKey(company.getWorkflowStatus())) continue;
|
||||||
|
|
||||||
String sql = RegistryCodeSqlBuilder.getInstance(RegistryTradingParams.AS_T).build();
|
|
||||||
ImdgPredicateBuilder pbRegistry = registryImdg.predicateBuilder();
|
ImdgPredicateBuilder pbRegistry = registryImdg.predicateBuilder();
|
||||||
Collection<Registry> registries = registryImdg.getCollectionObjectsByPredicate(
|
Collection<Registry> registries = registryImdg.getCollectionObjectsByPredicate(
|
||||||
pbRegistry.and(
|
pbRegistry.and(
|
||||||
pbRegistry.equals("companyId", statement.getAddresseeId()),
|
pbRegistry.equals("companyId", statement.getAddresseeId()),
|
||||||
pbRegistry.equals("account", statement.getAccount()),
|
pbRegistry.equals("account", statement.getAccount()),
|
||||||
pbRegistry.equals("accountType", AccountType.Depo.getKey()),
|
pbRegistry.equals("accountType", AccountType.Depo.getKey()),
|
||||||
pbRegistry.sql(sql)
|
RegistryCodeSqlBuilder.getInstance(RegistryTradingParams.AS_T).buildPredicate(pbRegistry)
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
if (registries.isEmpty()) {
|
if (registries.isEmpty()) {
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue