mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Fixes #1150 - Disconnecting a database action should followed by
updating the menu state according to its current state.
This commit is contained in:
parent
4741992ad7
commit
db79f3ff3d
@ -144,6 +144,7 @@ function($, _, S, pgAdmin, pgBrowser, Alertify) {
|
||||
type:'DELETE',
|
||||
success: function(res) {
|
||||
if (res.success == 1) {
|
||||
var prv_i = t.parent(i);
|
||||
Alertify.success("{{ _('" + res.info + "') }}");
|
||||
t.removeIcon(i);
|
||||
data.connected = false;
|
||||
@ -151,6 +152,10 @@ function($, _, S, pgAdmin, pgBrowser, Alertify) {
|
||||
t.addIcon(i, {icon: data.icon});
|
||||
t.unload(i);
|
||||
t.setInode(i);
|
||||
setTimeout(function() {
|
||||
t.select(prv_i);
|
||||
}, 10);
|
||||
|
||||
}
|
||||
else {
|
||||
try {
|
||||
|
Loading…
Reference in New Issue
Block a user