mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Resolved an issue related to no proper valid/invalid event was
generated for the privilege control. Also, made changes in the PrivilegeRoleModel, to allow to select a grantee only once for the current user (as grantor), and omit them from other cell objects. Valid/Invalid event was not properly triggered, whenever the child attribute is a collection/model within a model (nested mode/collection within model). This patch tried to take care of all such scenarios in general.
This commit is contained in:
@@ -38,6 +38,11 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
||||
category: 'drop', priority: 5, label: '{{ _('Disconnect Server...') }}',
|
||||
icon: 'fa fa-chain-broken', enable : 'is_connected'
|
||||
}]);
|
||||
|
||||
pgBrowser.messages['PRIV_GRANTEE_NOT_SPECIFIED'] =
|
||||
'{{ _('Please select the grantee from the list!') }}';
|
||||
pgBrowser.messages['NO_PRIV_SELECTED'] =
|
||||
'{{ _('Please select at least one privilege to grant!') }}';
|
||||
},
|
||||
is_not_connected: function(node) {
|
||||
return (node && node.connected != true);
|
||||
@@ -259,7 +264,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
||||
tree.select(item);
|
||||
tree.open(item);
|
||||
}, 10);
|
||||
|
||||
|
||||
}
|
||||
};
|
||||
|
||||
@@ -348,7 +353,7 @@ function($, _, S, pgAdmin, pgBrowser, alertify) {
|
||||
return onFailure(xhr, status, error, obj, data, tree, item);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
/* Send PING to indicate that session is alive */
|
||||
function server_status(server_id)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user