Merge branch 'ent-8387-Bug-visual-al-intentar-linkar-a-un-agente-sin-permisos' into 'develop'

Ent 8387 bug visual al intentar linkar a un agente sin permisos

See merge request artica/pandorafms!4632
This commit is contained in:
vgilc 2022-01-25 10:22:42 +00:00
commit ea122aae3e
2 changed files with 20 additions and 17 deletions

View File

@ -430,6 +430,7 @@ class TreeService extends Tree
$tmp['searchChildren'] = 1; $tmp['searchChildren'] = 1;
} else { } else {
$tmp['searchChildren'] = 0; $tmp['searchChildren'] = 0;
$tmp['noAcl'] = 1;
} }
$tmp['showEventsBtn'] = 1; $tmp['showEventsBtn'] = 1;

View File

@ -1183,24 +1183,26 @@ var TreeController = {
disabled == false disabled == false
) { ) {
if (element.type == "agent" || element.type == "module") { if (element.type == "agent" || element.type == "module") {
$content if (typeof element.noAcl === "undefined") {
.click(function(e) { $content
_getTreeDetailData( .click(function(e) {
element.type, _getTreeDetailData(
element.id, element.type,
element.serverID, element.id,
function(error, data) { element.serverID,
if (error) { function(error, data) {
// console.error(error); if (error) {
} else { // console.error(error);
controller.detailRecipient } else {
.render(element.name, data) controller.detailRecipient
.open(); .render(element.name, data)
.open();
}
} }
} );
); })
}) .css("cursor", "pointer");
.css("cursor", "pointer"); }
} }
} }