mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
1) Fixed an issue where shortcut keys are not working with manage macro. Fixes #5908
2) Fixed an issue where the cursor shifts its focus to the wrong window for all the query tool related model dialogs. Fixes #6161
This commit is contained in:
parent
1f4affcb1e
commit
49095ccba6
@ -19,8 +19,10 @@ Bug fixes
|
|||||||
*********
|
*********
|
||||||
|
|
||||||
| `Issue #5519 <https://redmine.postgresql.org/issues/5519>`_ - Ensure that the query tool tab should be closed after server disconnection when auto-commit/auto-rollback is set to false.
|
| `Issue #5519 <https://redmine.postgresql.org/issues/5519>`_ - Ensure that the query tool tab should be closed after server disconnection when auto-commit/auto-rollback is set to false.
|
||||||
|
| `Issue #5908 <https://redmine.postgresql.org/issues/5908>`_ - Fixed an issue where shortcut keys are not working with manage macro.
|
||||||
| `Issue #6076 <https://redmine.postgresql.org/issues/6076>`_ - Fixed an issue where correct error not thrown while importing servers and JSON file has incorrect/insufficient keys.
|
| `Issue #6076 <https://redmine.postgresql.org/issues/6076>`_ - Fixed an issue where correct error not thrown while importing servers and JSON file has incorrect/insufficient keys.
|
||||||
| `Issue #6082 <https://redmine.postgresql.org/issues/6082>`_ - Ensure that the user should not be to change the connection when a long query is running.
|
| `Issue #6082 <https://redmine.postgresql.org/issues/6082>`_ - Ensure that the user should not be to change the connection when a long query is running.
|
||||||
|
| `Issue #6161 <https://redmine.postgresql.org/issues/6161>`_ - Fixed an issue where the cursor shifts its focus to the wrong window for all the query tool related model dialogs.
|
||||||
| `Issue #6220 <https://redmine.postgresql.org/issues/6220>`_ - Corrected the syntax for 'CREATE TRIGGER', use 'EXECUTE FUNCTION' instead of 'EXECUTE PROCEDURE' from v11 onwards.
|
| `Issue #6220 <https://redmine.postgresql.org/issues/6220>`_ - Corrected the syntax for 'CREATE TRIGGER', use 'EXECUTE FUNCTION' instead of 'EXECUTE PROCEDURE' from v11 onwards.
|
||||||
| `Issue #6274 <https://redmine.postgresql.org/issues/6274>`_ - Ensure that the strings in the LDAP auth module are translatable.
|
| `Issue #6274 <https://redmine.postgresql.org/issues/6274>`_ - Ensure that the strings in the LDAP auth module are translatable.
|
||||||
| `Issue #6293 <https://redmine.postgresql.org/issues/6293>`_ - Fixed an issue where the procedure creation is failed when providing the Volatility option.
|
| `Issue #6293 <https://redmine.postgresql.org/issues/6293>`_ - Fixed an issue where the procedure creation is failed when providing the Volatility option.
|
||||||
|
@ -191,4 +191,4 @@ module.exports = Alertify.dialog('createModeDlg', function() {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
}, true, 'fileSelectionDlg');
|
}, false, 'fileSelectionDlg');
|
||||||
|
@ -63,6 +63,17 @@ let MacroDialog = {
|
|||||||
className: 'btn btn-primary fa fa-save pg-alertify-button',
|
className: 'btn btn-primary fa fa-save pg-alertify-button',
|
||||||
'data-btn-name': 'ok',
|
'data-btn-name': 'ok',
|
||||||
}],
|
}],
|
||||||
|
focus: {
|
||||||
|
element: function(){
|
||||||
|
/*
|
||||||
|
returning false will focus nothing, but it will make
|
||||||
|
contents behind the modal accessible via Tab key,
|
||||||
|
so focus the dialog itself instead.
|
||||||
|
*/
|
||||||
|
return $(this.elements.dialog).find('.header-icon-cell button')[0];
|
||||||
|
},
|
||||||
|
select: true,
|
||||||
|
},
|
||||||
// Set options for dialog
|
// Set options for dialog
|
||||||
options: {
|
options: {
|
||||||
title: title,
|
title: title,
|
||||||
|
@ -82,6 +82,17 @@ let NewConnectionDialog = {
|
|||||||
'data-btn-name': 'ok',
|
'data-btn-name': 'ok',
|
||||||
},
|
},
|
||||||
],
|
],
|
||||||
|
focus: {
|
||||||
|
element: function(){
|
||||||
|
/*
|
||||||
|
returning false will focus nothing, but it will make
|
||||||
|
contents behind the modal accessible via Tab key,
|
||||||
|
so focus the dialog itself instead.
|
||||||
|
*/
|
||||||
|
return $(this.elements.dialog).find('.new-connection-dialog .nav-link.active.show');
|
||||||
|
},
|
||||||
|
select: true,
|
||||||
|
},
|
||||||
// Set options for dialog
|
// Set options for dialog
|
||||||
options: {
|
options: {
|
||||||
title: title,
|
title: title,
|
||||||
|
@ -8,8 +8,8 @@
|
|||||||
//////////////////////////////////////////////////////////////////////////
|
//////////////////////////////////////////////////////////////////////////
|
||||||
// This file contains common utilities functions used in sqleditor modules
|
// This file contains common utilities functions used in sqleditor modules
|
||||||
|
|
||||||
define(['jquery', 'underscore', 'sources/gettext', 'sources/url_for'],
|
define(['jquery', 'underscore', 'sources/gettext', 'sources/url_for', 'pgadmin.alertifyjs'],
|
||||||
function ($, _, gettext, url_for) {
|
function ($, _, gettext, url_for, alertify) {
|
||||||
var sqlEditorUtils = {
|
var sqlEditorUtils = {
|
||||||
/* Reference link http://stackoverflow.com/questions/105034/create-guid-uuid-in-javascript
|
/* Reference link http://stackoverflow.com/questions/105034/create-guid-uuid-in-javascript
|
||||||
* Modified as per requirement.
|
* Modified as per requirement.
|
||||||
@ -236,6 +236,23 @@ define(['jquery', 'underscore', 'sources/gettext', 'sources/url_for'],
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
isModalOpen: function(dialog_list) {
|
||||||
|
/* check the modals inside the sqleditor are open or not */
|
||||||
|
if(Array.isArray(dialog_list)) {
|
||||||
|
for(let d of dialog_list) {
|
||||||
|
try {
|
||||||
|
if(alertify.dialog(d) && alertify.dialog(d).isOpen())
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
catch (err) {
|
||||||
|
// Do nothing
|
||||||
|
console.warn(err.stack || err);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return false;
|
||||||
|
},
|
||||||
};
|
};
|
||||||
return sqlEditorUtils;
|
return sqlEditorUtils;
|
||||||
});
|
});
|
||||||
|
@ -506,13 +506,23 @@ define('tools.querytool', [
|
|||||||
transId = self.handler.transId;
|
transId = self.handler.transId;
|
||||||
|
|
||||||
if (!$container.hasClass('wcPanelTabContentHidden')) {
|
if (!$container.hasClass('wcPanelTabContentHidden')) {
|
||||||
setTimeout(function () {
|
|
||||||
self.handler.gridView.query_tool_obj.focus();
|
let modal_list = ['fileSelectionDlg', 'createModeDlg',
|
||||||
}, 200);
|
'confirm', 'alert', 'confirmSave', 'newConnectionDialog',
|
||||||
// Trigger an event to update connection status flag
|
'macroDialog'];
|
||||||
pgBrowser.Events.trigger(
|
|
||||||
'pgadmin:query_tool:panel:gain_focus:' + transId
|
/* check the modals inside the sqleditor are open, if not,
|
||||||
);
|
focus on the editor instead. */
|
||||||
|
if(!SqlEditorUtils.isModalOpen(modal_list)) {
|
||||||
|
setTimeout(function () {
|
||||||
|
self.handler.gridView.query_tool_obj.focus();
|
||||||
|
}, 200);
|
||||||
|
|
||||||
|
// Trigger an event to update connection status flag
|
||||||
|
pgBrowser.Events.trigger(
|
||||||
|
'pgadmin:query_tool:panel:gain_focus:' + transId
|
||||||
|
);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user