You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Martin Grigorov (JIRA)" <ji...@apache.org> on 2010/04/21 16:03:50 UTC

[jira] Closed: (WICKET-2744) AjaxFormChoiceComponentUpdatingBehavior cannot find the choice

     [ https://issues.apache.org/jira/browse/WICKET-2744?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Martin Grigorov closed WICKET-2744.
-----------------------------------

    Resolution: Fixed

It is already fixed in https://issues.apache.org/jira/browse/WICKET-2806

> AjaxFormChoiceComponentUpdatingBehavior cannot find the choice
> --------------------------------------------------------------
>
>                 Key: WICKET-2744
>                 URL: https://issues.apache.org/jira/browse/WICKET-2744
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.4.6
>            Reporter: Martin Grigorov
>            Assignee: Igor Vaynberg
>             Fix For: 1.5-M1, 1.4.7
>
>         Attachments: ajaxradiochoice.tgz
>
>
> AjaxFormChoiceComponentUpdatingBehavior tries to find the form components (the choices) by iterating the children elements with tagName 'input' and verifying some constraints. One of this constraints have been changed recently and now the children could not be found:
> Index: src/main/java/org/apache/wicket/ajax/form/AjaxFormChoiceComponentUpdatingBehavior.java
> ===================================================================
> --- src/main/java/org/apache/wicket/ajax/form/AjaxFormChoiceComponentUpdatingBehavior.java	(revision 909983)
> +++ src/main/java/org/apache/wicket/ajax/form/AjaxFormChoiceComponentUpdatingBehavior.java	(working copy)
> @@ -70,7 +70,7 @@
>  		asb.append(" for (var i = 0 ; i < inputNodes.length ; i ++) {\n");
>  		asb.append(" var inputNode = inputNodes[i];\n");
>  		asb.append(" if (!inputNode.type) continue;\n");
> -		asb.append(" if (!(inputNode.className.indexOf('wicket-'+markupId)===0)) continue;\n");
> +		asb.append(" if (!(inputNode.id.indexOf(markupId+'-')===0)) continue;\n");
>  		asb.append(" var inputType = inputNode.type.toLowerCase();\n");
>  		asb.append(" if (inputType == 'checkbox' || inputType == 'radio') {\n");
>  		asb.append(" Wicket.Event.add(inputNode, 'click', callbackScript);\n");

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.