Merge remote-tracking branch 'origin/develop' into ent-3013-ipam-modo-configuracion-de-vlan
Former-commit-id: 069f3fb28862a06eba76132c5e31da24ecf54b05
This commit is contained in:
commit
16ecc4efa3
|
@ -250,23 +250,32 @@ else {
|
||||||
}
|
}
|
||||||
|
|
||||||
//Removed web analysis and log4x from select
|
//Removed web analysis and log4x from select
|
||||||
$sql = sprintf ('SELECT id_tipo, descripcion
|
$sql = sprintf (
|
||||||
|
'SELECT id_tipo, descripcion, nombre
|
||||||
FROM ttipo_modulo
|
FROM ttipo_modulo
|
||||||
WHERE categoria IN (%s) AND id_tipo NOT IN (24, 25)
|
WHERE categoria IN (%s) AND id_tipo NOT IN (24, 25)
|
||||||
ORDER BY descripcion',
|
ORDER BY descripcion',
|
||||||
implode (',', $categories));
|
implode (',', $categories)
|
||||||
|
);
|
||||||
|
|
||||||
$table_simple->data[2][1] = html_print_select_from_sql ($sql, 'id_module_type',
|
|
||||||
$idModuleType, '', '', '', true, false, false, $disabledBecauseInPolicy, false, false, 100);
|
|
||||||
|
|
||||||
// Store the relation between id and name of the types on a hidden field
|
|
||||||
$type_names = db_get_all_rows_sql($sql);
|
$type_names = db_get_all_rows_sql($sql);
|
||||||
|
|
||||||
$type_names_hash = array();
|
$type_names_hash = array();
|
||||||
|
$type_description_hash = array();
|
||||||
|
if (isset($type_names) && is_array($type_names)) {
|
||||||
foreach ($type_names as $tn) {
|
foreach ($type_names as $tn) {
|
||||||
$type_names_hash[$tn['id_tipo']] = $tn['nombre'];
|
$type_names_hash[$tn['id_tipo']] = $tn['nombre'];
|
||||||
|
$type_description_hash[$tn['id_tipo']] = $tn['descripcion'];
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$table_simple->data[2][1] = html_print_select (
|
||||||
|
$type_description_hash, 'id_module_type', $idModuleType,
|
||||||
|
$disabledBecauseInPolicy, '', 0, true,
|
||||||
|
false, true, '', false, false, false, 100
|
||||||
|
);
|
||||||
|
|
||||||
|
// Store the relation between id and name of the types on a hidden field
|
||||||
$table_simple->data[2][1] .= html_print_input_hidden('type_names',base64_encode(io_json_mb_encode($type_names_hash)),true);
|
$table_simple->data[2][1] .= html_print_input_hidden('type_names',base64_encode(io_json_mb_encode($type_names_hash)),true);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -735,8 +735,11 @@ function html_print_extended_select_for_post_process($name, $selected = '',
|
||||||
$selected_float = (float)$selected;
|
$selected_float = (float)$selected;
|
||||||
$found = false;
|
$found = false;
|
||||||
|
|
||||||
if (array_key_exists(number_format($selected, 14, '.', ','), $fields))
|
if($selected){
|
||||||
|
if (array_key_exists(number_format($selected, 14, '.', ','), $fields)) {
|
||||||
$found = true;
|
$found = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (!$found) {
|
if (!$found) {
|
||||||
$fields[$selected] = floatval($selected);
|
$fields[$selected] = floatval($selected);
|
||||||
|
|
Loading…
Reference in New Issue