fix bad routes in services treeview

Former-commit-id: 27bfcca5a7e0f7c3929e2a1f449c0f1d318891c9
This commit is contained in:
alejandro-campos 2019-02-25 17:04:07 +01:00
parent 67e53bf7a7
commit db5d2ceee1
2 changed files with 8 additions and 5 deletions

View File

@ -161,7 +161,7 @@ class TreeService extends Tree {
$services[$service['id']]['counters'] = array('total_services'=>$service['total_services'], 'total_agents'=>$service['total_agents'], 'total_modules'=>$service['total_modules']);
$services[$service['id']]['name'] = $service['name'];
$services[$service['id']]['id'] = $service['id'];
$services[$service['id']]['serviceDetail']='http://localhost/pandora_console/index.php?sec=network&sec2=enterprise/operation/services/services&tab=service_map&id_service='.(int)$service['id'];
$services[$service['id']]['serviceDetail']='index.php?sec=network&sec2=enterprise/operation/services/services&tab=service_map&id_service='.(int)$service['id'];
}
return $services;
@ -241,7 +241,7 @@ class TreeService extends Tree {
$service_stats[$service['id']]['rootType'] = $service['rootType'];
$service_stats[$service['id']]['type'] = 'services';
$service_stats[$service['id']]['children']=array();
$service_stats[$service['id']]['serviceDetail']='http://localhost/pandora_console/index.php?sec=network&sec2=enterprise/operation/services/services&tab=service_map&id_service='.(int)$service['id'];
$service_stats[$service['id']]['serviceDetail']='index.php?sec=network&sec2=enterprise/operation/services/services&tab=service_map&id_service='.(int)$service['id'];
$service_stats[$service['id']]['counters']=array('total_services'=>$service['total_services'], 'total_agents'=>$service['total_agents'], 'total_modules'=>$service['total_modules']);
}

View File

@ -523,7 +523,8 @@ var TreeController = {
if (typeof element.eventAgent != 'undefined') {
$content.append('<form method="post" id="hiddenAgentsEventsForm-'+element.eventAgent+'" style="display: none;" action="index.php?sec=eventos&sec2=operation/events/events&refr=0&pure=&section=list&history=0"><input type="hidden" name="id_agent" value="'+element.eventAgent+'"></form>');
var $eventImage = $('<img src="images/tree_events.png" />');
var $eventImage = $('<img src="'+(controller.baseURL.length > 0 ? controller.baseURL : '')
+'images/tree_events.png" /> ');
$eventImage.addClass("agent-alerts-fired");
$eventImage
.click(function (e) {
@ -550,7 +551,8 @@ var TreeController = {
}
var $serviceDetailImage = $('<img src="images/tree_service_map.png" />');
var $serviceDetailImage = $('<img src="'+(controller.baseURL.length > 0 ? controller.baseURL : '')
+'images/tree_service_map.png" /> ');
if (typeof element.serviceDetail != 'undefined') {
@ -585,7 +587,8 @@ var TreeController = {
if (typeof element.eventModule != 'undefined') {
$content.append('<form method="post" id="hiddenModulesEventsForm-'+element.eventModule+'" style="display: none;" action="index.php?sec=eventos&sec2=operation/events/events&refr=0&pure=&section=list&history=0"><input type="hidden" name="module_search_hidden" value="'+element.eventModule+'"></form>');
var $moduleImage = $('<img src="images/tree_events.png" />');
var $moduleImage = $('<img src="'+(controller.baseURL.length > 0 ? controller.baseURL : '')
+'images/tree_events.png" /> ');
$moduleImage
.click(function (e) {
e.preventDefault();