<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

<link href="../css/main.css" rel="stylesheet" type="text/css" />

</head>

<body>

<?php

$_SESSION['current_page']   = "store";
include ("../navigation/header.php");
$page_name = "Stores-main";

include ("../navigation/access.php");
if ($permission_num==1) {
include ("../navigation/store_sidebar.php");
?>

<div class="main_frame">
 
  
<?php

date_default_timezone_set('Africa/Gaborone');
$entry_date = date("Y-m-d H:i:s", time());
$ip_address = $_SERVER['REMOTE_ADDR'];

$table_name = "test_tracking_log";
$track_check_query = "INSERT INTO $table_name (entry_date, user, company, page, location) VALUES ('".$entry_date."' ,'".$_SESSION['username']."','Vertex', 'sales_main.php', '".$ip_address."' )";
execsql($track_check_query);

$branch = $_GET['branch'];
$subCat = 'Tiles';

if ($branch=='') {
if ($_SESSION['userbranch'] == 'Gaborone') {
	           $branch="Gaborone";
		}
if ($_SESSION['userbranch'] == 'Francistown') {
	  				$branch="Francistown";
		}
}

if ($branch=='Gaborone') {
	   include('store_items_list_gab.php');
}
if ($branch=='Francistown') {
	   include('store_items_list_ftw.php');
}
if ($branch=='Combined') {
	   include('store_items_list_comb.php');
}

?>
</div>



<?php include ('../navigation/side_bar.php'); ?>

</body>

<?php } else {
	
$_SESSION['denied_return'] = $_SESSION['location'];	
include ("../navigation/store_sidebar.php");?>
	<body onload="accessdenied(); return false">
	</body>
<?php }
?>

</html>