Subject: [pgAdmin4][Patch]: Collection Control Fixes

From: Khushboo Vashi <[email-masked]>
Date: Mon, 28 Mar 2016 14:52:55 +0530

Hi,

Please find attached patch to fix below issues in the Collection Control:

1> Unique Collection Control:
Couldn't listen Change event
2> Subnode Collection Control:
Add button Label was not in Upper case

First Issue was reported by Murtuza.

Thanks,
Khushboo
diff --git a/web/pgadmin/static/js/backform.pgadmin.js b/web/pgadmin/static/js/backform.pgadmin.js
index 60a93ac..e30a278 100644
--- a/web/pgadmin/static/js/backform.pgadmin.js
+++ b/web/pgadmin/static/js/backform.pgadmin.js
@@ -899,7 +899,7 @@
     },
     render: function() {
       // Clean up existing elements
-      this.cleanup();
+      this.undelegateEvents();
 
       var field = _.defaults(this.field.toJSON(), this.defaults),
           attributes = this.model.toJSON(),
@@ -945,6 +945,7 @@
       this.$el.html(grid).addClass(field.name);
       this.updateInvalid();
 
+      this.delegateEvents();
       return this;
     },
     showGridControl: function(data) {
@@ -1169,7 +1170,7 @@
     showGridControl: function(data) {
       var gridHeader = ["<div class='subnode-header'>",
           "  <label class='control-label col-sm-4'>" + data.label + "</label>" ,
-          "  <button class='btn-sm btn-default add'>Add</buttton>",
+          "  <button class='btn-sm btn-default add'>ADD</buttton>",
           "</div>"].join("\n");
         gridBody = $("<div class='pgadmin-control-group backgrid form-group col-xs-12 object subnode'></div>").append(gridHeader);

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

---

From: Ashesh Vashi <[email-masked]>
Date: Fri, 1 Apr 2016 15:27:22 +0530

Thanks - committed!

--

Thanks & Regards,

Ashesh Vashi
EnterpriseDB INDIA: Enterprise PostgreSQL Company
<http://www.enterprisedb.com>

*http://www.linkedin.com/in/asheshvashi*
<http://www.linkedin.com/in/asheshvashi>