Merge branch 'ent-6145-Mostrar-AVG-MAX-MIN-en-graficas-con-selector-individual' into 'develop'
add new options char See merge request artica/pandorafms!3471
This commit is contained in:
commit
099a0e4d67
|
@ -2122,7 +2122,7 @@ $class = 'databox filters';
|
|||
<td style="font-weight:bold;">
|
||||
<?php
|
||||
echo __('Full resolution graph (TIP)').ui_print_help_tip(
|
||||
__('This option may cause performance issues.'),
|
||||
__('TIP mode charts do not support average - maximum - minimum series, you can only enable TIP or average, maximum or minimum series'),
|
||||
true
|
||||
);
|
||||
?>
|
||||
|
|
|
@ -233,8 +233,9 @@ $table->data[] = $data;
|
|||
$table->rowclass[] = '';
|
||||
|
||||
$data = [];
|
||||
$data[0] = __('Show full scale graph (TIP)').ui_print_help_tip(
|
||||
__('This option may cause performance issues'),
|
||||
$data[0] = __('Show full scale graph (TIP)');
|
||||
$data[0] .= ui_print_help_tip(
|
||||
__('TIP mode charts do not support average - maximum - minimum series, you can only enable TIP or average, maximum or minimum series'),
|
||||
true,
|
||||
'images/tip.png',
|
||||
true
|
||||
|
|
|
@ -80,6 +80,18 @@ $label = db_get_value(
|
|||
'id_agente_modulo',
|
||||
$id
|
||||
);
|
||||
|
||||
ui_require_css_file('register', 'include/styles/', true);
|
||||
// Connection lost alert.
|
||||
$conn_title = __('Connection with server has been lost');
|
||||
$conn_text = __('Connection to the server has been lost. Please check your internet connection or contact with administrator.');
|
||||
ui_print_message_dialog(
|
||||
$conn_title,
|
||||
$conn_text,
|
||||
'connection',
|
||||
'/images/error_1.png'
|
||||
);
|
||||
|
||||
?>
|
||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
||||
|
@ -171,6 +183,11 @@ $label = db_get_value(
|
|||
$fullscale = get_parameter('fullscale', 0);
|
||||
}
|
||||
|
||||
$type_mode_graph = get_parameter_checkbox(
|
||||
'type_mode_graph',
|
||||
($fullscale === 1) ? 0 : $config['type_mode_graph']
|
||||
);
|
||||
|
||||
$time_compare = false;
|
||||
|
||||
if ($time_compare_separated) {
|
||||
|
@ -294,14 +311,8 @@ $label = db_get_value(
|
|||
true
|
||||
);
|
||||
|
||||
$table->data[3][2] = __('Show full scale graph (TIP)');
|
||||
$table->data[3][3] = html_print_checkbox_switch(
|
||||
'fullscale',
|
||||
1,
|
||||
(bool) $fullscale,
|
||||
true,
|
||||
false
|
||||
);
|
||||
$table->data[3][2] = '';
|
||||
$table->data[3][3] = '';
|
||||
|
||||
if (!modules_is_boolean($id)) {
|
||||
$table->data[4][0] = __('Zoom');
|
||||
|
@ -349,6 +360,29 @@ $label = db_get_value(
|
|||
true
|
||||
);
|
||||
|
||||
|
||||
$table->data[6][0] = __('Show AVG/MAX/MIN data series in graph');
|
||||
$table->data[6][1] = html_print_checkbox_switch(
|
||||
'type_mode_graph',
|
||||
1,
|
||||
(bool) $type_mode_graph,
|
||||
true,
|
||||
false
|
||||
);
|
||||
|
||||
$table->data[6][2] = __('Show full scale graph (TIP)');
|
||||
$table->data[6][2] .= ui_print_help_tip(
|
||||
__('TIP mode charts do not support average - maximum - minimum series, you can only enable TIP or average, maximum or minimum series'),
|
||||
true
|
||||
);
|
||||
$table->data[6][3] = html_print_checkbox_switch(
|
||||
'fullscale',
|
||||
1,
|
||||
(bool) $fullscale,
|
||||
true,
|
||||
false
|
||||
);
|
||||
|
||||
$form_table = html_print_table($table, true);
|
||||
$form_table .= '<div style="width:100%; text-align:right; margin-top: 15px;">';
|
||||
$form_table .= html_print_submit_button(
|
||||
|
@ -433,6 +467,7 @@ $label = db_get_value(
|
|||
'fullscale' => $fullscale,
|
||||
'zoom' => $zoom,
|
||||
'height' => 300,
|
||||
'type_mode_graph' => $type_mode_graph,
|
||||
];
|
||||
$output .= grafico_modulo_sparse($params);
|
||||
$output .= '<br>';
|
||||
|
@ -479,11 +514,28 @@ ui_include_time_picker(true);
|
|||
?>
|
||||
|
||||
<script>
|
||||
$('#checkbox-time_compare_separated').click(function() {
|
||||
$('#checkbox-time_compare_overlapped').removeAttr('checked');
|
||||
$(document).ready (function () {
|
||||
$('#checkbox-time_compare_separated').click(function(e) {
|
||||
if(e.target.checked === true) {
|
||||
$('#checkbox-time_compare_overlapped').prop('checked', false);
|
||||
}
|
||||
});
|
||||
$('#checkbox-time_compare_overlapped').click(function() {
|
||||
$('#checkbox-time_compare_separated').removeAttr('checked');
|
||||
$('#checkbox-time_compare_overlapped').click(function(e) {
|
||||
if(e.target.checked === true) {
|
||||
$('#checkbox-time_compare_separated').prop('checked', false);
|
||||
}
|
||||
});
|
||||
|
||||
$('#checkbox-fullscale').click(function(e) {
|
||||
if(e.target.checked === true) {
|
||||
$('#checkbox-type_mode_graph').prop('checked', false);
|
||||
}
|
||||
});
|
||||
|
||||
$('#checkbox-type_mode_graph').click(function(e) {
|
||||
if(e.target.checked === true) {
|
||||
$('#checkbox-fullscale').prop('checked', false);
|
||||
}
|
||||
});
|
||||
|
||||
// Add datepicker and timepicker
|
||||
|
@ -525,5 +577,5 @@ ui_include_time_picker(true);
|
|||
arrow.attr('src',arrow.attr('src').replace(arrow_up, arrow_down));
|
||||
}
|
||||
});
|
||||
|
||||
});
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue