X-Git-Url: https://delta.frontaccounting.com/gitweb/?a=blobdiff_plain;f=admin%2Ffiscalyears.php;h=62f8f6a28f30c63f65efbb47937419efdf69cadd;hb=b32d16b2c0c6c43e569ebe87e2a13ceb892b5788;hp=3701369a1a5304dcc30d810f660624539915e037;hpb=da8311619dd73feae101d246a1957b972e00cbd2;p=fa-stable.git diff --git a/admin/fiscalyears.php b/admin/fiscalyears.php index 3701369a..62f8f6a2 100644 --- a/admin/fiscalyears.php +++ b/admin/fiscalyears.php @@ -4,11 +4,13 @@ $page_security = 9; $path_to_root=".."; include_once($path_to_root . "/includes/session.inc"); -page(_("Fiscal Years")); - include_once($path_to_root . "/includes/date_functions.inc"); include_once($path_to_root . "/admin/db/company_db.inc"); include_once($path_to_root . "/includes/ui.inc"); +$js = ""; +if ($use_date_picker) + $js .= get_js_date_picker(); +page(_("Fiscal Years"), false, false, "", $js); //--------------------------------------------------------------------------------------------- @@ -34,16 +36,19 @@ function check_data() if (!is_date($from)) { display_error( _("Invalid BEGIN date in fiscal year.")); + set_focus('from_date'); return false; } if (!is_date($_POST['to_date'])) { display_error( _("Invalid END date in fiscal year.")); + set_focus('to_date'); return false; } if (date1_greater_date2($from, $_POST['to_date'])) { display_error( _("BEGIN date bigger than END date.")); + set_focus('from_date'); return false; } return true; @@ -178,8 +183,8 @@ function display_fiscalyear_edit($selected_id) } else { - text_row(_("Fiscal Year Begin:"), 'from_date', null, 15, 10); - text_row(_("Fiscal Year End:"), 'to_date', null, 15, 10); + date_row(_("Fiscal Year Begin:"), 'from_date', '', null, 0, 0, 1001); + date_row(_("Fiscal Year End:"), 'to_date', '', null, 0, 0, 1001); } yesno_list_row(_("Is Closed:"), 'closed', null, "", "", false);