public inbox for [email protected]  
help / color / mirror / Atom feed
From: Murtuza Zabuawala <[email protected]>
To: pgadmin-hackers <[email protected]>
Subject: PATCH: To fix column editor issue (pgAdmin4)
Date: Mon, 19 Sep 2016 15:40:33 +0530
Message-ID: <CAKKotZQhgwpCmdcTSWMcXUiEpNM1abSk_10PwvgLAGRYqMuVNA@mail.gmail.com> (raw)
List-Unsubscribe:  <mailto:[email protected]?body=unsub%20pgadmin-hackers>

Hi,

PFA patch to fix the issue in column editor where subnode control was not
expanding properly.
RM#1703/04

*Issue:*
There was issue in SecurityGroup function(used to show/hide security tab)
which was not able to find node_info property when called from subnode
control, due t which it was breaking while expanding subnode control.

--
Regards,
Murtuza Zabuawala
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


-- 
Sent via pgadmin-hackers mailing list ([email protected])
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgadmin-hackers


Attachments:

  [application/octet-stream] RM_1703_1704.patch (1.1K, 3-RM_1703_1704.patch)
  download | inline diff:
diff --git a/web/pgadmin/browser/server_groups/servers/databases/schemas/templates/schema/js/schema.js b/web/pgadmin/browser/server_groups/servers/databases/schemas/templates/schema/js/schema.js
index 76919aa..121af60 100644
--- a/web/pgadmin/browser/server_groups/servers/databases/schemas/templates/schema/js/schema.js
+++ b/web/pgadmin/browser/server_groups/servers/databases/schemas/templates/schema/js/schema.js
@@ -112,8 +112,11 @@ function($, _, S, pgAdmin, pgBrowser, Backform, alertify) {
     id: 'security', label: '{{ _("Security")  }}', type: 'group',
     // Show/Hide security group for nodes under the catalog
     visible: function(args) {
-      if (args && 'node_info' in args && 'catalog' in args.node_info) {
-        return false;
+      if (args && 'node_info' in args) {
+        // If node_info is not present in current object then it might in its
+        // parent in case if we used sub node control
+        var node_info = args.node_info || args.handler.node_info;
+        return 'catalog' in node_info ? false : true;
       }
       return true;
     }


view thread (2+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected]
  Subject: Re: PATCH: To fix column editor issue (pgAdmin4)
  In-Reply-To: <CAKKotZQhgwpCmdcTSWMcXUiEpNM1abSk_10PwvgLAGRYqMuVNA@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

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