0002032: user_theme() should return default if theme does not exist
[fa-stable.git] / gl / gl_bank.php
index 67271a2d7138513c6462826b05122efeeb5bb285..b11dcd34de20367a65d500e7428027584b030206 100644 (file)
@@ -22,6 +22,7 @@ include_once($path_to_root . "/includes/data_checks.inc");
 include_once($path_to_root . "/gl/includes/ui/gl_bank_ui.inc");
 include_once($path_to_root . "/gl/includes/gl_db.inc");
 include_once($path_to_root . "/gl/includes/gl_ui.inc");
+include_once($path_to_root . "/admin/db/attachments_db.inc");
 
 $js = '';
 if ($use_popup_windows)
@@ -277,6 +278,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']);