From 57a2ea3a5357af89088829ed74e296892eb47a12 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Wed, 8 Sep 2021 19:45:55 +0200 Subject: [PATCH] Fix sql error --- htdocs/compta/facture/card-rec.php | 2 ++ htdocs/core/class/commonobject.class.php | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/htdocs/compta/facture/card-rec.php b/htdocs/compta/facture/card-rec.php index affdd2e8991..d122c00ac07 100644 --- a/htdocs/compta/facture/card-rec.php +++ b/htdocs/compta/facture/card-rec.php @@ -1228,6 +1228,8 @@ if ($action == 'create') { } $morehtmlref .= ''; + $morehtmlright = ''; + dol_banner_tab($object, 'ref', $linkback, 1, 'title', 'none', $morehtmlref, '', 0, '', $morehtmlright); print '
'; diff --git a/htdocs/core/class/commonobject.class.php b/htdocs/core/class/commonobject.class.php index 6b741f59f20..eb6ac7e882b 100644 --- a/htdocs/core/class/commonobject.class.php +++ b/htdocs/core/class/commonobject.class.php @@ -2001,6 +2001,11 @@ abstract class CommonObject return 1; } + // For backward compatibility + if ($this->table_element == 'facture_rec' && $fieldid == 'title') { + $fieldid = 'titre'; + } + // Security on socid $socid = 0; if ($user->socid > 0) {