X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=manufacturing%2Fwork_order_costs.php;h=0d68a3f9db4e9413aac25c93f6a3b04bb999532b;hb=634019327c53a3e1082c90f4fcece9a97429a039;hp=a4ebdf2e6f5c0a97670cc4f5935527e68ca2570a;hpb=233ff5f66ad848a134d243cd11a215d8a2d725f8;p=fa-stable.git diff --git a/manufacturing/work_order_costs.php b/manufacturing/work_order_costs.php index a4ebdf2e..0d68a3f9 100644 --- a/manufacturing/work_order_costs.php +++ b/manufacturing/work_order_costs.php @@ -103,6 +103,7 @@ function can_process() if (isset($_POST['process']) && can_process() == true) { + begin_transaction(); add_gl_trans_std_cost(systypes::work_order(), $_POST['selected_id'], $_POST['date_'], $_POST['cr_acc'], 0, 0, $wo_cost_types[$_POST['PaymentType']], -input_num('costs'), payment_person_types::WorkOrder(), $_POST['PaymentType']); $is_bank_to = is_bank_account($_POST['cr_acc']); @@ -116,7 +117,7 @@ if (isset($_POST['process']) && can_process() == true) add_gl_trans_std_cost(systypes::work_order(), $_POST['selected_id'], $_POST['date_'], $_POST['db_acc'], $_POST['dim1'], $_POST['dim2'], $wo_cost_types[$_POST['PaymentType']], input_num('costs'), payment_person_types::WorkOrder(), $_POST['PaymentType']); - + commit_transaction(); meta_forward($_SERVER['PHP_SELF'], "AddedID=".$_POST['selected_id']); }