From b618dfe286146c3c8db73de834eda60e8a12d556 Mon Sep 17 00:00:00 2001 From: Yosry Muhammad Date: Fri, 9 Aug 2019 11:45:05 +0530 Subject: [PATCH] Fix double click issue to expand the contents of a cell if the resultset was not editable. Fixes #4585 --- docs/en_US/release_notes_4_12.rst | 3 ++- web/pgadmin/tools/sqleditor/static/js/sqleditor.js | 7 +++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/en_US/release_notes_4_12.rst b/docs/en_US/release_notes_4_12.rst index b50890af0..f0410304d 100644 --- a/docs/en_US/release_notes_4_12.rst +++ b/docs/en_US/release_notes_4_12.rst @@ -46,4 +46,5 @@ Bug fixes | `Issue #4565 `_ - Fix the reverse engineered SQL for trigger functions with the WINDOW option selected. | `Issue #4578 `_ - Ensure enable trigger menu should be visible when trigger is disabled. | `Issue #4581 `_ - Ensure the comment on a Primary Key constraint can be edited under the Table node. -| `Issue #4582 `_ - Fix console error when changing kind(SQL/BATCH) for pgAgent job step. \ No newline at end of file +| `Issue #4582 `_ - Fix console error when changing kind(SQL/BATCH) for pgAgent job step. +| `Issue #4585 `_ - Fix double click issue to expand the contents of a cell if the resultset was not editable. \ No newline at end of file diff --git a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js index 4e1302d7b..0121348e9 100644 --- a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js +++ b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js @@ -713,7 +713,7 @@ define('tools.querytool', [ */ // This function is responsible to create and render the SlickGrid. - render_grid: function(collection, columns, is_editable, client_primary_key, rows_affected, is_explain_plan) { + render_grid: function(collection, columns, is_editable, client_primary_key, rows_affected) { var self = this; self.handler.numberOfModifiedCells = 0; @@ -833,7 +833,7 @@ define('tools.querytool', [ } var grid_options = { - editable: is_editable || is_explain_plan, + editable: true, enableAddRow: is_editable, enableCellNavigation: true, enableColumnReorder: false, @@ -2481,7 +2481,6 @@ define('tools.querytool', [ && data.types[0] && data.types[0].typname === 'json') { /* json is sent as text, parse it */ explain_data_json = JSON.parse(data.result[0][0]); - self.is_explain_plan = true; } if (explain_data_json && explain_data_json[0] && @@ -2497,7 +2496,7 @@ define('tools.querytool', [ function() { self.gridView.render_grid( explain_data_array, self.columns, self.can_edit, - self.client_primary_key, 0, self.is_explain_plan + self.client_primary_key, 0 ); // Make sure - the 'Explain' panel is visible, before - we // start rendering the grid.