Upon further analysis, 
I was having the panel as the ModalWindow.setContent(WizardPanel) and
doesn’t seem to work in terms of multiple button clicks ie., Next/Previous.

Good news is that I tried to replace the panel with the Page using
ModelWindow.createPage(), and the wizard seems to be functional as expected
in terms of buttons.

But:

Using the Panel approach here is what I have seen by debugging the
javascript:
upon click of Next button: 
executes the wicketSubmitByFormId() 
  i.      return call.submitFormBytId(formId, sumbitButton)
  ii.      further goes to submitForm:function(form, submitButton)
  iii.      var s=Wicket.Form.serialoze(form)
  iv.      this call further goes into Wicket.Form.serialoze(form)

1.       if(element.tagName.toLowerCase == “form”)

Everthing above works fine, and Navigates to the next panel 
Now when I click on any other buttons 
It tries to execute the above four steps (but there is an error in the “iv”
step ie., the values are null, so when trying to execute the
element.tagName.toLowerCase() results in an error (null pointer) dies to
which I am seeing the annoying alert message. 
 

I guess I nailed out the problem. But not sure why this should happen
though. Looks like upon one submit action (Next/previous or any buttons) the
modalwindow gets reset to null, as such it doesn’t have the reference of the
form or its contents (everything is set to null)

Can you please help me with any information. Highly appreciate your
response.

Thanks & Best Regards,

Kuga



Kuga wrote:
> 
> Hi,
> 
> I was browsing through the wicket forums, for one of the problems I am
> having using Wicket wizard in ModalWindow.
> 
> I am iusing Wicket 1.3.4 
> 
> Wondering if anyone could help me with any possible solutions. Greatly
> appreciate you time and response.
> 
> I have changed the WizardButtons to use Ajax buttons. The following is the
> behavior:
> 
> In the wizard Ajax button I added the following:
> 
> protected void onSubmit(AjaxRequestTarget target, Form form) {
>             onClick(target);
>             target.addComponent((Wizard)wizard);
>       }
> 
> 1. I have added 3 IWizardStep to the model 
> 2. Added the wizard to a panel, and then added this panel as setContent()
> to the ModalWindow.
> 3. Lauched the modalwindow, 
>             a. Observed the right behavior (button enabled state) of the
> buttons at launch
>             b. Now Clicked on “Next” button – traverses to the next step.
>             c. Now clicked on the “Previous” button – instead of going to
> Previous – I got the annoying alert message. 
>             d. added the javascript (Wicket.windo.unloadConfirmatoin =
> false;
>             e. Adding the above scrip was just suppressing the alert
> message, and just closes the wizard window without going to the previous
> screen.
> 
> Not really sure where I am going wrong. Have been trying to Debug, but
> since the previous button doesn’t get the onClick() due to closing, could
> not even debug this issue.
> 
> Can you please let me know about your experience in solving this issue,
> and also if you feel that I am doing any mistake, please let me know.
> Thanks & Best Regards
> Kuga
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Wizard-in-Modalwindow-getting-alert-message-upon-using-the-Wizard-buttons-tp19631049p19631131.html
Sent from the Wicket - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to