[KFSMI-940] AbstractLookupableHelperServiceImpl validateSearchParameters throws excepton if errorMap is not empty, which makes LookupAction search call unusable in some situations Created: 08/Jun/08  Updated: 27/Jan/14

Status: Rice Roadblock
Project: KFS Request
Affects Version/s: None
Fix Version/s: TBD

Type: Enhancement Priority: Minor
Reporter: Jerry Neal (Inactive)
Resolution: Unresolved Votes: 0

Issue Links:
Discovered
discovered KULRICE-8554 AbstractLookupableHelperServiceImpl v... Open
Duplicate
is duplicated by KULRICE-1979 AbstractLookupableHelperServiceImpl v... Open
Relate
is related to KULRICE-7946 KNS Enhancements Closed
Sub-Committee:
Tech / QA / PM
Impacted Modules:
System

 Description   

We have a situation in budget where we are doing some extra processing of lookup results (overriding LookupAction), if there are errors we add them to GlobalVariables errorMap and then call LookupAction.search to redisplay the search
results. LookupAction:search calls validateSearchParameters on lookupable, which calls lookupableHelperService and the default AbstractLookupableHelperServiceImpl implementation. The default implementation throws an exception at the
end of processing if the errorMap is not empty:

if (!GlobalVariables.getErrorMap().isEmpty())

{ throw new ValidationException("errors in search criteria"); }

So if there were errors previous to the method call but the validation was OK an exception will still be thrown. I believe it would be better if the method just checked for errors encountered within the method itself (maybe by a boolean) and then throw
an exception, allowing for the errorMap to contain errors from previous code.



 Comments   
Comment by Jerry Neal (Inactive) [ 16/Nov/12 ]

This is still an issue, should fix in KRAD

Generated at Mon Nov 30 11:02:17 CST 2020 using JIRA 7.0.11#70121-sha1:19d24976997c1d95f06f3e327e087be0b71f28d4.