<?php
define("PICKUPRECEIVING_MODULE_DIR","./modules/pickupreceiving");
define("PICKUPRECEIVING_MODULE_DIR_ADMIN","../modules/pickupreceiving");

$action = $_REQUEST['a'];
$isAdmin = stripos($_SERVER['SCRIPT_NAME'],"/admin/")===false?false:true;



if($isAdmin){
	
	
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.functions.php');
	//include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.addon.php');
	
	include_once("../connect.php");
	include_once("../session.php");

}else{
	include_once("./connect.php");
	include_once("./session.php");
	include_once(PICKUPRECEIVING_MODULE_DIR . '/pickupreceiving.functions.php');
	//include_once(PICKUPRECEIVING_MODULE_DIR . '/pickupreceiving.addon.php');
	
}

if($action == "receive"){
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.receive.php');
}
if($action == "functions"){
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.functions.php');
}
if($action == "carrierreport"){
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.carrierreport.php');
}
if($action == "carrierreport2"){
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.carrierreport2.php');
}
if($action == "verify"){
	
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.verify.php');
	
}
if($action == "waitingPickups"){
	
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.waitingPickups.php');
	
}
if($action == "rejectedReport"){
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.rejectedReport.php');	
}
if($action == "pickupsWaitingApproval"){
	include_once(PICKUPRECEIVING_MODULE_DIR_ADMIN . '/pickupreceiving.pickupsWaitingApproval.php');	
}

?>