From baf08ffb019ab3d04264b2876a1c0f3e32365c29 Mon Sep 17 00:00:00 2001 From: Janusz Dobrowolski Date: Fri, 15 Dec 2017 19:14:49 +0100 Subject: [PATCH] Work Order Entry, Work Order Additional Costs: fixed input data checks. --- manufacturing/work_order_costs.php | 2 +- manufacturing/work_order_entry.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/manufacturing/work_order_costs.php b/manufacturing/work_order_costs.php index b52590f4..bd262f81 100644 --- a/manufacturing/work_order_costs.php +++ b/manufacturing/work_order_costs.php @@ -68,7 +68,7 @@ if (strlen($wo_details[0]) == 0) function can_process($wo_details) { - if (!check_num('costs', 0)) + if (input_num('costs')<=0) { display_error(_("The amount entered is not a valid number or less then zero.")); set_focus('costs'); diff --git a/manufacturing/work_order_entry.php b/manufacturing/work_order_entry.php index 6a47ad5a..aa13e8d5 100644 --- a/manufacturing/work_order_entry.php +++ b/manufacturing/work_order_entry.php @@ -133,7 +133,7 @@ function can_process() } } - if (!check_num('quantity', 0)) + if (!check_num('quantity', 1)) { display_error( _("The quantity entered is invalid or less than zero.")); set_focus('quantity'); -- 2.30.2