From 6addd207af9ac31c87a999d894ff559dadda64c1 Mon Sep 17 00:00:00 2001 From: Khushboo Vashi Date: Thu, 15 Oct 2020 15:59:53 +0530 Subject: [PATCH] Ensure that macros should be run on the older version of Safari and Chrome. Fixes #5911 --- docs/en_US/release_notes.rst | 3 ++- docs/en_US/release_notes_4_28.rst | 20 +++++++++++++++++++ .../tools/sqleditor/static/js/sqleditor.js | 3 ++- 3 files changed, 24 insertions(+), 2 deletions(-) create mode 100644 docs/en_US/release_notes_4_28.rst diff --git a/docs/en_US/release_notes.rst b/docs/en_US/release_notes.rst index 706d2e06b..28610b28e 100644 --- a/docs/en_US/release_notes.rst +++ b/docs/en_US/release_notes.rst @@ -11,6 +11,7 @@ notes for it. .. toctree:: :maxdepth: 1 + release_notes_4_28 release_notes_4_27 release_notes_4_26 release_notes_4_25 @@ -54,4 +55,4 @@ notes for it. release_notes_1_3 release_notes_1_2 release_notes_1_1 - release_notes_1_0 \ No newline at end of file + release_notes_1_0 diff --git a/docs/en_US/release_notes_4_28.rst b/docs/en_US/release_notes_4_28.rst new file mode 100644 index 000000000..87c5a1ef8 --- /dev/null +++ b/docs/en_US/release_notes_4_28.rst @@ -0,0 +1,20 @@ +************ +Version 4.28 +************ + +Release date: 2020-11-12 + +This release contains a number of bug fixes and new features since the release of pgAdmin4 4.27. + +New features +************ + + +Housekeeping +************ + + +Bug fixes +********* + +| `Issue #5911 `_ - Ensure that macros should be run on the older version of Safari and Chrome. diff --git a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js index 058e21a2f..b2f22e629 100644 --- a/web/pgadmin/tools/sqleditor/static/js/sqleditor.js +++ b/web/pgadmin/tools/sqleditor/static/js/sqleditor.js @@ -2801,7 +2801,8 @@ define('tools.querytool', [ .done(function(res) { if (res) { // Replace the place holder - let query = res.sql.replaceAll('$SELECTION$', self.gridView.query_tool_obj.getSelection()); + const regex = /\$SELECTION\$/gi; + let query = res.sql.replace(regex, self.gridView.query_tool_obj.getSelection()); const executeQuery = new ExecuteQuery.ExecuteQuery(self, pgAdmin.Browser.UserManagement); executeQuery.poll = pgBrowser.override_activity_event_decorator(executeQuery.poll).bind(executeQuery);