Fix : delete function

This commit is contained in:
Alexandre SPANGARO 2017-07-28 06:40:15 +02:00
parent fb4727c408
commit 0e86bfb6d4

View File

@ -172,7 +172,7 @@ if (empty($reshook))
if ($result >= 0) if ($result >= 0)
{ {
$db->commit(); $db->commit();
header("Location: ".DOL_URL_ROOT.'/compta/salaries/index.php'); header("Location: ".DOL_URL_ROOT.'/compta/bank/various_payment/index.php');
exit; exit;
} }
else else
@ -411,7 +411,7 @@ if ($id)
print '<div class="tabsAction">'."\n"; print '<div class="tabsAction">'."\n";
if ($object->rappro == 0) if ($object->rappro == 0)
{ {
if (! empty($user->rights->banque->delete)) if (! empty($user->rights->banque->modifier))
{ {
print '<a class="butActionDelete" href="card.php?id='.$object->id.'&action=delete">'.$langs->trans("Delete").'</a>'; print '<a class="butActionDelete" href="card.php?id='.$object->id.'&action=delete">'.$langs->trans("Delete").'</a>';
} }