From 162d5d8a399d49a0cb562d5a6c21b60ada39289b Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 7 Oct 2021 10:38:10 +0200 Subject: [PATCH] Fix protection of double party accounting when using situation invoices --- htdocs/accountancy/index.php | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/htdocs/accountancy/index.php b/htdocs/accountancy/index.php index 1842c23f418..cff986c4729 100644 --- a/htdocs/accountancy/index.php +++ b/htdocs/accountancy/index.php @@ -81,7 +81,12 @@ $help_url = ''; llxHeader('', $langs->trans("AccountancyArea"), $help_url); -if ($conf->accounting->enabled) { +if (!empty($conf->global->INVOICE_USE_SITUATION) && $conf->global->INVOICE_USE_SITUATION == 1) { + print load_fiche_titre($langs->trans("AccountancyArea"), '', 'accountancy'); + + print ''.$langs->trans("SorryThisModuleIsNotCompatibleWithTheExperimentalFeatureOfSituationInvoices")."\n"; + print "
"; +} elseif ($conf->accounting->enabled) { $step = 0; $resultboxes = FormOther::getBoxesArea($user, "27"); // Load $resultboxes (selectboxlist + boxactivated + boxlista + boxlistb) @@ -258,7 +263,8 @@ if ($conf->accounting->enabled) { } else { print load_fiche_titre($langs->trans("AccountancyArea"), '', 'accountancy'); - print ''.$langs->trans("Module10Desc")."
\n"; + print ''.$langs->trans("Module10Desc")."\n"; + print "
"; } // End of page