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

Andrea Del Bene edited comment on WICKET-6041 at 12/11/15 3:49 PM:
-------------------------------------------------------------------

I think Yoann got the point. AFAIK form submitting also includes form 
processing. If this assumption is true a possible simple fix could be moving 
markFormsSubmitted at the bottom of Form#onFormSubmitted(IFormSubmitter), after 
we have invoked formToProcess.process(submitter);

{code}
....
else
{
        // the submit request might be for one of the nested forms, so let's
        // find the right one:
        final Form<?> formToProcess = findFormToProcess(submitter);
        
        // process the form for this request
        formToProcess.process(submitter);

        //mark form as submitted
        formToProcess.markFormsSubmitted();                                     
}
{code}

This solution would preserve the current behavior with not submitted forms and 
would make the overall form behavior more consistent.


was (Author: bitstorm):
I think Yoann got the point. AFAIK form submitting also includes form 
processing. If this assumption is true a possible simple fix could be moving 
markFormsSubmitted at the bottom of Form#onFormSubmitted(IFormSubmitter), after 
we have invoked formToProcess.process(submitter);

{code}
....
else
{
        // the submit request might be for one of the nested forms, so let's
        // find the right one:
        final Form<?> formToProcess = findFormToProcess(submitter);
        
        // process the form for this request
        formToProcess.process(submitter);

        //mark form as submitted
        formToProcess.markFormsSubmitted();                                     
}
{code}

> Nested forms / parent FormComponents do not reflect updated model when nested 
> form submitted
> --------------------------------------------------------------------------------------------
>
>                 Key: WICKET-6041
>                 URL: https://issues.apache.org/jira/browse/WICKET-6041
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 6.21.0, 7.1.0
>            Reporter: Patrick Davids
>            Assignee: Andrea Del Bene
>         Attachments: NonReflectingFormComponent.zip
>
>
> Hi,
> as discussed in user-list, here the ticket and quickstart attached.
> I guess the quickstart looks quite unusual, because it is reduced to its 
> minimum to show what happens.
> The use-case of such an nested form component tree is more clearer when 
> considering the usage in wizards, which holds its own form to be able to do 
> step-transitions.
> In combination with dialogs (e.g. wicket-jquery-ui / greetings to [~sebfz1] 
> by the way), which also needed a form to work, you will get such a nested 
> form situation.
> kind regards
> Patrick



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

Reply via email to