jquery-bootstrap-scripting icon indicating copy to clipboard operation
jquery-bootstrap-scripting copied to clipboard

No Reload after (dialog2.closed)

Open kevinmeckl opened this issue 12 years ago • 4 comments

Hi,

the modal will close after the page do not reload, it is possible? the modal box will close as when I click on close.

Thank you...

kevinmeckl avatar Sep 20 '12 10:09 kevinmeckl

Could you clarify what your issue is about? A piece of code would help, too!

nikku avatar Nov 16 '12 09:11 nikku

@Nikku , what @KevinMkl is saying is that when you open the dialog and submit a form to lets say another page, then close it, the dialog content does not reload back to the original first page. Maybe there should be an option to reload original content of the dialog on dialog2.closed event.

corpulent avatar Dec 04 '12 14:12 corpulent

Yes, after a function I call dialog2.closed event, the window closes but the page is reloaded

$("#form_submit").validationEngine('attach', {
    onValidationComplete: function(form, status){
        //Check Validation
            if (status == true){
                $("#form_submit").submit_function();

                        dialog.trigger("dialog2.closed");
                        dialog.("dialog2.closed");

                       // I try several types

            }
        } 

});

kevinmeckl avatar Dec 04 '12 14:12 kevinmeckl

Still can't reproduce. If you can show me a jsfiddle then I could see, whether this is a bug.

Simple form submit won't work anyway as the form must be ajax-submitted.

nikku avatar Dec 04 '12 21:12 nikku

I have the same issue and it is indeed via Ajax.

The jsfiddle doens't work but it should give you a better view of the code http://jsfiddle.net/dragonfly4/3EQXS/

You click on "Open dialog", the form opens (view A) and you submit it. (view B) You close view B. Let's say you want to modify your data again so you click again on "open dialog" and then you get view B instead of seeing view A.

Any idea how we can reset the state of the dialog when closing it?

dragonfly4 avatar Jun 04 '13 12:06 dragonfly4