<?php
session_start(); 
  if($_SESSION['email']==""){
      header("location: index.php");
  }
?>
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>View Order | Drop Express Air Cargo Service Co LLC</title>
<!-- Stylesheets -->
<link href="../css/bootstrap.css" rel="stylesheet">
<link href="../css/color.css" rel="stylesheet">
<link href="../css/style.css" rel="stylesheet">
<link href="../css/responsive.css" rel="stylesheet">
<link rel="icon" type="image/icon" href="https://www.threebaboonstech.com/img/logo/favicon.png">
<link rel="stylesheet" type="text/css" href="https://cdn.datatables.net/1.13.7/css/jquery.dataTables.min.css">

<!-- Responsive -->
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0">
<!-- Google tag (gtag.js) -->
<script async src="https://www.googletagmanager.com/gtag/js?id=G-C7YMG1S2S3"></script>
<script>
  window.dataLayer = window.dataLayer || [];
  function gtag(){dataLayer.push(arguments);}
  gtag('js', new Date());

  gtag('config', 'G-C7YMG1S2S3');
</script>
<!-- Facebook Pixel Code -->
<script>
!function(f,b,e,v,n,t,s)
{if(f.fbq)return;n=f.fbq=function(){n.callMethod?
n.callMethod.apply(n,arguments):n.queue.push(arguments)};
if(!f._fbq)f._fbq=n;n.push=n;n.loaded=!0;n.version='2.0';
n.queue=[];t=b.createElement(e);t.async=!0;
t.src=v;s=b.getElementsByTagName(e)[0];
s.parentNode.insertBefore(t,s)}(window,document,'script',
'https://connect.facebook.net/en_US/fbevents.js');
 fbq('init', '1497195837521938'); 
fbq('track', 'PageView');
</script>
<noscript>
 <img height="1" width="1" 
src="https://www.facebook.com/tr?id=1497195837521938&ev=PageView
&noscript=1"/>
</noscript>
<!-- End Facebook Pixel Code -->
</head>

<body class="hidden-bar-wrapper">

<div class="page-wrapper">
 	
    <!-- Preloader -->
    <div class="preloader"></div>
 	
 	<!-- Main Header / Header Style Two -->
 	 <?php include('include/header.php'); ?>
    <!--End Main Header -->
	
	
	<!--Page Title-->
    <section class="page-title" style="background-image:url(../images/background/12.jpg);">
    	<div class="auto-container">
        	<h2>Record Management</h2>
			<div class="separater"></div>
        </div>
    </section>
    
    <!--Breadcrumb-->
    <div class="breadcrumb-outer">
    	<div class="auto-container">
        	<ul class="bread-crumb text-center">
            	<li><a href="../index.html">Home</a> <span>/</span></li>
                <li>Record Keeping System</li>
            </ul>
        </div>
    </div>
    <!--End Page Title-->
        
	<div class ="auto-container">
		<div class ="row clearfix">
			<div class="sec-title">
				<h3>All <span>Shipments</span></h3>
				<div class="separater"></div>
			</div>
		</div>
	</div>
			<div class="container">
				<table class="table table-striped" id="table" style="border:1px solid;">
				<thead>
					<tr>
					    <th>Actions</th>
						<th>Tracking #</th>
						<th>Sender Name</th>
						<th>Reciver Name</th>
						<th>Destination</th>
						<th>Arrival Date</th>
						<th>Shipment Location</th>
						
					</tr>
				</thead>
				<tbody>
					<?php
					include("action/config.php");
					$sql = "SELECT * FROM `shipment_datalis` WHERE `status` = '0'";
					$res = mysqli_query($con,$sql);
					
					while ($row = mysqli_fetch_assoc($res)) {
						$sender = $row['sendername'];
						$receiver = $row['receivername'];
						$destination = $row['destination'];
						$arrival = $row['arrival'];
						$c_location = $row['c_location'];
						$track_id = $row['track_id'];
						echo '
						<tr>
						<td><span><a class="action-btn p-2" href="action/delete.php?track_id='.$track_id.'"><i class="fa fa-trash"></i></a><a class="action-btn p-2" href="update-single.php?track_id='.$track_id.'" class="p-2"><i class="fa fa-pencil"></i></a><a class="action-btn p-2" href="track_details.php?track_id='.$track_id.'" class="p-2"><i class="fa fa-clock-o"></i></a></span></td>
							<td>'.$track_id.'</td>
							<td>'.$sender.'</td>
							<td>'.$receiver.'</td>
							<td>'.$destination.'</td>
							<td>'.$arrival.'</td>
							<td>'.$c_location.'</td>
							
						</tr>	
						';
					}
					?>	
				</tbody>
					<tfoot>
					<tr>
					    <th>Actions</th>
						<th>Tracking #</th>
						<th>Sender Name</th>
						<th>Reciver Name</th>
						<th>Destination</th>
						<th>Arrival Date</th>
						<th>Shipment Location</th>
						
					</tr>
				</tfoot>
			</table>
			</div>
			
	<br></br>
	<div class ="row clearfix"><div class ="auto-container"><a class ="back-to-home" href="login_success.php">Back To Home</a></div></div>

	<!--Main Footer-->
	
</div>
<!--End pagewrapper-->

<!--Scroll to top-->
<div class="scroll-to-top scroll-to-target" data-target="html"><span class="fa fa-arrow-up"></span></div>

<script src="../js/jquery.js"></script>
<script type="text/javascript" src="https://cdn.datatables.net/1.13.7/js/jquery.dataTables.min.js"></script>
<script type="text/javascript">
	  $(document).ready(function() {
    $('#table').DataTable({
        "scrollX" : true,
        "columnDefs": [
            { "width": "20%", "targets": 0 },
            { "width": "25%", "targets": 1 },
            { "width": "25%", "targets": 2 },
            { "width": "25%", "targets": 3 },
            { "width": "25%", "targets": 4 },
            { "width": "25%", "targets": 5 },
            { "width": "25%", "targets": 6 }
          ]
        });
    });
</script>
<script src="../js/popper.min.js"></script>
<script src="../js/bootstrap.min.js"></script>
<script src="../js/jquery.mCustomScrollbar.concat.min.js"></script>
<script src="../js/jquery.fancybox.js"></script>
<script src="../js/appear.js"></script>
<script src="../js/owl.js"></script>
<script src="../js/wow.js"></script>
<script src="../js/jquery-ui.js"></script>
<script src="../js/script.js"></script>
</body>
</html> 