From f8a4dde4f19ced6410bd19beb3318bf026a39e5a Mon Sep 17 00:00:00 2001 From: Florian HENRY Date: Tue, 30 May 2023 15:59:40 +0200 Subject: [PATCH 1/4] fix: Contract API class must return lines date --- htdocs/contrat/class/api_contracts.class.php | 5 ----- 1 file changed, 5 deletions(-) diff --git a/htdocs/contrat/class/api_contracts.class.php b/htdocs/contrat/class/api_contracts.class.php index 68ace23a26a..2becf6fcfb7 100644 --- a/htdocs/contrat/class/api_contracts.class.php +++ b/htdocs/contrat/class/api_contracts.class.php @@ -660,11 +660,6 @@ class Contracts extends DolibarrApi $object = parent::_cleanObjectDatas($object); unset($object->address); - - unset($object->date_start); - unset($object->date_start_real); - unset($object->date_end); - unset($object->date_end_real); unset($object->civility_id); return $object; From cb9eac9047186ba062679341869e59e8aa9b3519 Mon Sep 17 00:00:00 2001 From: atm-florian Date: Wed, 31 May 2023 12:13:50 +0200 Subject: [PATCH 2/4] FIX: dol_trunc may not have the desired behaviour for truncating a cryptographic initialiszation vector, for instance when MAIN_DISABLE_TRUNC is used --- htdocs/core/lib/security.lib.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/core/lib/security.lib.php b/htdocs/core/lib/security.lib.php index 97abd91d8b2..52e7a975338 100644 --- a/htdocs/core/lib/security.lib.php +++ b/htdocs/core/lib/security.lib.php @@ -152,7 +152,7 @@ function dolEncrypt($chain, $key = '', $ciphering = 'AES-256-CTR', $forceseed = if (empty($forceseed)) { $ivseed = dolGetRandomBytes($ivlen); } else { - $ivseed = dol_trunc(md5($forceseed), $ivlen, 'right', 'UTF-8', 1); + $ivseed = dol_substr(md5($forceseed), 0, $ivlen, 'ascii', 1); } $newchain = openssl_encrypt($chain, $ciphering, $key, 0, $ivseed); From 735ad3d53341886b8489aa68d078a8526dadd8fc Mon Sep 17 00:00:00 2001 From: Je2fb <46494485+Je2fb@users.noreply.github.com> Date: Wed, 31 May 2023 21:36:11 +0200 Subject: [PATCH 3/4] Update commande.class.php Change function hasdelay and showdelay to use the variable 'delivery_date' --- htdocs/commande/class/commande.class.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/htdocs/commande/class/commande.class.php b/htdocs/commande/class/commande.class.php index a37fa4575c6..6acab5152f1 100644 --- a/htdocs/commande/class/commande.class.php +++ b/htdocs/commande/class/commande.class.php @@ -4120,7 +4120,7 @@ class Commande extends CommonOrder $now = dol_now(); - return max($this->date, $this->date_livraison) < ($now - $conf->commande->client->warning_delay); + return max($this->date, $this->delivery_date) < ($now - $conf->commande->client->warning_delay); } /** @@ -4132,7 +4132,7 @@ class Commande extends CommonOrder { global $conf, $langs; - if (empty($this->date_livraison)) { + if (empty($this->delivery_date)) { $text = $langs->trans("OrderDate").' '.dol_print_date($this->date_commande, 'day'); } else { $text = $text = $langs->trans("DeliveryDate").' '.dol_print_date($this->date_livraison, 'day'); From 60b5280d853e11179eb88735dfa823dd494b5eda Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 4 Jun 2023 15:26:52 +0200 Subject: [PATCH 4/4] FIX #24918 --- htdocs/projet/tasks/task.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/htdocs/projet/tasks/task.php b/htdocs/projet/tasks/task.php index 6861a8d7926..2c375446850 100644 --- a/htdocs/projet/tasks/task.php +++ b/htdocs/projet/tasks/task.php @@ -497,9 +497,7 @@ if ($id > 0 || !empty($ref)) { // WYSIWYG editor include_once DOL_DOCUMENT_ROOT.'/core/class/doleditor.class.php'; $cked_enabled = (!empty($conf->global->FCKEDITOR_ENABLE_SOCIETE) ? $conf->global->FCKEDITOR_ENABLE_SOCIETE : 0); - if (!empty($conf->global->MAIN_INPUT_DESC_HEIGHT)) { - $nbrows = $conf->global->MAIN_INPUT_DESC_HEIGHT; - } + $nbrows = getDolGlobalInt('MAIN_INPUT_DESC_HEIGHT', 0); $doleditor = new DolEditor('description', $object->description, '', 80, 'dolibarr_details', '', false, true, $cked_enabled, $nbrows); print $doleditor->Create(); print '';