diff --git a/htdocs/compta/bank/categ.php b/htdocs/compta/bank/categ.php index 81cdaa6d860..bb55c4b5de8 100644 --- a/htdocs/compta/bank/categ.php +++ b/htdocs/compta/bank/categ.php @@ -53,6 +53,23 @@ if ($_POST["action"] == 'add') } } +/* + * Action suppression catégorie + */ +if ( $_REQUEST['action'] == 'delete' ) +{ + if ( $_REQUEST['categid'] ) + { + $sql = "DELETE FROM ".MAIN_DB_PREFIX."bank_categ WHERE rowid='".$_REQUEST['categid']."'"; + $result = $db->query($sql); + + if (!$result) + { + dolibarr_print_error($db); + } + } +} + /* * Affichage liste des catégories */ @@ -80,7 +97,8 @@ if ($result) $var=!$var; print "