Hi,
PFA patch to fix the create table dialog UI related issue where NULL and
Primary key switch toggles at different speed in the grid and there was a
error message flickering while toggling the Primary key switch.
RM#2624
--
Regards,
Murtuza Zabuawala
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company
diff --git
a/web/pgadmin/browser/server_groups/servers/databases/schemas/tables/static/js/table.js
b/web/pgadmin/browser/server_groups/servers/databases/schemas/tables/static/js/table.js
index d0113e6..78ab8f3 100644
---
a/web/pgadmin/browser/server_groups/servers/databases/schemas/tables/static/js/table.js
+++
b/web/pgadmin/browser/server_groups/servers/databases/schemas/tables/static/js/table.js
@@ -593,15 +593,12 @@ define('pgadmin.node.table', [
m.destroy();
})
if (primary_key_column_coll.length == 0) {
- setTimeout(function () {
- // There will be only on primary key so remove the
first one.
- primary_key_coll.remove(primary_key_coll.first());
/* Ideally above line of code should be
"primary_key_coll.reset()".
* But our custom DataCollection (extended from
Backbone collection in datamodel.js)
* does not respond to reset event, it only supports
add, remove, change events.
* And hence no custom event listeners/validators
get called for reset event.
*/
- }, 10);
+ primary_key_coll.remove(primary_key_coll.first());
}
}
primary_key_column_coll.trigger('pgadmin:multicolumn:updated',
primary_key_column_coll);
diff --git a/web/pgadmin/static/js/backgrid.pgadmin.js
b/web/pgadmin/static/js/backgrid.pgadmin.js
index 3eda52f..b4ec198 100644
--- a/web/pgadmin/static/js/backgrid.pgadmin.js
+++ b/web/pgadmin/static/js/backgrid.pgadmin.js
@@ -487,6 +487,7 @@
column = this.column,
val = this.formatter.toRaw(this.$input.prop('checked'), model);
+ this.enterEditMode();
// on bootstrap change we also need to change model's value
model.set(column.get("name"), val);
},