myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Andreas Wuest (JIRA)" <...@myfaces.apache.org>
Subject [jira] [Comment Edited] (TOMAHAWK-1680) add the possibility to disable an individual t:radio
Date Tue, 09 Feb 2016 15:40:18 GMT

    [ https://issues.apache.org/jira/browse/TOMAHAWK-1680?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15139076#comment-15139076
] 

Andreas Wuest edited comment on TOMAHAWK-1680 at 2/9/16 3:39 PM:
-----------------------------------------------------------------

The attached patch solved the problem for me by adding a new attribte to the tag. However
i was not able to find a proper testcase that i could extend. The logic for enabling / disabling
the radio button, never seems to be tested, is it?
The patch is only again core20 since that is the version we are using, but i guess it should
also be applied against core21 and maybe core12 (haven't looked at those). The patch is rather
simple so it should be easy to adjust for 12 and 21.


was (Author: kickmetondy):
Patch that solved the problem for me by adding a new attribte to the tag. However i was not
able to find a proper testcase that i could extend. The logic for enabling / disabling the
radio button, never seems to be tested, is it?
The patch is only again core20 since that is the version we are using, but i guess it should
also be applied against core21 and maybe core12 (haven't looked at those). The patch is rather
simple so it should be easy to adjust for 12 and 21.

> add the possibility to disable an individual t:radio
> ----------------------------------------------------
>
>                 Key: TOMAHAWK-1680
>                 URL: https://issues.apache.org/jira/browse/TOMAHAWK-1680
>             Project: MyFaces Tomahawk
>          Issue Type: Wish
>          Components: selectOneRadio / radio
>    Affects Versions: 1.1.14
>         Environment: Win 7 / Linux
>            Reporter: Andreas Wuest
>         Attachments: ExtendedHtmlRadioRenderer.java, PATCH_1680.patch
>
>
> Hello,
> please add the possibility to disable an individual t:radio Radio Button. At the moment
it is only possible to enable/disable a complete group defined via t:selectOneRadio. However
it is not possible to enabled / disable an individual radio button from the group. It is only
possible to enable / disable all or none.
> Example:
> define the group with all the possible elements
> {code}
>  <t:selectOneRadio id="radioGrpFSGuarantor" layout="spread" value="#{clientRolesDlg.roleFSGuarantor}">
>      <f:selectItems value="#{clientRolesDlg.selectRolesList}" />
>      <f:ajax execute="@form" listener="#clientRolesDlg.onRoleChanged" /> 
> </t:selectOneRadio>
> <ui:repeat id="rClientRowStatus" value="#{clientRolesDlg.rows}" var="clientRow" varStatus="clientRowStatus">
>   <tr>
>      <td>
>          <t:outputText id="otHasData" value="#{clientRow}" />
>      </td>
>      <td >
>          <t:radio for=":globalForm:radioGrpFSCustomer" index="#{clientRowStatus.index}"
disabled="true|false" />      <-------------- additional disable attribute
>      </td>
>    </tr>
> </ui:repeat>
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message