001 /*
002 * Copyright 2011 The Kuali Foundation.
003 *
004 * Licensed under the Educational Community License, Version 2.0 (the "License");
005 * you may not use this file except in compliance with the License.
006 * You may obtain a copy of the License at
007 *
008 * http://www.opensource.org/licenses/ecl2.php
009 *
010 * Unless required by applicable law or agreed to in writing, software
011 * distributed under the License is distributed on an "AS IS" BASIS,
012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
013 * See the License for the specific language governing permissions and
014 * limitations under the License.
015 */
016 package org.kuali.kfs.module.ld.businessobject.lookup;
017
018 import java.util.List;
019 import java.util.Map;
020
021 import org.kuali.kfs.module.ld.businessobject.LedgerBalanceForEffortCertification;
022 import org.kuali.rice.kns.bo.BusinessObject;
023 import org.kuali.rice.kns.lookup.KualiLookupableHelperServiceImpl;
024 import org.kuali.rice.kns.lookup.LookupableHelperService;
025 import org.kuali.rice.kns.util.KNSConstants;
026
027 public class LedgerBalanceForEffortCertificationLookupableHelperServiceImpl extends KualiLookupableHelperServiceImpl {
028
029 private LookupableHelperService effortLedgerBalanceLookupableHelperService;
030
031 /**
032 * @see org.kuali.rice.kns.lookup.LookupableHelperService#getSearchResults(java.util.Map)
033 */
034 public List<? extends BusinessObject> getSearchResults(Map<String, String> fieldValues) {
035 setBackLocation(fieldValues.get(KNSConstants.BACK_LOCATION));
036 setDocFormKey(fieldValues.get(KNSConstants.DOC_FORM_KEY));
037 setReferencesToRefresh(fieldValues.get(KNSConstants.REFERENCES_TO_REFRESH));
038
039 List<LedgerBalanceForEffortCertification> searchResults = effortLedgerBalanceLookupableHelperService.getSearchResults(fieldValues);
040
041 return searchResults;
042 }
043
044 /**
045 * Sets the effortLedgerBalanceLookupableHelperService attribute value.
046 * @param effortLedgerBalanceLookupableHelperService The effortLedgerBalanceLookupableHelperService to set.
047 */
048 public void setEffortLedgerBalanceLookupableHelperService(LookupableHelperService effortLedgerBalanceLookupableHelperService) {
049 if(effortLedgerBalanceLookupableHelperService != null) {
050 this.effortLedgerBalanceLookupableHelperService = effortLedgerBalanceLookupableHelperService;
051 }
052 else {
053 this.effortLedgerBalanceLookupableHelperService = new KualiLookupableHelperServiceImpl();
054 }
055 }
056 }