Skip to content

Replies

0
Fragend
Fragend answered on Jun 22, 2017 2:19 PM

Hi,

Thank you for your replay. But something is not correctly placed, I think.

My script is like this :-

<script>
                                            $(function () {
                                                var width = $(window).width > 1120 ? 1100 : 1020,
                                                    height = $(window).width > 780 ? 740 : 740;
                                                $("#openDdialog_product").igButton({ labelText: "Product" });
                                                $("#dialog_product").igDialog({
                                                    state: "closed",
                                                    autoOpen: false,
                                                    modal: true,
                                                    height: height,
                                                    width: width,
                                                    headerText: "Product",
                                                    showMinimizeButton: true,
                                                    showMaximizeButton: true,
                                                    showPinButton: true,
                                                    
                                                });
                                                $("#openDdialog_product").on({
                                                    click: function (e) {
                                                        $("#dialog_product").igDialog("open");
                                                    }
                                                });
                                                $(document).delegate(".selector", "igdialogstatechanged", function (evt, ui) {
                                                    evt;

                                                    ui.closed
                                                });
                                                
                                                $(".selector").igDialog({
                                                    stateChanging : function(evt, ui) { window.location.reload(true); }
                                                });
                                            });
                                        </script>

nothing happens. But if I put it this way :-

<script>
                                            $(function () {
                                                var width = $(window).width > 1120 ? 1100 : 1020,
                                                    height = $(window).width > 780 ? 740 : 740;
                                                $("#openDdialog_produkt").igButton({ labelText: "Produkt" });
                                                $("#dialog_produkt").igDialog({
                                                    state: "closed",
                                                    autoOpen: false,
                                                    modal: true,
                                                    height: height,
                                                    width: width,
                                                    headerText: "Produkt",
                                                    showMinimizeButton: true,
                                                    showMaximizeButton: true,
                                                    showPinButton: true,
                                                    stateChanging : function(evt, ui) { window.location.reload(true); }
                                                    
                                                });
                                                $("#openDdialog_produkt").on({
                                                    click: function (e) {
                                                        $("#dialog_produkt").igDialog("open");
                                                    }
                                                });

                                            });
                                        </script>

the igDialog window closed immediately and the parent window is reloading.

Can anyone look at it and give me a hint or correct it?

Thank you very much

0
Fragend
Fragend answered on Jun 8, 2017 11:24 AM

Hello Michael H.,

Thank you very much for the reply. Let me try to answer or to give some clarity:

1. My "reload parent page function" is a page with form.

2. The igDialog is part of the parent page form. The changes made on the igDialog, should be saved in the database and displayed on the parent page, when the igDialog is closed.

3. The settings for this igDialog is "External page Loading". I have external HTML that is shown on this dialog window.

4. I have the current Version – 2016.2. Sorry I don't know.

I would like to say also, that this dialog window is really great! Great work!

Thank you for any help!

Hope hear from you soon!

Hirut