<?php
/*
* date last modified 03-10-2017
* Edited by PI-Digi Logical Solutions
* HTML Files - manage_staff.html.php
* Mysql Tables - tbl_admin, tbl_purchase_partner, tbl_admin_type
*/
require_once('./classes/class.noseo_pagination.php'); # pagination class
require_once('./includes/functions.php'); # general functions

$debug = true;

if(isset($_REQUEST['p']) && $_REQUEST['p']!=''){
	$p = trim($_REQUEST['p']);
} else {
	$p = 1;
}

$pageVars = '';

//we have to find shops near to user who have product categories that in the order
if(isset($_REQUEST['tech_id']) && $_REQUEST['tech_id']!='') {
	$techId = trim($_REQUEST['tech_id']);
	$select = "SELECT * FROM `tbl_job` WHERE `technician_id` = '".$techId."' AND task_date >= CURDATE()";
	$execDetails = mysqli_query($con, $select);				
	// Using pagination class
	$pagination = new pagination_noseo($select);
	$execDetails = $pagination->createPages(10);
	$pageLnk = 'index.php?page='.$page.'&'.$pageVars;
	$pageNums = $pagination->pageNumber(5, $pageLnk);
		
} else {
	?>
	        <script language="javascript" type="text/javascript">			
				window.location='index.php?page=manage_technician';
			</script>
	 <?php
}


?>