From 395209a5dbaee724a516e2958d505deaa56212dd Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 4 Sep 2014 15:17:05 +0200 Subject: [PATCH] Fix: Reason to have button greyed is wrong Conflicts: htdocs/compta/facture/prelevement.php --- htdocs/compta/facture/prelevement.php | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/htdocs/compta/facture/prelevement.php b/htdocs/compta/facture/prelevement.php index e579bc21640..81505af34ee 100644 --- a/htdocs/compta/facture/prelevement.php +++ b/htdocs/compta/facture/prelevement.php @@ -1,7 +1,7 @@ * Copyright (C) 2004 Eric Seigne - * Copyright (C) 2004-2010 Laurent Destailleur + * Copyright (C) 2004-2014 Laurent Destailleur * Copyright (C) 2005-2012 Regis Houssin * Copyright (C) 2010 Juanjo Menent * @@ -142,7 +142,7 @@ if ($object->id > 0) /* * Facture - */ + */ print ''; $linkback = ''.$langs->trans("BackToList").''; @@ -450,7 +450,7 @@ if ($object->id > 0) /* * Buttons - */ + */ print "\n
\n"; // Add a withdraw request @@ -467,7 +467,11 @@ if ($object->id > 0) } else { - if ($num == 0) print ''.$langs->trans("MakeWithdrawRequest").''; + if ($num == 0) + { + if ($object->statut > 0) print ''.$langs->trans("MakeWithdrawRequest").''; + else print ''.$langs->trans("MakeWithdrawRequest").''; + } else print ''.$langs->trans("MakeWithdrawRequest").''; }