<?php
	require "../commonincludefiles.php";
   	$objRouteMgmt = new RouteMgmt();
	$i=0;
	$order_field=" route_id ";
	$order_type=" ASC ";
	$rs = $objRouteMgmt->getAllRecordsroute($limit,$start,$where,$order_field,$order_type);
	$total = dbRows($rs);
	$RouteData = array("count" => $total, "data" => array());
	if(dbRows($rs) > 0){
		while($row = dbArray($rs)){
			$temparray["route_id"]  = $row["route_id"];
			$temparray["route_name"]  = $row["route_name"];
			$RouteData["data"][$i] = $temparray;   
			$i++;
		}
	}
	echo json_encode($RouteData);	
?>