mirror of
https://github.com/pandorafms/pandorafms.git
synced 2025-07-28 00:04:37 +02:00
Fixed the link of edit module in Metaconsole
This commit is contained in:
parent
299b6f6a31
commit
07f62cc3e6
@ -844,7 +844,7 @@ else {
|
||||
|
||||
$result = array();
|
||||
$count_modules = 0;
|
||||
foreach($servers as $server) {
|
||||
foreach ($servers as $server) {
|
||||
// If connection was good then retrieve all data server
|
||||
if (metaconsole_connect($server) == NOERR) {
|
||||
$connection = true;
|
||||
@ -1068,18 +1068,39 @@ foreach ($result as $row) {
|
||||
}
|
||||
|
||||
$data[2] = html_print_image("images/" . modules_show_icon_type ($row["module_type"]), true);
|
||||
if (check_acl ($config['id_user'], $row['id_group'], "AW"))
|
||||
$data[2] .= '<a href="' .
|
||||
'index.php?' .
|
||||
if (check_acl ($config['id_user'], $row['id_group'], "AW")) {
|
||||
$show_edit_icon = true;
|
||||
if (defined('METACONSOLE')) {
|
||||
if (!can_user_access_node ()) {
|
||||
$show_edit_icon = false;
|
||||
}
|
||||
|
||||
$url_edit_module = $row["server_url"] . 'index.php?' .
|
||||
'sec=gagente&' .
|
||||
'sec2=godmode/agentes/configurar_agente&' .
|
||||
'id_agente=' . $row['id_agent'] . '&' .
|
||||
'tab=module&' .
|
||||
'id_agent_module=' . $row["id_agente_modulo"] . '&' .
|
||||
'edit_module=1">' .
|
||||
'edit_module=1' .
|
||||
'&loginhash=auto&loginhash_data=' . $row["hashdata"] . '&loginhash_user=' . $row["user"];
|
||||
}
|
||||
else {
|
||||
$url_edit_module = 'index.php?' .
|
||||
'sec=gagente&' .
|
||||
'sec2=godmode/agentes/configurar_agente&' .
|
||||
'id_agente=' . $row['id_agent'] . '&' .
|
||||
'tab=module&' .
|
||||
'id_agent_module=' . $row["id_agente_modulo"] . '&' .
|
||||
'edit_module=1';
|
||||
}
|
||||
|
||||
if ($show_edit_icon) {
|
||||
$data[2] .= '<a href="' . $url_edit_module . '">' .
|
||||
html_print_image("images/config.png", true,
|
||||
array("alt" => '0', "border" => "", "title" => __('Edit'))) .
|
||||
'</a>';
|
||||
'</a>';
|
||||
}
|
||||
}
|
||||
|
||||
$data[3] = ui_print_truncate_text($row["module_name"], 'agent_small', false, true, true);
|
||||
if ($row["extended_info"] != "") {
|
||||
|
Loading…
x
Reference in New Issue
Block a user