use of de.agilecoders.wicket.extensions.markup.html.bootstrap.form.checkbox.bootstrapcheckbox.BootstrapCheckBoxPickerConfig in project ocvn by devgateway.
the class CheckBoxPickerBootstrapFormComponent method inputField.
@Override
protected BootstrapCheckBoxPicker inputField(final String id, final IModel<Boolean> model) {
config = new BootstrapCheckBoxPickerConfig().withOnClass("btn-info").withOffClass("btn-warning").withOnIcon(FontAwesomeIconType.thumbs_up).withOffIcon(FontAwesomeIconType.thumbs_down).withReverse(true).withStyle(ButtonGroup.Size.Small);
final BootstrapCheckBoxPicker checkBoxPicker = new BootstrapCheckBoxPicker("field", initFieldModel(), config);
checkBoxPicker.add(new AjaxFormComponentUpdatingBehavior("change") {
private static final long serialVersionUID = 1L;
@Override
protected void onUpdate(final AjaxRequestTarget target) {
CheckBoxPickerBootstrapFormComponent.this.onUpdate(target);
}
});
return checkBoxPicker;
}
use of de.agilecoders.wicket.extensions.markup.html.bootstrap.form.checkbox.bootstrapcheckbox.BootstrapCheckBoxPickerConfig in project oc-explorer by devgateway.
the class CheckBoxPickerBootstrapFormComponent method inputField.
@Override
protected BootstrapCheckBoxPicker inputField(final String id, final IModel<Boolean> model) {
config = new BootstrapCheckBoxPickerConfig().withOnClass("btn-info").withOffClass("btn-warning").withOnIcon(FontAwesomeIconType.thumbs_up).withOffIcon(FontAwesomeIconType.thumbs_down).withReverse(true).withStyle(ButtonGroup.Size.Small);
final BootstrapCheckBoxPicker checkBoxPicker = new BootstrapCheckBoxPicker("field", initFieldModel(), config);
checkBoxPicker.add(new AjaxFormComponentUpdatingBehavior("change") {
private static final long serialVersionUID = 1L;
@Override
protected void onUpdate(final AjaxRequestTarget target) {
CheckBoxPickerBootstrapFormComponent.this.onUpdate(target);
}
});
return checkBoxPicker;
}
Aggregations