<?php
/**********************************************************************
***********************************************************************/

$page_security = 'SA_PRINT_CHEQUES';
$path_to_root="..";

include_once($path_to_root . "/includes/session.inc");
include_once($path_to_root . "/includes/ui.inc");
include_once($path_to_root . "/gl/includes/ui/print_receipts_ui.inc");
include_once($path_to_root . "/gl/includes/db/print_receipts_db.inc");
include_once($path_to_root . "/reporting/includes/reporting.inc");

$js = "";
$js .= get_js_open_window(800, 500);
$js .= get_js_date_picker();

page(_($help_context = "Print Receipts"), false, false, "", $js);

global $Ajax;
$Ajax->activate('trans_tbl');

if (list_updated('trans_type_id')) {
    clear_print_receipts();
}

    start_form();
    
        display_print_receipts_selecting_parameters();
        
        div_start('trans_tbl');

            display_print_receipts_details($_POST['trans_type_id'], $_POST['from_date'], $_POST['to_date'], 
                                           $_POST['printed'], $_POST['filtering_receipt_no']);
       div_end();
       
    end_form(2);

end_page();

?>