diff --git a/htdocs/takepos/invoice.php b/htdocs/takepos/invoice.php index cfde72c9fd3..350299814ec 100644 --- a/htdocs/takepos/invoice.php +++ b/htdocs/takepos/invoice.php @@ -398,6 +398,7 @@ if ($action == "deleteline") { $invoice->deleteline($deletelineid); $invoice->fetch($placeid); } + if (count($invoice->lines)==0) $invoice->delete($user); } if ($action == "delete") {