From 60576955c1b52c86fdf529802f7651e0de2c11af Mon Sep 17 00:00:00 2001 From: Jean-Christophe Engel Date: Mon, 5 Jan 2026 11:42:56 +0100 Subject: [PATCH] =?UTF-8?q?Modifications=20pour=20compatibilit=C3=A9=20php?= =?UTF-8?q?8.5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- admin/_inc.php | 4 ++-- lib/Facture.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/admin/_inc.php b/admin/_inc.php index 6b5906e..f11fc22 100644 --- a/admin/_inc.php +++ b/admin/_inc.php @@ -11,7 +11,7 @@ define('CERFA', 2); define('COTIS', 3); const PATTERNS_LIST = [ - null => 'Aucun, le numéro sera à spécifier manuellement pour chaque document', + '' => 'Aucun, le numéro sera à spécifier manuellement pour chaque document', '%{type}-%{year}-%{ynumber}' => 'Type-Année-Numéro du document par année ("FACT-2021-42")', '%{year}-%{type}-%04{ynumber}' => 'Année-Type-Numéro du document par année ("2021-DEVIS-0042")', '%{t}-%{year}-%{ynumber}' => 'Type court-Année-Numéro du document par année ("F-2021-42")', @@ -52,7 +52,7 @@ $tpl->register_function('money_fac', function (array $params) if (!isset($name)) { - $name = 'prix[]'; + $name = 'prix[]'; } if (null !== $current_value && !$user) { diff --git a/lib/Facture.php b/lib/Facture.php index 1e0dd2f..d4515de 100644 --- a/lib/Facture.php +++ b/lib/Facture.php @@ -499,7 +499,7 @@ class Facture public $recu_fields = ['id', 'label', 'amount', 'date', 'expiry', 'paid', 'paid_amount']; - public function getCotis(int $user_id, int $su_id = null) + public function getCotis(int $user_id, ?int $su_id = null) { $where = 'WHERE su.id_user = ?'; if (null !== $su_id)