Skip to content
Snippets Groups Projects
Commit 290caba1 authored by Laurent Destailleur's avatar Laurent Destailleur Committed by GitHub
Browse files

Merge pull request #6413 from atm-gauthier/3.8_FIX_delete_bank_class_when_delete_bank_categ

FIX : delete bank class lines when we delete bank_categ
parents 797b68fc c01988ba
No related branches found
No related tags found
No related merge requests found
......@@ -87,6 +87,17 @@ if ($action == 'delete')
{
if (GETPOST('categid'))
{
// Delete bank class
$sql = "DELETE FROM ".MAIN_DB_PREFIX."bank_class";
$sql.= " WHERE fk_categ = '".GETPOST('categid')."'";
$result = $db->query($sql);
if (!$result)
{
dol_print_error($db);
}
// Delete bank categ
$sql = "DELETE FROM ".MAIN_DB_PREFIX."bank_categ";
$sql.= " WHERE rowid = '".GETPOST('categid')."'";
$sql.= " AND entity = ".$conf->entity;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment