Fixed a bug that custom "interval values" had not been used as default
module interval (you can add custom ones at 'visual styles' configuration).
This commit is contained in:
parent
195f0628f0
commit
15ec55589c
|
@ -597,7 +597,16 @@ function html_print_extended_select_for_time ($name, $selected = '', $script = '
|
|||
global $config;
|
||||
|
||||
$fields = get_periods();
|
||||
|
||||
|
||||
if ( ! $selected ) {
|
||||
foreach( $fields as $t_key => $t_value){
|
||||
if ( $t_key != -1 ) { // -1 means 'custom'
|
||||
$selected = $t_key;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (($selected !== false) && (!isset($fields[$selected]) && $selected != 0)) {
|
||||
$fields[$selected] = human_time_description_raw($selected,true);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue