You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Juergen Donnerstag (JIRA)" <ji...@apache.org> on 2010/03/21 18:29:27 UTC
[jira] Resolved: (WICKET-2780) Containers in forms inside a border
is not validated correctly
[ https://issues.apache.org/jira/browse/WICKET-2780?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Juergen Donnerstag resolved WICKET-2780.
----------------------------------------
Resolution: Invalid
Assignee: Juergen Donnerstag
you need to add <code>form.add(getBodyContainer());</code> to your myborder.java class. You need to tell Wicket that the body needs to be added to the form and not the border.
> Containers in forms inside a border is not validated correctly
> --------------------------------------------------------------
>
> Key: WICKET-2780
> URL: https://issues.apache.org/jira/browse/WICKET-2780
> Project: Wicket
> Issue Type: Bug
> Components: wicket
> Affects Versions: 1.4.1
> Environment: Tested with 1.4.1, but 1.4.7 code looks identical
> Reporter: Adriano dos Santos Fernandes
> Assignee: Juergen Donnerstag
> Attachments: bordervalidation.zip
>
>
> I've a border that have a form and in that form there is a DateField component. DateField is a FormComponentPanel with a embedded DateTextField.
> This code below in Form.java does not validate that component correctly, when an invalid date is entered.
> // Borders need special treatment
> if (!error[0] && (getParent() instanceof Border))
> {
> MarkupContainer border = getParent();
> Iterator<? extends Component> iter = border.iterator();
> while (!error[0] && iter.hasNext())
> {
> Component child = iter.next();
> if ((child != this) && (child instanceof FormComponent))
> {
> visitor.component(child);
> }
> }
> }
> The problem is that the visitor is not used to go deeper in the hierarchy, so the DateTextField is never reached.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.