From 87666509c1ac5a18eafc9228740ff60a8b389e4f Mon Sep 17 00:00:00 2001 From: enriquecd Date: Fri, 28 Oct 2016 13:51:12 +0200 Subject: [PATCH] New function pandora ux, let open pics from base64 image modules #90 - 2 --- pandora_console/include/ajax/module.php | 12 +++++++----- pandora_console/include/functions_ui.php | 2 +- pandora_console/mobile/operation/modules.php | 10 ++++++++-- 3 files changed, 16 insertions(+), 8 deletions(-) diff --git a/pandora_console/include/ajax/module.php b/pandora_console/include/ajax/module.php index 283a08230d..4e84b62893 100755 --- a/pandora_console/include/ajax/module.php +++ b/pandora_console/include/ajax/module.php @@ -177,7 +177,7 @@ if ($get_module_detail) { "Data" => array( "data", "modules_format_data", - "align" => "left", + "align" => "center", "width" => "230px"), ); @@ -185,14 +185,14 @@ if ($get_module_detail) { $columns["Time"] = array( "utimestamp", "modules_format_time", - "align" => "left", + "align" => "center", "width" => "50px"); } else { $columns["Timestamp"] = array( "utimestamp", "modules_format_timestamp", - "align" => "left", + "align" => "center", "width" => "50px"); } @@ -249,7 +249,7 @@ if ($get_module_detail) { foreach ($columns as $col => $attr) { if ($attr[1] != "modules_format_data") { - $data[] = $attr[1] ($row[$attr[0]]); + $data[] = date('d F Y - h:i:s A', $row['utimestamp']); } elseif (($config['command_snapshot']) && (preg_match ("/[\n]+/i", $row[$attr[0]]))) { @@ -957,8 +957,10 @@ if ($list_modules) { base64_encode($module["nombre"]))) . "&" . "refresh=" . SECONDS_10MINUTES . "&" . "draw_events=$draw_events', 'day_".$win_handle."')"; - + +if(!is_snapshot_data($module['datos'])){ $data[8] .= '' . html_print_image("images/chart_curve.png", true, array("border" => '0', "alt" => "")) . '   '; + } $server_name = ''; $data[8] .= "' . - html_print_image("images/default_list.png", true, + html_print_image("images/photo.png", true, array("border" => '0', "alt" => "", "title" => __("Snapshot view"))) . '   '; diff --git a/pandora_console/mobile/operation/modules.php b/pandora_console/mobile/operation/modules.php index 70ea40c20b..7abbbdf572 100644 --- a/pandora_console/mobile/operation/modules.php +++ b/pandora_console/mobile/operation/modules.php @@ -547,14 +547,20 @@ class Modules { $output = $sub_string; } } - + if (is_snapshot($module['datos'])){ + '' . + '' . + '' . + $output . '' . ''; + } + else{ $row[7] = $row[__('Data')] = '' . '' . '' . $output . '' . ''; - + } if (!$ajax) { if ($this->columns['agent']) { unset($row[0]);