src/main/java/org/efaps/ui/wicket/models/field/factories/BooleanUIFactory.java
@SuppressWarnings("unchecked")
    @Override
    public Component getEditable(final String _wicketId,
                                 final AbstractUIField _uiField)
        throws EFapsException
    {
        Component ret = null;
        if (applies(_uiField)) {
            final FieldConfiguration config = _uiField.getFieldConfiguration();
            final UIType uiType = config.getUIType();
            if (uiType.equals(UIType.CHECKBOX)) {
                ret = new CheckBoxField(_wicketId, Model.of(_uiField), null, config);
            } else {
                final IModel<Map<Object, Object>> model = Model.ofMap((Map<Object, Object>) _uiField.getValue()
                                .getEditValue(_uiField.getParent().getMode()));
                final Serializable value = _uiField.getValue().getDbValue();
                ret = new BooleanField(_wicketId, value, model, _uiField.getFieldConfiguration(), _uiField.getLabel(),
                                _uiField instanceof UIFieldSetValue);
            }
        }
        return ret;
    }
@SuppressWarnings("unchecked")
    @Override
    public Component getEditable(final String _wicketId,
                                 final AbstractUIField _uiField)
        throws EFapsException
    {
        Component ret = null;
        if (applies(_uiField)) {
            final FieldConfiguration config = _uiField.getFieldConfiguration();
            final UIType uiType = config.getUIType();
            if (uiType.equals(UIType.CHECKBOX)) {
                ret = new CheckBoxField(_wicketId, Model.of(_uiField), null, config);
            } else {
                final IModel<Map<Object, Object>> model = Model.ofMap((Map<Object, Object>) _uiField.getValue()
                                .getEditValue(_uiField.getParent().getMode()));
                final Serializable value = _uiField.getValue().getDbValue();
                ret = new BooleanField(_wicketId, value, model, _uiField.getFieldConfiguration(), _uiField.getLabel(),
                                _uiField instanceof UIFieldSetValue);
            }
        }
        return ret;
    }
@ SuppressWarnings ( "unchecked" ) @ Override public Component getEditable ( final String _wicketId , final AbstractUIField _uiField ) throws EFapsException { Component ret = null ; if ( applies ( _uiField ) ) { final FieldConfiguration config = _uiField . getFieldConfiguration ( ) ; final UIType uiType = config . getUIType ( ) ; if ( uiType . equals ( UIType . CHECKBOX ) ) { ret = new CheckBoxField ( _wicketId , Model . of ( _uiField ) , null , config ) ; } else { final IModel < Map < Object , Object > > model = Model . ofMap ( ( Map < Object , Object > ) _uiField . getValue ( ) . getEditValue ( _uiField . getParent ( ) . getMode ( ) ) ) ; final Serializable value = _uiField . getValue ( ) . getDbValue ( ) ; ret = new BooleanField ( _wicketId , value , model , _uiField . getFieldConfiguration ( ) , _uiField . getLabel ( ) , _uiField instanceof UIFieldSetValue ) ; } } return ret ; }
{@inheritDoc}
{