本文整理汇总了Java中org.kuali.rice.krad.datadictionary.AttributeDefinition.getControl方法的典型用法代码示例。如果您正苦于以下问题:Java AttributeDefinition.getControl方法的具体用法?Java AttributeDefinition.getControl怎么用?Java AttributeDefinition.getControl使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.kuali.rice.krad.datadictionary.AttributeDefinition
的用法示例。
在下文中一共展示了AttributeDefinition.getControl方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getAttributeControlDefinition
import org.kuali.rice.krad.datadictionary.AttributeDefinition; //导入方法依赖的package包/类
/**
* @see org.kuali.rice.krad.service.DataDictionaryService#getAttributeControlDefinition(java.lang.String)
*/
@Override
public ControlDefinition getAttributeControlDefinition(String entryName, String attributeName) {
ControlDefinition controlDefinition = null;
AttributeDefinition attributeDefinition = getAttributeDefinition(entryName, attributeName);
if (attributeDefinition != null) {
controlDefinition = attributeDefinition.getControl();
}
return controlDefinition;
}
示例2: getAttributeSize
import org.kuali.rice.krad.datadictionary.AttributeDefinition; //导入方法依赖的package包/类
/**
* @see org.kuali.rice.krad.service.DataDictionaryService#getAttributeSize(java.lang.String)
*/
@Override
public Integer getAttributeSize(String entryName, String attributeName) {
Integer size = null;
AttributeDefinition attributeDefinition = getAttributeDefinition(entryName, attributeName);
if (attributeDefinition != null) {
ControlDefinition controlDefinition = attributeDefinition.getControl();
if (controlDefinition.isText() || controlDefinition.isCurrency()) {
size = controlDefinition.getSize();
}
}
return size;
}
示例3: getAttributeControlDefinition
import org.kuali.rice.krad.datadictionary.AttributeDefinition; //导入方法依赖的package包/类
@Override
public ControlDefinition getAttributeControlDefinition(String entryName, String attributeName) {
ControlDefinition controlDefinition = null;
AttributeDefinition attributeDefinition = getAttributeDefinition(entryName, attributeName);
if (attributeDefinition != null) {
controlDefinition = attributeDefinition.getControl();
}
return controlDefinition;
}
示例4: getAttributeSize
import org.kuali.rice.krad.datadictionary.AttributeDefinition; //导入方法依赖的package包/类
@Override
public Integer getAttributeSize(String entryName, String attributeName) {
Integer size = null;
AttributeDefinition attributeDefinition = getAttributeDefinition(entryName, attributeName);
if (attributeDefinition != null) {
ControlDefinition controlDefinition = attributeDefinition.getControl();
if (controlDefinition.isText() || controlDefinition.isCurrency()) {
size = controlDefinition.getSize();
}
}
return size;
}
示例5: considerCustomButtonFieldAuthorization
import org.kuali.rice.krad.datadictionary.AttributeDefinition; //导入方法依赖的package包/类
/**
* @param dataObjectEntry if collectionItemBusinessObject is not null, then it is the DD entry for collectionItemBusinessObject.
* Otherwise, it is the entry for primaryBusinessObject
* @param primaryDataObject the top-level BO that is being inquiried or maintained
* @param collectionItemBusinessObject an element of a collection under the primaryBusinessObject that we are evaluating view auths for
* @param user the logged in user
* @param businessObjectAuthorizer
* @param inquiryOrMaintenanceDocumentRestrictions
* @param propertyPrefix
*/
protected void considerCustomButtonFieldAuthorization(
DataObjectEntry dataObjectEntry,
Object primaryDataObject,
BusinessObject collectionItemBusinessObject,
Person user,
BusinessObjectAuthorizer businessObjectAuthorizer,
MaintenanceDocumentRestrictions maintenanceDocumentRestrictions,
String propertyPrefix) {
for (String attributeName : dataObjectEntry.getAttributeNames()) {
AttributeDefinition attributeDefinition = dataObjectEntry
.getAttributeDefinition(attributeName);
// TODO what is the equivalent of control.isButton in KRAD
if (attributeDefinition.getControl() != null &&
attributeDefinition.getControl().isButton()) {
Map<String, String> collectionItemPermissionDetails = new HashMap<String, String>();
Map<String, String> collectionItemRoleQualifications = null;
if (ObjectUtils.isNotNull(collectionItemBusinessObject)) {
collectionItemPermissionDetails.putAll(getButtonFieldPermissionDetails(collectionItemBusinessObject, attributeName));
collectionItemPermissionDetails.putAll(businessObjectAuthorizer.
getCollectionItemPermissionDetails(collectionItemBusinessObject));
collectionItemRoleQualifications = new HashMap<String, String>(businessObjectAuthorizer.
getCollectionItemRoleQualifications(collectionItemBusinessObject));
}
else {
getButtonFieldPermissionDetails(primaryDataObject, attributeName);
}
if (!businessObjectAuthorizer
.isAuthorizedByTemplate(
primaryDataObject,
KRADConstants.KNS_NAMESPACE,
KimConstants.PermissionTemplateNames.PERFORM_CUSTOM_MAINTENANCE_DOCUMENT_FUNCTION,
user.getPrincipalId(),
collectionItemPermissionDetails,
collectionItemRoleQualifications)) {
maintenanceDocumentRestrictions
.addHiddenField(propertyPrefix + attributeName);
}
}
}
}