#10049 fix error500 edit cluster metaconsole

This commit is contained in:
Jonathan 2022-12-21 15:38:34 +01:00
parent 9881cd82fc
commit 8a68018c64
1 changed files with 2 additions and 7 deletions

View File

@ -693,13 +693,8 @@ function treeview_printTable($id_agente, $server_data=[], $no_head=false)
$cluster = PandoraFMS\Cluster::loadFromAgentId( $cluster = PandoraFMS\Cluster::loadFromAgentId(
$agent['id_agente'] $agent['id_agente']
); );
$url = 'index.php?sec=reporting&sec2='; $go_to_agent .= '<a target=_blank href="'.$console_url.'index.php?sec=reporting&sec2=operation/cluster/cluster&op=update&id='.$cluster->id().'">';
$url .= 'operation/cluster/cluster'; $go_to_agent .= html_print_submit_button(__('Go to cluster edition'), 'upd_button', false, 'class="sub config"', true);
$url = ui_get_full_url(
$url.'&op=update&id='.$cluster->id()
);
$go_to_agent .= '<a target="_blank" href="'.$url.'">';
$go_to_agent .= html_print_submit_button(__('Edit cluster'), 'upd_button', false, 'class="sub config"', true);
} else { } else {
$go_to_agent .= '<a target=_blank href="'.$console_url.'index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.$ent.'">'; $go_to_agent .= '<a target=_blank href="'.$console_url.'index.php?sec=gagente&sec2=godmode/agentes/configurar_agente&id_agente='.$id_agente.$ent.'">';
$go_to_agent .= html_print_submit_button(__('Go to agent edition'), 'upd_button', false, 'class="sub config"', true); $go_to_agent .= html_print_submit_button(__('Go to agent edition'), 'upd_button', false, 'class="sub config"', true);