diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index 0ed036f1d1f..cebd49737e5 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -3388,13 +3388,19 @@ class Form while($res = $this->db->fetch_object($resql)) { + $unitLabel = $res->label; + if (! empty($langs->tab_translate['unit'.$res->code])) // check if Translation is available before + { + $unitLabel = $langs->trans('unit'.$res->code)!=$res->label?$langs->trans('unit'.$res->code):$res->label; + } + if ($selected == $res->rowid) { - $return.=''; + $return.=''; } else { - $return.=''; + $return.=''; } } $return.='';