Re: ModalWindow cannot trigger setWindowClosedCallback or setCloseButtonCallback problem

2019-03-07 Thread kyc
Why AjaxButton works inside the modal window ModalEditPanel but Button not
works for the Form submit?

--
Sent from: http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: ModalWindow cannot trigger setWindowClosedCallback or setCloseButtonCallback problem

2019-03-07 Thread kyc
modalEditLog.setContent(new
ModalEditPanel(modalEditLog.getContentId(), modalEditLog, result));


modalEditLog.setWindowClosedCallback(new WindowClosedCallback() 
{
private static final long serialVersionUID = 
7961678233294274184L;

public void onClose(AjaxRequestTarget target) {
doRefresh(target);
}
});


Panel ModalEditPanel is the replacement for the original WebPage
ModalEditPage and it has the close button to close the window

addOrReplace(new AjaxLink("btnClose") {
private static final long serialVersionUID = 
-8174543450190822811L;

@Override
public void onClick(AjaxRequestTarget target) {
window.close(target);
}
});


--
Sent from: http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: ModalWindow cannot trigger setWindowClosedCallback or setCloseButtonCallback problem

2019-03-07 Thread Martin Grigorov
Please share how you solved it.
Someone else may hit the same issue some day and your explicit description
will help him/her.
Just confirming "ModalWindow#setContent() solved it" is also fine.

On Thu, Mar 7, 2019 at 11:52 AM kyc  wrote:

> Solved.  Thank you.
>
> --
> Sent from:
> http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>


Re: ModalWindow cannot trigger setWindowClosedCallback or setCloseButtonCallback problem

2019-03-07 Thread kyc
Solved.  Thank you.

--
Sent from: http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html

-
To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
For additional commands, e-mail: users-h...@wicket.apache.org



Re: ModalWindow cannot trigger setWindowClosedCallback or setCloseButtonCallback problem

2019-03-07 Thread Martin Grigorov
Hi,

It seems you use ModalWindow backed by a Page, i.e. you use ModalWindow's
PageCreator.
Try with ModalWindow backed by a Panel (ModalWindow#setContent()).

On Thu, Mar 7, 2019 at 9:57 AM kyc  wrote:

> Hi Bas,
>
> Thanks for your reply.
>
> Since we are saving data in the page of Modal Page itself, it is no
> problem.
> However,  we have problem to close that modalwindow with a separate close
> button.
> Even I change the form to StatelessForm, the close button still have the
> PageExpiredException
>
> addOrReplace(new AjaxLink("btnClose") {
> private static final long serialVersionUID
> = -8174543450190822811L;
>
> @Override
> public void onClick(AjaxRequestTarget target) {
> window.close(target);
> }
> });
>
> KYC
>
>
>
>
>
> --
> Sent from:
> http://apache-wicket.1842946.n4.nabble.com/Users-forum-f1842947.html
>
> -
> To unsubscribe, e-mail: users-unsubscr...@wicket.apache.org
> For additional commands, e-mail: users-h...@wicket.apache.org
>
>