From b54b6874640e61396cb979aa4c4a7322201022dc Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 24 Mar 2019 11:04:32 +0100 Subject: [PATCH 1/2] FIX bad check on type of expense report (mandatory status not working) --- htdocs/expensereport/card.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/htdocs/expensereport/card.php b/htdocs/expensereport/card.php index ddd1f7cd306..e9fb3dd1b43 100644 --- a/htdocs/expensereport/card.php +++ b/htdocs/expensereport/card.php @@ -1103,7 +1103,7 @@ if (empty($reshook)) $qty = GETPOST('qty','int'); if (empty($qty)) $qty=1; - if (! $fk_c_type_fees > 0) + if (! ($fk_c_type_fees > 0)) { $error++; setEventMessages($langs->trans("ErrorFieldRequired", $langs->transnoentitiesnoconv("Type")), null, 'errors'); From 2034ac61efe4296e9b4b9aacb66fa009d1202360 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sun, 24 Mar 2019 15:05:02 +0100 Subject: [PATCH 2/2] Fix phpcs --- htdocs/compta/tva/clients.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/htdocs/compta/tva/clients.php b/htdocs/compta/tva/clients.php index 7bc35607ee6..d9644d5ca23 100644 --- a/htdocs/compta/tva/clients.php +++ b/htdocs/compta/tva/clients.php @@ -378,9 +378,7 @@ if (! is_array($x_coll) || ! is_array($x_paye)) $subtot_coll_vat = 0; if ($min == 0 || ($min > 0 && $x_both[$thirdparty_id]['coll']['totalht'] > $min)) { - if (is_array($x_both[$thirdparty_id]['coll']['detail'])) { - // VAT Rate print ""; print ''; @@ -513,8 +511,8 @@ if (! is_array($x_coll) || ! is_array($x_paye)) $subtot_coll_vat += $temp_vat; $x_coll_sum += $temp_vat; } - } + // Total customers for this vat rate print ''; print '';