Merge remote-tracking branch 'origin/ent-8321-formularios-modulos-de-tendencias-ticket-7456' into ent-3220-modulo-para-capacity-planning

This commit is contained in:
Ramon Novoa 2021-12-13 10:51:51 +01:00
commit 2673c85dc1
2 changed files with 22 additions and 2 deletions

View File

@ -1608,8 +1608,12 @@ if ($update_module || $create_module) {
}
if ($prediction_module === MODULE_PREDICTION_PLANNING) {
$custom_string_1 = get_parameter('estimation_interval', '300');
$custom_string_2 = get_parameter('estimation_type', 'estimation_calculation');
if ($custom_string_2 === 'estimation_calculation') {
$custom_string_1 = get_parameter('estimation_days', -1);
} else {
$custom_string_1 = get_parameter('estimation_interval', '300');
}
}
$active_snmp_v3 = get_parameter('active_snmp_v3');

View File

@ -192,6 +192,7 @@ push_table_simple($data, 'prediction_module');
$data = [];
$data[0] = '';
$data[1] .= '<div id="estimation_interval_row">';
$data[1] .= html_print_label(__('Future estimation'), 'estimation_interval', true).'<br/>';
$data[1] .= html_print_input(
[
@ -203,8 +204,23 @@ $data[1] .= html_print_input(
'div',
false
);
$data[1] .= '</div>';
$data[1] .= '<div id="estimation_days_row">';
$data[1] .= html_print_label(__('Limit value'), 'estimation_days', true).'<br/>';
$data[1] .= html_print_input(
[
'type' => 'number',
'return' => 'true',
'id' => 'estimation_days',
'name' => 'estimation_days',
'value' => $estimation_interval,
]
);
$data[1] .= '</div>';
$data[1] .= '<br />';
$data[1] .= html_print_label(__('Calculation type'), 'estimation_type', true).'<br/>';
$data[1] .= html_print_input(
[