From e9e66f59a1ad3a07c19c8e67b896207444eda82f Mon Sep 17 00:00:00 2001 From: Janusz Dobrowolski Date: Wed, 6 Nov 2013 21:13:23 +0100 Subject: [PATCH] Payments, Deposits: fixed false error when payment is made in customer/supplier currency. --- gl/gl_bank.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/gl/gl_bank.php b/gl/gl_bank.php index 00ce0783..6d1cc226 100644 --- a/gl/gl_bank.php +++ b/gl/gl_bank.php @@ -280,7 +280,7 @@ function check_trans() if (!db_has_currency_rates(get_bank_account_currency($_POST['bank_account']), $_POST['date_'], true)) $input_error = 1; - if (in_array(get_post('PayType'), array(PT_SUPPLIER, PT_CUSTOMER)) && (input_num('settled_amount') <= 0)) { + if (isset($_POST['settled_amount']) && in_array(get_post('PayType'), array(PT_SUPPLIER, PT_CUSTOMER)) && (input_num('settled_amount') <= 0)) { display_error(_("Settled amount have to be positive number.")); set_focus('person_id'); $input_error = 1; -- 2.30.2