ok
Direktori : /home2/selectio/public_html/lilyexpresslive/ |
Current File : /home2/selectio/public_html/lilyexpresslive/tracking.php |
<?php include "header.php"; include 'db.php'; if(isset($_REQUEST['track_id'])){ $track_id=$_REQUEST['track_id']; }else{ $track_id=''; } $track_id=preg_replace('/\s+/', '', $track_id); $t_id=explode(",",$track_id); $rowcount_awb=0; // $type=$_POST['type']; $type='awb';?> <style> .process-style-05 .icon { background-color: #a5893c !important; border:7px solid red; } </style> <style> .process-style-05 .icon{ background-color: green; } .process-style-05 .icon:before{ background: none; } </style> <style> .opacity-08 { opacity: -0.2; } .ftr-nw-ltr { padding-top:0px; } /*.track .step.active .icon { width: 45%; height: 73px; top: -66%; border: 7px solid green; }*/ .track .icon { width: 45% !important; height: 73px !important; line-height: 40px !important; position: relative !important; border-radius: 100% !important; /* background: #ddd; */ top: -63% !important; border: 7px solid #ffbd00; } </style> <style> #customers { font-size: 17px; border-collapse: collapse; width: 100%; color: black; font-family: math; } #customers td, #customers th { padding: 8px; } /*#customers tr:nth-child(even){background-color: #f2f2f2;} #customers tr:hover {background-color: #ddd;}*/ #customers th { padding-top: 12px; padding-bottom: 12px; text-align: center; background-color:white; color: black; } #shipment-histry { font-size: 17px; border-collapse: collapse; width: 100%; color: black; font-family: math; } #shipment-histry td, #shipment-histry th { padding: 8px; } /*#customers tr:nth-child(even){background-color: #f2f2f2;} #customers tr:hover {background-color: #ddd;}*/ #shipment-histry th { padding-top: 12px; padding-bottom: 12px; text-align: center; background-color:white; color: black; } .card-body { padding: 3rem 3rem; } </style> <style> @import url('https://fonts.googleapis.com/css?family=Open+Sans&display=swap');.card{position: relative;display: -webkit-box;display: -ms-flexbox;display: flex;-webkit-box-orient: vertical;-webkit-box-direction: normal;-ms-flex-direction: column;flex-direction: column;min-width: 0;word-wrap: break-word;background-color: #fff;background-clip: border-box;border: 1px solid rgba(0, 0, 0, 0.1);border-radius: 0.10rem}.card-header:first-child{border-radius: calc(0.37rem - 1px) calc(0.37rem - 1px) 0 0}.card-header{padding: 0.75rem 1.25rem;margin-bottom: 0;background-color: #fff;border-bottom: 1px solid rgba(0, 0, 0, 0.1)}.track{position: relative;background-color: #ddd;height: 7px;display: -webkit-box;display: -ms-flexbox;display: flex;margin-bottom: 60px;margin-top: 50px}.track .step{-webkit-box-flex: 1;-ms-flex-positive: 1;flex-grow: 1;width: 25%;margin-top: -18px;text-align: center;position: relative}.track .step.active:before{background: #FF5722}.track .step::before{height: 7px;position: absolute;content: "";width: 100%;left: 0;top: 18px}.track .step.active .icon{background: #ee5435;color: #fff}.track .icon{display: inline-block;width: 40px;height: 40px;line-height: 40px;position: relative;border-radius: 100%;background: #ddd}.track .step.active .text{font-weight: 400;color: #000}.track .text{display: block;margin-top: 7px}.itemside{position: relative;display: -webkit-box;display: -ms-flexbox;display: flex;width: 100%}.itemside .aside{position: relative;-ms-flex-negative: 0;flex-shrink: 0}.img-sm{width: 80px;height: 80px;padding: 7px}ul.row, ul.row-sm{list-style: none;padding: 0}.itemside .info{padding-left: 15px;padding-right: 7px}.itemside .title{display: block;margin-bottom: 5px;color: #212529}p{margin-top: 0;margin-bottom: 1rem}.btn-warning{color: #ffffff;background-color: #ee5435;border-color: #ee5435;border-radius: 1px}.btn-warning:hover{color: #ffffff;background-color: #ff2b00;border-color: #ff2b00;border-radius: 1px} </style> <!-- PAGE TITLE --> <section class="page-title-section bg-img cover-background top-position1 left-overlay-dark" data-overlay-dark="9" data-background="img/abt-bg-1.jpg"> <div class="container"> <div class="row"> <div class="col-md-12"> <h1>Tracking</h1> <ul class="list-unstyled"> <li><a href="index.php">Home</a></li> <li><a href="#!">Tracking</a></li> </ul> </div> </div> </div> </section> <!-- NEWS LETTER SECTION START --> <div class="ftr-nw-ltr site-bg-white" id="trackingid"> <div class="ftr-nw-ltr-inner site-bg-primary"> <div class="container" > <!-- <div class="ftr-nw-img"> <img src="images/news-l-bg.png" alt=""> </div>--> <div class="row"> <div class="col-md-12" style="text-align:center;"> <div class="ftr-nw-title" style="font-size: 31px;color: #0b2f44;font-weight: 600;">Real Time Tracking</div> </div> </div><br> <div class="row"> <div class="col-md-12"> <div class="ftr-nw-form"> <form action="#"> <div class="row"> <div class="col-md-3"></div> <div class="col-md-6"> <input name="track_id" class="form-control" placeholder="Your Tracking ID Now" type="text" value="<?=$track_id?>"><br> <button type="submit" class="ftr-nw-subcribe-btn" style="font-size: 22px;color: #fff;background-color: #0b2f44;border: none;font-weight: 600;padding: 9px 30px;margin-left:222px;">Track</button> </div> <div class="col-md-3"></div> </div> </form> </div> </div> </div> <!-- <div class="ftr-nw-content"> <div class="ftr-nw-form"> </div> </div>--> </div> </div> </div> <!-- NEWS LETTER SECTION END --> <br><br> <?php if($track_id!==''){ foreach ($t_id as $trck_id){ $Get_pk="SELECT pickup_entry.*,tbl_customer.cust_name as cname,tbl_customer.destination_city as dest FROM `pickup_entry` INNER join tbl_customer on pickup_entry.ref_no='$trck_id' and tbl_customer.cust_id=pickup_entry.customer_id"; $result = mysqli_query($conn,$Get_pk); error_log("Query:".$Get_pk); $rowcount = mysqli_num_rows($result); $rowcount_awb=$rowcount; foreach ($result as $row) { $mani_fest=$row['manifest_id']; $customer_id=$row['customer_id']; $pick_id=$row['id']; $statement="SELECT * FROM tbl_tracking where pickup_entry_id='$pick_id'"; $status_alls = mysqli_query($conn,$statement); $rowcount=mysqli_num_rows($status_alls); foreach ($status_alls as $row1) { $stat= $row1['status']; switch ($stat) { case "pending": $rowcount=0; break; case "picked": $rowcount=1; break; case "In Transit": $rowcount=2; break; case "Received at destination": $rowcount=3; break; case "Out for delivery": $rowcount=4; break; case "Delivered": $rowcount=5; break; case "manifest": $rowcount=2; break; case "Undelivery": $rowcount=6; break; case "Return To Origin": $rowcount=7; break; default: $rowcount =0; } } ?> <!-- PROCESS ================================================== --> <!--<section class="pt-0" style="padding-top: 3% !important;"> <div class="container"> <div class="heading-style01 mb-1-9 mb-xl-7 text-center" style="padding-bottom: 5%;"> <h2 class="display-5">Tracking</h2> </div> <div class="row" hidden> <div class="process-arrow position-relative w-100 d-inline-block align-middle"> <div class="process-bg-line"></div> <div class="row mt-n1-9"> <div class="col-sm-6 col-lg-2 mt-1-9"> <div class="process-style-05"> <div class="icon" <?php if(0<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-03.png" alt="..." class="w-60px" style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 01</span> <h5>SOFT DATA UPLOAD</h5> </div> </div> </div> <div class="col-sm-6 col-lg-2 mt-1-9" style="margin-top: 9%;"> <div class="process-style-05"> <div class="icon" <?php if(1<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-06.png" alt="..." class="mb-1-9 mb-xl-5" style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 02</span> <h5>PICKED</h5> </div> </div> </div> <div class="col-sm-6 col-lg-2 mt-1-9"> <div class="process-style-05"> <div class="icon" <?php if(2<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-05.png" alt="..." class="mb-1-9 mb-xl-5" style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 03</span> <h5>FORWARDED TO DESTINATION</h5> </div> </div> </div> <div class="col-sm-6 col-lg-2 mt-1-9" style="margin-top: -2%;"> <div class="process-style-05"> <div class="icon" <?php if(3<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-02.png" class="w-50px" alt="..." style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 04</span> <h5>RECEIVED AT DESTINATION</h5> </div> </div> </div> <div class="col-sm-6 col-lg-2 mt-1-9" style="margin-top: 7%;"> <div class="process-style-05"> <div class="icon" <?php if(4<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-01.png" class="w-50px" alt="..." style="margin-top: 30%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 05</span> <h5>OUT FOR DELIVERY</h5> </div> </div> </div> <?php if(5==$rowcount){ ?> <div class="col-sm-6 col-lg-2 mt-1-9"> <div class="process-style-05"> <div class="icon" <?php if(5<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-02.png" class="w-50px" alt="..." style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 06</span> <h5>DELIVERED</h5> </div> </div> </div> <?php } ?> <?php if(6==$rowcount){ ?> <div class="col-sm-6 col-lg-2 mt-1-9"> <div class="process-style-05"> <div class="icon" <?php if(5<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-02.png" class="w-50px" alt="..." style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 06</span> <h5>DELIVERED</h5> </div> </div> </div> <?php } ?> <?php if(6==$rowcount){ ?> <div class="col-sm-6 col-lg-2 mt-1-9"> <div class="process-style-05"> <div class="icon" <?php if(5<=$rowcount){ echo'style="border: 7px solid green;"';} ?>> <img src="img/icons/service-icon-02.png" class="w-50px" alt="..." style="margin-top: 20%;height: 55px;"> </div> <div class="process-contnet"> <span>Step 06</span> <h5>DELIVERED</h5> </div> </div> </div> <?php } ?> </div> </div> </div> </div> </section>--> <!-- <br><br> --> <div class="row"> <div class="col-md-6"> <table id="customers"> <tr> <th colspan="3"><i class="fa fa-truck"></i> Shipment Details</th> </tr> <tr> <td style="width:40%;text-align:center;">AWB No </td> <td style="width:20%;text-align:center;"> :</td> <td style="width:40%;text-align:center;"><?php echo $trck_id; ?></td> </tr> <tr> <td style="width:40%;text-align:center;">PICKUP DATE </td> <td style="width:20%;text-align:center;"> :</td> <td style="width:40%;text-align:center;"><?php $day=date_create($row['pickup_created_date']);$new_date=date_format($day,'d-m-Y h:i:s');echo $new_date; ?></td> </tr> <tr> <td style="width:40%;text-align:center;">CONSIGNEE NAME </td> <td style="width:20%;text-align:center;"> :</td> <td style="width:40%;text-align:center;"><?php echo ucfirst($row['cname']); ?></td> </tr> <tr> <td style="width:40%;text-align:center;">NO OF BOX </td> <td style="width:20%;text-align:center;"> :</td> <td style="width:40%;text-align:center;"><?php echo $row['pics']; ?></td> </tr> <tr> <td style="width:40%;text-align:center;">DESTINATION </td> <td style="width:20%;text-align:center;"> :</td> <td style="width:40%;text-align:center;"><?php if($row['entry_type']==2 || $row['client_id']==22 || $row['client_id']==28){ echo $row['destination']; }else { echo $row['dest']; }?></td> </tr> <tr> <td style="width:40%;text-align:center;">CURRENT STATUS </td> <td style="width:20%;text-align:center;"> :</td> <td style="width:40%;text-align:center;"><b><?php echo ucfirst($row['status']); ?></b></td> </tr> </table> </div> <div class="col-md-6"> <table id="shipment-histry"> <tr> <th><i class="fa fa-truck"></i> Shipment History</th> </tr> <?php $statement="SELECT * FROM tbl_tracking where pickup_entry_id='$pick_id'"; $status_alls = mysqli_query($conn,$statement); $da='';$msg=''; foreach ($status_alls as $row1) { if($row1['status']=='Delivered'){ if($row1['delivery_date']==''){ $day=date_create($row1['shipment_create_date']); $new_date=date_format($day,'d-m-Y h:i:s'); echo $new_date; }else{ $day=date_create($row1['shipment_create_date']); $new_date=date_format($day,'d-m-Y h:i:s'); $da=$new_date; } }else{ $day=date_create($row1['shipment_create_date']); $new_date=date_format($day,'d-m-Y h:i:s'); $da=$new_date; } if($row1['status']=='In Transit'){ $msg='Forwarded to Destination'; }else if($row1['status']=='pending'){ $msg='Soft Data Uploaded'; }else{ $msg=ucfirst($row1['status']); } $loc=''; echo ' <tr> <td><i class="fa fa-calendar" style="font-size:24px;color:green"></i> '.$da.' <i class="fa fa-arrow-right" style="font-size:24px;color:green"></i> '.$msg.' <i class="fa fa-check-circle" style="font-size:24px;color:green"></i> '.$loc.'</li></td>'; } ?> </tr> <tr><td> <ul style="list-style:none;"> <?php if($row1['receiver_name']!='' || $row1['status']=='Delivered' | $row1['status']=='Undelivery'){ ?> <li><i class="fa fa-check" style="font-size:24px;color:red"></i> <?php if($row1['receiver_name']!=''){ ?>Receiver Name <i class="fa fa-arrow-right"></i> <b><?=$row1['receiver_name']?></b></li> <?php } if($row1['receiver_mobile']!=''){ ?> <li><i class="fa fa-check" style="font-size:24px;color:red"></i> Receiver Mobile <i class="fa fa-arrow-right"></i> <b><?=$row1['receiver_mobile']?></b></li> <?php } ?> <?php if($row1['relation']!=''){ ?> <li><i class="fa fa-check" style="font-size:24px;color:red"></i> Relation <i class="fa fa-arrow-right"></i> <b><?=$row1['relation']?></b></li> <?php } ?> <?php if($row1['reason']!=''){ ?> <li><i class="fa fa-check" style="font-size:24px;color:red"></i> Reason <i class="fa fa-arrow-right"></i> <b><?=$row1['reason']?></b></li> <?php } ?> <?php if($row1['status']=='Delivered'){ $statement="SELECT * FROM tbl_pod where awb_no='$trck_id'"; $status_alls = mysqli_query($conn,$statement); $rowcount=mysqli_num_rows($result); if($rowcount>0){ foreach ($status_alls as $row12) { if($row12['url_1']!=''){ ?> <li><center style="color:blue;"><h5><i class="bi bi-journal-check"></i> Proof of Delivery</h5></center></li> <li><center><a href="../dashboard/admin/img/POD/<?php echo $row12['url_1'];?>" target = "_blank" class="btn btn-warning btn-xxs" style="padding: 3px;font-size: 14px;margin:3px;"><i class="fa fa-eye"></i>View Proof Of Delivery (POD)</a> <a style="padding: 3px;font-size: 14px;" href="../dashboard/admin/img/POD/<?php echo $row12['url_1'];?>" download class="btn btn-info btn-xxs"><i class="fa fa-download"></i> Download Proof Of Delivery (POD)</a></center></li> <?php } } }} } ?> </ul> </td></tr> </table> </div> </div> <br><br><br> <?php }}} ?> <?php include "footer.php"?>