From 4acacc2e9ffcabb857883e2aeb13795ed466ffe9 Mon Sep 17 00:00:00 2001 From: "Laurent Destailleur (aka Eldy)" Date: Thu, 16 Jan 2025 15:19:36 +0100 Subject: [PATCH] Debug v21 - fix js warnings --- htdocs/core/class/html.form.class.php | 42 +++++++++++++-------------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/htdocs/core/class/html.form.class.php b/htdocs/core/class/html.form.class.php index a6cce4e7bfb..16ab5f8f1b9 100644 --- a/htdocs/core/class/html.form.class.php +++ b/htdocs/core/class/html.form.class.php @@ -9044,7 +9044,7 @@ class Form */ public static function selectArrayAjax($htmlname, $url, $id = '', $moreparam = '', $moreparamtourl = '', $disabled = 0, $minimumInputLength = 1, $morecss = '', $callurlonselect = 0, $placeholder = '', $acceptdelayedhtml = 0) { - global $conf, $langs; + global $conf; global $delayedhtmlcontent; // Will be used later outside of this function // TODO Use an internal dolibarr component instead of select2 @@ -9091,9 +9091,9 @@ class Form }, cache: true }, - language: select2arrayoflanguage, + language: select2arrayoflanguage || \'en\', containerCssClass: \':all:\', /* Line to add class from the original SELECT propagated to the new tag (ok with multiselect). Need full version of select2. */ + dropdownCssClass: \'' . dol_escape_js($morecss) . '\', /* Line to add class on the new