当前位置: 首页>>代码示例>>Java>>正文


Java CheckboxGroupControl类代码示例

本文整理汇总了Java中org.kuali.rice.krad.uif.control.CheckboxGroupControl的典型用法代码示例。如果您正苦于以下问题:Java CheckboxGroupControl类的具体用法?Java CheckboxGroupControl怎么用?Java CheckboxGroupControl使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


CheckboxGroupControl类属于org.kuali.rice.krad.uif.control包,在下文中一共展示了CheckboxGroupControl类的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getDataFieldColumnOptions

import org.kuali.rice.krad.uif.control.CheckboxGroupControl; //导入依赖的package包/类
/**
 * Construct the column options for a data field
 *
 * @param collectionGroup the collectionGroup in which the data field is defined
 * @param field the field to construction options for
 * @return options as valid for datatable
 */
protected String getDataFieldColumnOptions(int target, CollectionGroup collectionGroup, DataField field) {
    String sortType = null;

    if (!collectionGroup.isReadOnly()
            && (field instanceof InputField)
            && ((InputField) field).getControl() != null) {
        Control control = ((InputField) field).getControl();
        if (control instanceof SelectControl) {
            sortType = UifConstants.TableToolsValues.DOM_SELECT;
        } else if (control instanceof CheckboxControl || control instanceof CheckboxGroupControl) {
            sortType = UifConstants.TableToolsValues.DOM_CHECK;
        } else if (control instanceof RadioGroupControl) {
            sortType = UifConstants.TableToolsValues.DOM_RADIO;
        } else {
            sortType = UifConstants.TableToolsValues.DOM_TEXT;
        }
    } else {
        sortType = UifConstants.TableToolsValues.DOM_TEXT;
    }

    Class dataTypeClass = ObjectPropertyUtils.getPropertyType(collectionGroup.getCollectionObjectClass(),
            field.getPropertyName());

    return constructTableColumnOptions(target, true, dataTypeClass, sortType);
}
 
开发者ID:aapotts,项目名称:kuali_rice,代码行数:33,代码来源:RichTable.java

示例2: getDataFieldColumnOptions

import org.kuali.rice.krad.uif.control.CheckboxGroupControl; //导入依赖的package包/类
/**
 * Construct the column options for a data field
 *
 * @param target column index
 * @param collectionGroup the collectionGroup in which the data field is defined
 * @param field the field to construction options for
 * @return options as valid for datatable
 */
protected String getDataFieldColumnOptions(int target, CollectionGroup collectionGroup, DataField field) {
    String sortDataType = null;

    if (!Boolean.TRUE.equals(collectionGroup.getReadOnly())
            && (field instanceof InputField)
            && ((InputField) field).getControl() != null) {
        Control control = ((InputField) field).getControl();
        if (control instanceof SelectControl) {
            sortDataType = UifConstants.TableToolsValues.DOM_SELECT;
        } else if (control instanceof CheckboxControl || control instanceof CheckboxGroupControl) {
            sortDataType = UifConstants.TableToolsValues.DOM_CHECK;
        } else if (control instanceof RadioGroupControl) {
            sortDataType = UifConstants.TableToolsValues.DOM_RADIO;
        } else {
            sortDataType = UifConstants.TableToolsValues.DOM_TEXT;
        }
    } else {
        sortDataType = UifConstants.TableToolsValues.DOM_TEXT;
    }

    Class<?> dataTypeClass = ObjectPropertyUtils.getPropertyType(collectionGroup.getCollectionObjectClass(),
            field.getPropertyName());
    // check to see if field has custom sort type
    if (field.getSortAs() != null && field.getSortAs().length() > 0) {
        if (field.getSortAs().equals(UifConstants.TableToolsValues.CURRENCY)) {
            dataTypeClass = KualiDecimal.class;
        } else if (field.getSortAs().equals(UifConstants.TableToolsValues.DATE)) {
            dataTypeClass = java.sql.Date.class;
        } else if (field.getSortAs().equals(UifConstants.TableToolsValues.NUMERIC)) {
            dataTypeClass = Number.class;
        } else if (field.getSortAs().equals(UifConstants.TableToolsValues.STRING)) {
            dataTypeClass = String.class;
        }
    }

    boolean isSortable = true;
    if (field.isApplyMask()) {
        isSortable = false;
    }

    return constructTableColumnOptions(target, isSortable, collectionGroup.isUseServerPaging(), dataTypeClass,
            sortDataType);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:52,代码来源:RichTable.java

示例3: getCheckboxGroupControl

import org.kuali.rice.krad.uif.control.CheckboxGroupControl; //导入依赖的package包/类
/**
 * Retrieves a new checkbox group control instance from Spring (initialized by the bean definition
 * with the given id)
 *
 * <p>
 * Return checkbox group set for vertical orientation
 * </p>
 *
 * @return CheckboxGroupControl
 */
public static CheckboxGroupControl getCheckboxGroupControl() {
    return (CheckboxGroupControl) getNewComponentInstance(CHECKBOX_GROUP_CONTROL);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:14,代码来源:ComponentFactory.java

示例4: getCheckboxGroupControlHorizontal

import org.kuali.rice.krad.uif.control.CheckboxGroupControl; //导入依赖的package包/类
/**
 * Retrieves a new checkbox group control instance from Spring (initialized by the bean definition
 * with the given id)
 *
 * <p>
 * Return checkbox group set for horizontal orientation
 * </p>
 *
 * @return CheckboxGroupControl
 */
public static CheckboxGroupControl getCheckboxGroupControlHorizontal() {
    return (CheckboxGroupControl) getNewComponentInstance(CHECKBOX_GROUP_CONTROL_HORIZONTAL);
}
 
开发者ID:kuali,项目名称:kc-rice,代码行数:14,代码来源:ComponentFactory.java


注:本文中的org.kuali.rice.krad.uif.control.CheckboxGroupControl类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。