From 1560ac82916bd5824c108aefec22fc8240d3044b Mon Sep 17 00:00:00 2001 From: jens Date: Tue, 14 Jan 2020 12:00:59 +0100 Subject: [PATCH 1/2] Revert change --- README.md | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/README.md b/README.md index fbcd2cce0..8482ae4f3 100644 --- a/README.md +++ b/README.md @@ -1,16 +1,6 @@ BootsFaces-OSP ============== -### Note about this repository -This is our maintained repository of the original [BootsFaces repository](https://github.com/TheCoder4eu/BootsFaces-OSP). - -It includes our changes, bug fixes and improvements. All changes will be send to the original repository maintainer -as a pull request, hopefully included in a future version of the origin repository. - -Here you will find our [SEB Snapshot Showcase](http://bootsfaces.sebsoftware.de) - ---- -

From 28d58cb44bbb9d0796e223214e8bf8864f720e29 Mon Sep 17 00:00:00 2001 From: jens Date: Mon, 3 Aug 2020 15:29:06 +0200 Subject: [PATCH 2/2] Fix radioButton checked rendering The comparison for the checked attribute was not working, if the f:selectItem form is used and the values are not string values. In that case the values is compared as string to the object value, that wasn't equal. --- .../net/bootsfaces/component/radiobutton/Radiobutton.java | 2 +- .../component/radiobutton/RadiobuttonRenderer.java | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/main/java/net/bootsfaces/component/radiobutton/Radiobutton.java b/src/main/java/net/bootsfaces/component/radiobutton/Radiobutton.java index f72194445..f0479b3a7 100644 --- a/src/main/java/net/bootsfaces/component/radiobutton/Radiobutton.java +++ b/src/main/java/net/bootsfaces/component/radiobutton/Radiobutton.java @@ -65,7 +65,7 @@ public void processEvent(ComponentSystemEvent event) throws AbortProcessingExcep } } -public String getFamily() { + public String getFamily() { return COMPONENT_FAMILY; } diff --git a/src/main/java/net/bootsfaces/component/radiobutton/RadiobuttonRenderer.java b/src/main/java/net/bootsfaces/component/radiobutton/RadiobuttonRenderer.java index 922a31c77..fd3175bfc 100644 --- a/src/main/java/net/bootsfaces/component/radiobutton/RadiobuttonRenderer.java +++ b/src/main/java/net/bootsfaces/component/radiobutton/RadiobuttonRenderer.java @@ -205,8 +205,12 @@ public void encodeBegin(FacesContext context, UIComponent component) throws IOEx // traditional JSF approach using f:selectItem[s] int counter=0; for (SelectItemAndComponent option:options) { + String o = null; + if (null != option.getSelectItem().getValue()) { + o = String.valueOf(option.getSelectItem().getValue()); + } generateASingleRadioButton(context, component, radiobutton, rw, propertyName, beanValue, - option.getSelectItem().getValue(), + o, option.getSelectItem().getLabel(), clientId+(counter++), option.getSelectItem().isDisabled()); }