diff --git a/pandora_console/operation/gis_maps/gis_map.php b/pandora_console/operation/gis_maps/gis_map.php new file mode 100644 index 0000000000..47527f42d7 --- /dev/null +++ b/pandora_console/operation/gis_maps/gis_map.php @@ -0,0 +1,73 @@ +width = "100%"; +$table->class = "databox data"; +$table->data = array (); +$table->head = array (); +$table->head[0] = __('Name'); +$table->head[1] = __('Group'); +$table->align = array (); +$table->align[1] = 'left'; + +$rowPair = true; +$iterator = 0; + +if ($maps !== false) { + foreach ($maps as $map) { + if (!check_acl ($config["id_user"], $map["group_id"], "IR", 0, true)) { + continue; + } + + if ($rowPair) + $table->rowclass[$iterator] = 'rowPair'; + else + $table->rowclass[$iterator] = 'rowOdd'; + $rowPair = !$rowPair; + $iterator++; + + $data = array (); + + $data[0] = '' . $map['map_name'].' '; + $data[1] = ui_print_group_icon ($map["group_id"], true); + + array_push ($table->data, $data); + } +} + +if (!empty ($table->data)) { + html_print_table ($table); +} +else { + echo '
' . __('No maps found') . '
'; +} +unset ($table); +?> diff --git a/pandora_console/operation/menu.php b/pandora_console/operation/menu.php index a4f0ea26a9..759922819b 100644 --- a/pandora_console/operation/menu.php +++ b/pandora_console/operation/menu.php @@ -192,8 +192,8 @@ if (check_acl ($config['id_user'], 0, "AR")) { $sub["gismaps"]["type"] = "direct"; $sub["gismaps"]["subtype"] = "nolink"; $sub2 = array (); - $sub2["operation/gis_maps/index"]["text"] = __("List of Gis maps"); - $sub2["operation/gis_maps/index"]["id"] = "List of Gis maps"; + $sub2["operation/gis_maps/gis_map"]["text"] = __("List of Gis maps"); + $sub2["operation/gis_maps/gis_map"]["id"] = "List of Gis maps"; $gisMaps = db_get_all_rows_in_table ('tgis_map', 'map_name'); if ($gisMaps === false) { $gisMaps = array ();