From 6f1c649c01f81892558b233b5f8cba6988989d1e Mon Sep 17 00:00:00 2001 From: Joe Hunt Date: Tue, 15 Mar 2011 16:30:41 +0100 Subject: [PATCH] update_stock_move_pid commented out for same date. --- purchasing/includes/db/invoice_db.inc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/purchasing/includes/db/invoice_db.inc b/purchasing/includes/db/invoice_db.inc index c95e5de4..9373d888 100644 --- a/purchasing/includes/db/invoice_db.inc +++ b/purchasing/includes/db/invoice_db.inc @@ -290,9 +290,10 @@ function add_supp_invoice($supp_trans, $invoice_no=0) // do not receive as ref b "The general ledger transaction could not be added for the price variance of the inventory item"); } update_stock_move_pid(ST_CUSTDELIVERY, $entered_grn->item_code, $old_date, $date_, 0, $mat_cost); - } */ + } if (is_inventory_item($entered_grn->item_code)) update_stock_move_pid(ST_SUPPRECEIVE, $entered_grn->item_code, $old_date, $old_date, $supp_trans->supplier_id, $mat_cost); + */ //} } // ---------------------------------------------------------------------- @@ -523,12 +524,13 @@ function void_supp_invoice($type, $type_no) $mat_cost = update_average_material_cost(null, $details_row["stock_id"], $diff, -$details_row["quantity"], $old_date, true); } - $deliveries = get_deliveries_between($details_row["stock_id"], $old_date, $date_); + /*$deliveries = get_deliveries_between($details_row["stock_id"], $old_date, $date_); if ($deliveries[0] != 0) // have deliveries been done during the period? { update_stock_move_pid(ST_CUSTDELIVERY, $details_row["stock_id"], $old_date, $date_, 0, $mat_cost); } update_stock_move_pid(ST_SUPPRECEIVE, $details_row["stock_id"], $old_date, $old_date, $grn['supplier_id'], $mat_cost); + */ } } } -- 2.30.2