X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=gl%2Fgl_bank.php;h=8c8860d0c47dbf405d7521eb43b8b2033d029571;hb=3f3cfa578adbc2b71f4fd9c8d0f5536d26af43d8;hp=3c8897c4299ddb11fae598939d679cead4f6651c;hpb=825a4b279d6af05322188299f6a3967d2562f1e9;p=fa-stable.git diff --git a/gl/gl_bank.php b/gl/gl_bank.php index 3c8897c4..8c8860d0 100644 --- a/gl/gl_bank.php +++ b/gl/gl_bank.php @@ -48,6 +48,9 @@ page($_SESSION['page_title'], false, false, '', $js); //----------------------------------------------------------------------------------------------- check_db_has_bank_accounts(_("There are no bank accounts defined in the system.")); +if (isset($_GET['ModifyDeposit']) || isset($_GET['ModifyPayment'])) + check_is_editable($_SESSION['pay_items']->trans_type, $_SESSION['pay_items']->order_id); + //---------------------------------------------------------------------------------------- if (list_updated('PersonDetailID')) { $br = get_branch(get_post('PersonDetailID')); @@ -144,8 +147,6 @@ function create_cart($type, $trans_no) unset ($_SESSION['pay_items']); } - check_is_closed($type, $trans_no); - $cart = new items_cart($type); $cart->order_id = $trans_no; @@ -280,6 +281,8 @@ if (isset($_POST['Process'])) set_focus('person_id'); $input_error = 1; } + if (!db_has_currency_rates(get_bank_account_currency($_POST['bank_account']), $_POST['date_'], true)) + $input_error = 1; if ($input_error == 1) unset($_POST['Process']);