Added start time in snmp interface graphics
This commit is contained in:
parent
77ee30df20
commit
6948a2fa56
|
@ -143,6 +143,7 @@ $interface_traffic_modules = array(
|
|||
$width = (int) get_parameter("width", 555);
|
||||
$height = (int) get_parameter("height", 245);
|
||||
$start_date = (string) get_parameter("start_date", date("Y-m-d"));
|
||||
$start_time = get_parameter ("start_time", date("H:i:s"));
|
||||
$zoom = (int) get_parameter ("zoom", 1);
|
||||
$baseline = get_parameter ("baseline", 0);
|
||||
$show_percentil = get_parameter ("show_percentil", 0);
|
||||
|
@ -154,12 +155,19 @@ $interface_traffic_modules = array(
|
|||
echo "<script type='text/javascript'>window.resizeTo($width + 120, $height + 320);</script>";
|
||||
}
|
||||
|
||||
$current = date("Y-m-d");
|
||||
/*$current = date("Y-m-d");
|
||||
|
||||
if ($start_date != $current)
|
||||
$date = strtotime($start_date);
|
||||
else
|
||||
$date = $utime;
|
||||
*/
|
||||
$date = strtotime("$start_date $start_time");
|
||||
$now = time();
|
||||
|
||||
if ($date > $now){
|
||||
$date = $now;
|
||||
}
|
||||
|
||||
$urlImage = ui_get_full_url(false);
|
||||
|
||||
|
@ -230,6 +238,12 @@ $interface_traffic_modules = array(
|
|||
$table->data[] = $data;
|
||||
$table->rowclass[] = '';
|
||||
|
||||
$data = array();
|
||||
$data[0] = __('Begin time');
|
||||
$data[1] = html_print_input_text ("start_time", $start_time,'', 10, 10, true);
|
||||
$table->data[] = $data;
|
||||
$table->rowclass[] = '';
|
||||
|
||||
$data = array();
|
||||
$data[0] = __('Time range');
|
||||
$data[1] = html_print_extended_select_for_time('period', $period, '', '', 0, 7, true);
|
||||
|
@ -333,6 +347,7 @@ ui_include_time_picker(true);
|
|||
$("#text-start_date").datepicker({
|
||||
dateFormat: "<?php echo DATE_FORMAT_JS; ?>"
|
||||
});
|
||||
|
||||
$("#text-start_time").timepicker({
|
||||
showSecond: true,
|
||||
timeFormat: '<?php echo TIME_FORMAT_JS; ?>',
|
||||
|
|
Loading…
Reference in New Issue