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: import java.util.Properties;
023:
024: import org.kuali.kfs.KFSConstants;
025: import org.kuali.kfs.KFSPropertyConstants;
026: import org.kuali.module.labor.LaborPropertyConstants;
027: import org.kuali.module.labor.bo.PositionData;
028:
029: /**
030: * This class is used to generate the URL for the user-defined attributes for the Position Inquiry screen. It is entended the
031: * KualiInquirableImpl class, so it covers both the default implementation and customized implemetnation.
032: */
033: public class PositionDataDetailsInquirableImpl extends
034: AbstractLaborInquirableImpl {
035:
036: /**
037: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#addMoreParameters(java.util.Properties,
038: * java.lang.String)
039: */
040: @Override
041: protected void addMoreParameters(Properties parameter,
042: String attributeName) {
043: parameter.put(KFSConstants.DISPATCH_REQUEST_PARAMETER,
044: KFSConstants.START_METHOD);
045: }
046:
047: /**
048: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#buildUserDefinedAttributeKeyList()
049: */
050: protected List buildUserDefinedAttributeKeyList() {
051: List keys = new ArrayList();
052: keys.add(KFSPropertyConstants.POSITION_NUMBER);
053: keys.add(LaborPropertyConstants.EFFECTIVE_DATE);
054: return keys;
055: }
056:
057: /**
058: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getAttributeName(java.lang.String)
059: */
060: protected String getAttributeName(String attributeName) {
061: return KFSPropertyConstants.POSITION_NUMBER;
062: }
063:
064: /**
065: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getBaseUrl()
066: */
067: protected String getBaseUrl() {
068: return KFSConstants.INQUIRY_ACTION;
069: }
070:
071: /**
072: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getInquiryBusinessObjectClass(java.lang.String)
073: */
074: protected Class getInquiryBusinessObjectClass(String attributeName) {
075: return PositionData.class;
076: }
077:
078: /**
079: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getKeyName(java.lang.String)
080: */
081: protected String getKeyName(String keyName) {
082: return keyName;
083: }
084:
085: /**
086: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getKeyValue(java.lang.String, java.lang.Object)
087: */
088: protected Object getKeyValue(String keyName, Object keyValue) {
089: return keyValue;
090: }
091:
092: /**
093: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getLookupableImplAttributeName()
094: */
095: protected String getLookupableImplAttributeName() {
096: return null;
097: }
098:
099: /**
100: * @see org.kuali.module.labor.web.inquirable.AbstractLaborInquirableImpl#getUserDefinedAttributeMap()
101: */
102: protected Map getUserDefinedAttributeMap() {
103: Map userDefinedAttributeMap = new HashMap();
104: userDefinedAttributeMap.put(
105: KFSPropertyConstants.POSITION_NUMBER,
106: KFSPropertyConstants.POSITION_NUMBER);
107:
108: return userDefinedAttributeMap;
109: }
110: }
|