public inbox for [email protected]  
help / color / mirror / Atom feed
[pgAdmin][RM6417]:Query editor is not being closed if user Click on don't Save button
2+ messages / 2 participants
[nested] [flat]

* [pgAdmin][RM6417]:Query editor is not being closed if user Click on don't Save button
@ 2021-04-29 10:36  Pradip Parkale <[email protected]>
  0 siblings, 1 reply; 2+ messages in thread

From: Pradip Parkale @ 2021-04-29 10:36 UTC (permalink / raw)
  To: pgadmin-hackers

Hi Hackers,

Please find the attached patch for #6417 Query editor is not being closed
if user Click on don't Save button.



-- 
Thanks & Regards,
Pradip Parkale
Software Engineer | EnterpriseDB Corporation


Attachments:

  [application/octet-stream] RM6417.patch (1.1K, 3-RM6417.patch)
  download | inline diff:
diff --git a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js
index d44d4ea47..1ef690e55 100644
--- a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js
+++ b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js
@@ -4965,6 +4965,7 @@ define('tools.querytool', [
                 break;
               case 1: // Don't Save
                 self.close_on_save = false;
+                self.is_unsaved_data = this.is_unsaved_data;
                 $.ajax({
                   url: url_for('sqleditor._check_server_connection_status', {
                     'sid': self.url_params.sid,
@@ -4977,7 +4978,7 @@ define('tools.querytool', [
                   let response = res.data.result.server;
                   if (response) {
                     closeEvent.cancel = true;
-                    if (this.is_unsaved_data)
+                    if (self.is_unsaved_data)
                       self.ignore_on_close.unsaved_data = true;
                     else
                       self.ignore_on_close.unsaved_query = true;


^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: [pgAdmin][RM6417]:Query editor is not being closed if user Click on don't Save button
@ 2021-05-03 07:23  Akshay Joshi <[email protected]>
  parent: Pradip Parkale <[email protected]>
  0 siblings, 0 replies; 2+ messages in thread

From: Akshay Joshi @ 2021-05-03 07:23 UTC (permalink / raw)
  To: Pradip Parkale <[email protected]>; +Cc: pgadmin-hackers

Thanks, patch applied.

On Thu, Apr 29, 2021 at 4:06 PM Pradip Parkale <
[email protected]> wrote:

> Hi Hackers,
>
> Please find the attached patch for #6417 Query editor is not being closed
> if user Click on don't Save button.
>
>
>
> --
> Thanks & Regards,
> Pradip Parkale
> Software Engineer | EnterpriseDB Corporation
>


-- 
*Thanks & Regards*
*Akshay Joshi*
*pgAdmin Hacker | Principal Software Architect*
*EDB Postgres <http://edbpostgres.com>*

*Mobile: +91 976-788-8246*


^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2021-05-03 07:23 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2021-04-29 10:36 [pgAdmin][RM6417]:Query editor is not being closed if user Click on don't Save button Pradip Parkale <[email protected]>
2021-05-03 07:23 ` Akshay Joshi <[email protected]>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox