001: /*
002: * Copyright 2007 The Kuali Foundation.
003: *
004: * Licensed under the Educational Community License, Version 1.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/ecl1.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.module.labor.web.inquirable;
017:
018: import java.util.ArrayList;
019: import java.util.HashMap;
020: import java.util.List;
021: import java.util.Map;
022:
023: import org.kuali.kfs.KFSConstants;
024: import org.kuali.module.gl.util.BusinessObjectFieldConverter;
025: import org.kuali.module.gl.web.Constant;
026: import org.kuali.module.labor.bo.LedgerBalance;
027:
028: /**
029: * This class is used to generate the URL for the user-defined attributes for the July1 Position Funds screen. It is entended the
030: * KualiInquirableImpl class, so it covers both the default implementation and customized implemetnation.
031: */
032: public class July1PositionFundingInquirableImpl extends
033: AbstractLaborInquirableImpl {
034: private static final org.apache.log4j.Logger LOG = org.apache.log4j.Logger
035: .getLogger(July1PositionFundingInquirableImpl.class);
036:
037: /**
038: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#buildUserDefinedAttributeKeyList()
039: */
040: protected List buildUserDefinedAttributeKeyList() {
041: List<String> keys = new ArrayList<String>();
042: return keys;
043: }
044:
045: /**
046: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getUserDefinedAttributeMap()
047: */
048: protected Map getUserDefinedAttributeMap() {
049:
050: Map userDefinedAttributeMap = new HashMap();
051: return userDefinedAttributeMap;
052: }
053:
054: /**
055: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getAttributeName(java.lang.String)
056: */
057: protected String getAttributeName(String attributeName) {
058: return attributeName;
059: }
060:
061: /**
062: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getKeyValue(java.lang.String, java.lang.Object)
063: */
064: protected Object getKeyValue(String keyName, Object keyValue) {
065: if (isExclusiveField(keyName, keyValue)) {
066: keyValue = Constant.EMPTY_STRING;
067: }
068: return keyValue;
069: }
070:
071: /**
072: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getKeyName(java.lang.String)
073: */
074: protected String getKeyName(String keyName) {
075: keyName = BusinessObjectFieldConverter
076: .convertToTransactionPropertyName(keyName);
077: return keyName;
078: }
079:
080: /**
081: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getLookupableImplAttributeName()
082: */
083: protected String getLookupableImplAttributeName() {
084: return "july1PositionFundingLookupable";
085: }
086:
087: /**
088: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getBaseUrl()
089: */
090: protected String getBaseUrl() {
091: return KFSConstants.GL_MODIFIED_INQUIRY_ACTION;
092: }
093:
094: /**
095: * @see org.kuali.module.gl.web.inquirable.AbstractGLInquirableImpl#getInquiryBusinessObjectClass(String)
096: */
097: protected Class getInquiryBusinessObjectClass(String attributeName) {
098: return LedgerBalance.class;
099: }
100: }
|