From bf548dda3f5a383474e0f4f57544a75e35a2084a Mon Sep 17 00:00:00 2001 From: Akshay Joshi Date: Mon, 17 Jun 2019 13:27:21 +0530 Subject: [PATCH] Fix help links for backup globals and backup server. Fixes #4365 --- docs/en_US/release_notes_4_9.rst | 4 +++- .../tools/backup/static/js/backup_dialog_wrapper.js | 10 +++++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/docs/en_US/release_notes_4_9.rst b/docs/en_US/release_notes_4_9.rst index 0c0efd4a4..873c121fb 100644 --- a/docs/en_US/release_notes_4_9.rst +++ b/docs/en_US/release_notes_4_9.rst @@ -27,4 +27,6 @@ Bug fixes | `Bug #4329 `_ - Fix an initialisation error when two functions with parameters are debugged in parallel. | `Bug #4343 `_ - Fix issue where property dialog of column should open properly for EPAS v12. | `Bug #4349 `_ - Ensure strings are properly encoded in the Query History. -| `Bug #4350 `_ - Ensure we include the CSRF token when uploading files.| `Bug #4357 `_ - Fix connection restoration issue when pgAdmin server is restarted and the page is refreshed. \ No newline at end of file +| `Bug #4350 `_ - Ensure we include the CSRF token when uploading files. +| `Bug #4357 `_ - Fix connection restoration issue when pgAdmin server is restarted and the page is refreshed. +| `Bug #4365 `_ - Fix help links for backup globals and backup server. diff --git a/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js b/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js index b2e9cb3d4..4dc8faf02 100644 --- a/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js +++ b/web/pgadmin/tools/backup/static/js/backup_dialog_wrapper.js @@ -27,6 +27,14 @@ export class BackupDialogWrapper extends DialogWrapper { } setup() { + let get_help_file = function (dialog_type) { + if (dialog_type == 'globals') { + return 'backup_globals_dialog.html'; + } else if (dialog_type == 'server') { + return 'backup_server_dialog.html'; + } + return 'backup_dialog.html'; + }; return { buttons: [{ text: '', @@ -46,7 +54,7 @@ export class BackupDialogWrapper extends DialogWrapper { type: 'button', label: gettext('Backup'), url: url_for('help.static', { - 'filename': 'backup_dialog.html', + 'filename': get_help_file(this.typeOfDialog), }), }, }, {