Fix button set to paid not always visible when it should.

This commit is contained in:
Laurent Destailleur 2016-12-02 14:52:38 +01:00
parent e846d74654
commit 411e82b7a3

View File

@ -1999,7 +1999,8 @@ if ($action != 'create' && $action != 'edit')
// If bank module is not used
if (($user->rights->expensereport->to_paid || empty($conf->banque->enabled)) && $object->fk_statut == 5)
{
if ((round($remaintopay) == 0 || empty($conf->banque->enabled)) && $object->paid == 0)
//if ((round($remaintopay) == 0 || empty($conf->banque->enabled)) && $object->paid == 0)
if ($object->paid == 0)
{
print '<div class="inline-block divButAction"><a class="butAction" href="' . $_SERVER["PHP_SELF"] . '?id='.$object->id.'&action=set_paid">'.$langs->trans("ClassifyPaid")."</a></div>";
}