From: Joe Hunt Date: Fri, 19 May 2017 19:53:28 +0000 (+0200) Subject: Sales type potential bug in tax_included (persistent on) X-Git-Tag: 2.3-final~2 X-Git-Url: https://delta.frontaccounting.com/gitweb/?p=fa-stable.git;a=commitdiff_plain;h=7657fb038729a6ae3688a98ca3b18a74614dd79f Sales type potential bug in tax_included (persistent on) --- diff --git a/sales/manage/sales_types.php b/sales/manage/sales_types.php index f356b4e4..8749f221 100644 --- a/sales/manage/sales_types.php +++ b/sales/manage/sales_types.php @@ -43,7 +43,7 @@ function can_process() if ($Mode=='ADD_ITEM' && can_process()) { - add_sales_type($_POST['sales_type'], isset($_POST['tax_included']) ? 1:0, + add_sales_type($_POST['sales_type'], check_value('tax_included'), input_num('factor')); display_notification(_('New sales type has been added')); $Mode = 'RESET'; @@ -54,7 +54,7 @@ if ($Mode=='ADD_ITEM' && can_process()) if ($Mode=='UPDATE_ITEM' && can_process()) { - update_sales_type($selected_id, $_POST['sales_type'], isset($_POST['tax_included']) ? 1:0, + update_sales_type($selected_id, $_POST['sales_type'], check_value('tax_included'), input_num('factor')); display_notification(_('Selected sales type has been updated')); $Mode = 'RESET';