diff --git a/pandora_console/godmode/agentes/module_manager_editor_common.php b/pandora_console/godmode/agentes/module_manager_editor_common.php
index feeba60aa9..7e9f29f2eb 100644
--- a/pandora_console/godmode/agentes/module_manager_editor_common.php
+++ b/pandora_console/godmode/agentes/module_manager_editor_common.php
@@ -1357,12 +1357,11 @@ $(document).ready (function () {
jQuery.each($("select[name='id_tag_available[]'] option:selected"), function (key, value) {
tag_name = $(value).html();
if (tag_name != ) {
- id_tag = $(value).attr('value');
- $("select[name='id_tag_selected[]']").append($("").val(id_tag).html('' + tag_name + ''));
+ $("select[name='id_tag_selected[]']").append(value);
$("#id_tag_available").find("option[value='" + id_tag + "']").remove();
$("#id_tag_selected").find("option[value='']").remove();
if($("#id_tag_available option").length == 0) {
- $("select[name='id_tag_available[]']").append($("").val('').html(''));
+ $("select[name='id_tag_available[]']").append(value);
}
}
});
@@ -1373,11 +1372,11 @@ $(document).ready (function () {
tag_name = $(value).html();
if (tag_name != ) {
id_tag = $(value).attr('value');
- $("select[name='id_tag_available[]']").append($("").val('').html(''));
+ $("select[name='id_tag_selected[]']").append(value);
}
}
});
diff --git a/pandora_console/include/functions_html.php b/pandora_console/include/functions_html.php
index e80fa6f9fd..bef78396aa 100644
--- a/pandora_console/include/functions_html.php
+++ b/pandora_console/include/functions_html.php
@@ -717,7 +717,8 @@ function html_print_select(
$message='',
$select_all=false,
$simple_multiple_options=false,
- $required=false
+ $required=false,
+ $truncate_size=false
) {
$output = "\n";
@@ -853,6 +854,18 @@ function html_print_select(
$output .= ' style="'.$option_style[$value].'"';
}
+ if ($truncate_size !== false) {
+ $output .= ' Title="'.$optlabel.'"';
+
+ $optlabel = ui_print_truncate_text(
+ $optlabel,
+ $truncate_size,
+ false,
+ true,
+ false
+ );
+ }
+
if ($optlabel === '') {
$output .= '>None';
} else {
@@ -1475,7 +1488,7 @@ function html_print_select_from_sql(
$disabled=false,
$style=false,
$size=false,
- $trucate_size=GENERIC_SIZE_TEXT,
+ $truncate_size=GENERIC_SIZE_TEXT,
$class='',
$required=false
) {
@@ -1490,13 +1503,7 @@ function html_print_select_from_sql(
foreach ($result as $row) {
$id = array_shift($row);
$value = array_shift($row);
- $fields[$id] = ui_print_truncate_text(
- $value,
- $trucate_size,
- false,
- true,
- false
- );
+ $fields[$id] = $value;
}
return html_print_select(
@@ -1523,7 +1530,8 @@ function html_print_select_from_sql(
// Simple_multiple_options.
false,
// Required.
- $required
+ $required,
+ $truncate_size
);
}