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

$page_security = 'SA_PROJECT_STATUS_VIEW';

if (!@$_GET['popup'])
    $path_to_root = "../..";
else	
    $path_to_root = "../..";

include_once($path_to_root . "/includes/session.inc");
include_once($path_to_root . "/includes/ui.inc");
include_once($path_to_root . "/projects/includes/ui/employee_project_boq_items_gantt_chart_ui.inc"); 
include_once($path_to_root . "/projects/includes/ui/boq_item_status_gantt_chart_ui.inc"); 
include_once($path_to_root . "/projects/includes/db/project_boq_item_details_view_db.inc");
include_once($path_to_root . "/projects/includes/db/project_boq_items_db.inc");
include_once($path_to_root . "/projects/includes/db/work_done_entry_details_db.inc"); 
include_once($path_to_root . "/includes/ui/ui_lists_group_companies.inc"); 
include_once($path_to_root . "/includes/db/group_companies_db.inc"); 
include_once($path_to_root . "/projects/includes/db/employee_projects_db.inc");
include_once($path_to_root . "/projects/includes/db/employee_project_work_db.inc"); 
include_once($path_to_root . "/payroll/includes/db/employees_db.inc"); 

$js = '';
$js .= get_js_open_window(900, 500);
$js .= get_js_date_picker();

page(_($help_context = "BOQ Item Status Gantt Chart"), false, false, "", $js);

simple_page_mode(true);

global $Ajax;

start_form();

start_table(TABLESTYLE_NOBORDER);
    start_row();
        group_company_employees_simple_list_cells(_("Employee:"), 'employee_code', '', null, '', true);
        date_cells("To Date:", "to_date");
        submit_cells('SearchOrders', _("Display"),'',_('Search'), 'process');
    end_row();
end_table(1);

$Ajax->activate('emp_proj_boq_item_gantt_chart');
div_start('emp_proj_boq_item_gantt_chart');
    if (isset($_POST['SearchOrders'])) {
        display_employee_project_boq_items_gantt_chart($_POST['employee_code'], $_POST['to_date']);
    }
div_end();

end_form(2);
end_page(@$_GET['popup'], false, false);

?>