include_once($path_to_root . "/admin/db/attachments_db.inc");
$js = '';
-if ($use_popup_windows)
+if ($SysPrefs->use_popup_windows)
$js .= get_js_open_window(800, 500);
-if ($use_date_picker)
+if (user_use_date_picker())
$js .= get_js_date_picker();
if (isset($_GET['NewPayment'])) {
//-----------------------------------------------------------------------------------------------
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'));
// apply exchange rate
foreach($cart->gl_items as $line_no => $line)
$cart->gl_items[$line_no]->amount *= $ex_rate;
-
+
} else {
$cart->reference = $Refs->get_next($cart->trans_type);
$cart->tran_date = new_doc_date();
}
elseif (!is_date_in_fiscalyear($_POST['date_']))
{
- display_error(_("The entered date is not in fiscal year."));
+ display_error(_("The entered date is out of fiscal year or is closed for further data entry."));
set_focus('date_');
$input_error = 1;
}
display_bank_header($_SESSION['pay_items']);
-start_table(TABLESTYLE2, "width=90%", 10);
+start_table(TABLESTYLE2, "width='90%'", 10);
start_row();
echo "<td>";
display_gl_items($_SESSION['pay_items']->trans_type==ST_BANKPAYMENT ?
end_page();
-?>