From e9d31826b7bbb2bbc18e5e5339f3bd0a4f5cb328 Mon Sep 17 00:00:00 2001 From: Maxime Bourget Date: Wed, 5 Jun 2013 22:07:37 +0100 Subject: [PATCH] Add db_prevoid --- hooks.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/hooks.php b/hooks.php index 0bf5ad1..1773852 100644 --- a/hooks.php +++ b/hooks.php @@ -92,5 +92,16 @@ class hooks_order_line_extra extends hooks { } } + + + function db_prevoid($cart, $trans_type) { + // Simple version, rebuild everything + $types = array(ST_CUSTCREDIT, ST_CUSTDELIVERY, ST_INVADJUST, ST_PURCHORDER, ST_WORKORDER, ST_MANUISSUE, + ST_SALESORDER, ST_SALESQUOTE, ST_MANURECEIVE); + if(in_array($trans_type, $types)) { + update_queue_quantities(); + update_qoh_for_item(); + } + } } ?> -- 2.30.2