Activity Ledger based reports with account filter error
Description
Michelle was attempting to create reports for Maumee district personnel using account filters. ActivityLedger based reports always created empty reports while filtering other reports with the same filters appeared to work correctly.
Additionally, adding a filter that includes a TI=00 with a fund code caused an NPE when attempting to run an ActivityLedger based report.
At least a part of the issue appears to be related lazy initialization. WildcardAccountFilter is using instanceof to determine which Predicate to create, it is not recognizing the object is an ExpenditureAccount so no predicate is created.
To do:
Make ti required in WildcardAccountFilter
Determine the Predicate to use from the ti value
Abstain if the object to test is not the right type otherwise, test with predicate
Replace instanceof checks with isAssignableFrom or ClassUtils.isAssignable()
Michelle was attempting to create reports for Maumee district personnel using account filters. ActivityLedger based reports always created empty reports while filtering other reports with the same filters appeared to work correctly.
Additionally, adding a filter that includes a TI=00 with a fund code caused an NPE when attempting to run an ActivityLedger based report.
At least a part of the issue appears to be related lazy initialization. WildcardAccountFilter is using instanceof to determine which Predicate to create, it is not recognizing the object is an ExpenditureAccount so no predicate is created.
To do:
Make ti required in WildcardAccountFilter
Determine the Predicate to use from the ti value
Abstain if the object to test is not the right type otherwise, test with predicate
Replace instanceof checks with isAssignableFrom or ClassUtils.isAssignable()
TI
Type
00
Cash Accounts
01
Appropriation Accounts
02
Budget Accounts
03
Revenue Accounts