/** * Get activity_statu_code * * @param fieldValues * @return */ protected Collection getActivityStatusCode(Map fieldValues) { Collection activityStatusCodes = new ArrayList<String>(); if (fieldValues.containsKey(CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE)) { String fieldValue = (String) fieldValues.get(CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE); if (KFSConstants.NON_ACTIVE_INDICATOR.equalsIgnoreCase(fieldValue)) { // when selected as 'N', search for active lines as 'M'-modified by CAB user,'N'- new activityStatusCodes.add(CabConstants.ActivityStatusCode.NEW); activityStatusCodes.add(CabConstants.ActivityStatusCode.MODIFIED); } fieldValues.remove(CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE); } return activityStatusCodes; }
/** * Update activity status code to the value used in DB. The reason is the value from user input * will be 'Y' or 'N'. However, these two status code are now replaced by 'N','E' and 'P'. * * @param fieldValues */ protected void updateStatusCodeCriteria(Map<String, String> fieldValues) { String activityStatusCode = null; if (fieldValues.containsKey(CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE)) { activityStatusCode = (String) fieldValues.get(CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE); } if (KFSConstants.NON_ACTIVE_INDICATOR.equalsIgnoreCase(activityStatusCode)) { // not processed in CAMs: 'N' fieldValues.put( CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE, CabConstants.ActivityStatusCode.NEW); } else if (KFSConstants.ACTIVE_INDICATOR.equalsIgnoreCase(activityStatusCode)) { // processed in CAMs: 'E' or 'P' fieldValues.put( CabPropertyConstants.GeneralLedgerEntry.ACTIVITY_STATUS_CODE, CabConstants.ActivityStatusCode.PROCESSED_IN_CAMS + SearchOperator.OR.op() + CabConstants.ActivityStatusCode.ENROUTE); } }