From 060f7bf67ceabd6fb58ffd55c850978c7148f532 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 5 Nov 2022 15:37:59 +0100 Subject: [PATCH] Fix bad td balance --- htdocs/product/stock/card.php | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/htdocs/product/stock/card.php b/htdocs/product/stock/card.php index 02797fdbb37..74469967195 100644 --- a/htdocs/product/stock/card.php +++ b/htdocs/product/stock/card.php @@ -783,6 +783,7 @@ if ($action == 'create') { print $langs->trans("CorrectStock"); print ""; } + if (!empty($conf->global->PRODUCT_USE_UNITS)) { if ($i == 0) { $units = $productstatic->fk_unit; @@ -790,11 +791,13 @@ if ($action == 'create') { $sameunits = false; } } + print ""; $i++; } $db->free($resql); + // Total print ''.$langs->trans("Total").''; print ''; $valtoshow = price2num($totalunit, 'MS'); @@ -812,9 +815,15 @@ if ($action == 'create') { print ' '; print ''.price(price2num($totalvaluesell, 'MT')).''; } - print ' '; - print ' '; - print ' '; + + if ($user->rights->stock->mouvement->creer) { + print ' '; + } + + if ($user->rights->stock->creer) { + print ' '; + } + print ''; } else { dol_print_error($db);