diff --git a/htdocs/core/class/html.formticket.class.php b/htdocs/core/class/html.formticket.class.php
index daafa88333f..2aa2fc85966 100644
--- a/htdocs/core/class/html.formticket.class.php
+++ b/htdocs/core/class/html.formticket.class.php
@@ -697,7 +697,8 @@ class FormTicket
if ($num_rows == 1) {
return '';
}
- $stringtoprint .= ' ';
+ $stringtoprint .= ' ';
+
$levelid = 1;
while ($levelid <= $use_multilevel) {
$tabscript = array();
@@ -741,7 +742,7 @@ class FormTicket
$iselected = $groupticketchild == $obj->code ?'selected':'';
$stringtoprint .= '';
if (empty($tabscript[$groupcodefather])) {
- $tabscript[$groupcodefather] = 'if($("#'.$htmlname.($levelid > 1 ?'_child_'.$levelid-1:'').'")[0].value == "'.dol_escape_js($groupcodefather).'"){
+ $tabscript[$groupcodefather] = 'if ($("#'.$htmlname.($levelid > 1 ?'_child_'.$levelid-1:'').'")[0].value == "'.dol_escape_js($groupcodefather).'"){
$(".'.$htmlname.'_'.dol_escape_htmltag($fatherid).'_child_'.$levelid.'").show()
console.log("We show childs tickets of '.$groupcodefather.' group ticket")
}else{
@@ -756,23 +757,31 @@ class FormTicket
dol_print_error($this->db);
}
$stringtoprint .='';
+ //$stringtoprint .= ajax_combobox($htmlname.'_child_'.$levelid);
$stringtoprint .='';
}
+ $stringtoprint .= ajax_combobox($htmlname);
+
return $stringtoprint;
}
}