<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <link rel="stylesheet" href="./css/appboarding.css" />
  <link rel="stylesheet" href="./css/print.css" media="print" /> 
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <meta http-equiv="X-UA-Compatible" content="ie=edge">
  <title>BoardingPass</title>
  <style>
   @media print{
    @page {
      size: 82.5mm 203.3mm portrait transform: rotate(-270deg);
      margin: 0 auto;
      
    }

   }
  </style>

</head>
<body>

 <div class="mypage">
    <div class="submypage" style="" >
      <div class="container-1" >
    <table class="tb1" style= "float: left;" >
   
  <tr >
  <td  style="padding-left:27mm; padding-top:4mm; height:5mm; font-size:13pt;" ><b>{{$boardingPass->room->code}}</b></td>
  <td></td>
  <td  style="text-align: right; padding-right:4mm; font-size:13pt; " colspan='2'><b>{{$boardingPass->room->code}}</b></td> 
  </tr>
  <tr>
  <td  class="one" style=" padding-top:8mm; padding-left:37mm; font-size:9pt;"colspan='2' >{{ $boardingPass->ticket->called.' '.$boardingPass->ticket->fullName}}</td>
  <td  class="six"> <canvas class="bc1 barcode"></canvas>  </td>
  <td  class="three" style=" padding-top:6mm; padding-left:3mm; font-size:9pt;">{{ $boardingPass->ticket->called.' '.$boardingPass->ticket->fullName}}</td>
  </tr>
  <tr><td></td><td></td><td></td><td></td></tr>
  <tr>
  <td class="one"  style=" height:10mm ; padding-left:37mm; text-align: center; ">{{ $boardingPass->ticket->segment->cruise->originPort->country}}/{{ $boardingPass->ticket->segment->cruise->originPort->name }}</td>
  <td  colspan='2' ></td>
  <td class="three" style="text-align: center; " >{{ $boardingPass->ticket->segment->cruise->originPort->country}}/{{ $boardingPass->ticket->segment->cruise->originPort->name }}</td>

</tr>

  <tr>
  <td class="one"  style="padding-left:37mm; padding-top:6mm; text-align: center;" > {{ $boardingPass->ticket->segment->cruise->destinationPort->country}}/{{ $boardingPass->ticket->segment->cruise->destinationPort->name }}</td>
  <td class="" colspan='2'></td>
  <td class="three"  style="text-align:center;" >{{ $boardingPass->ticket->segment->cruise->destinationPort->country}}/{{ $boardingPass->ticket->segment->cruise->destinationPort->name }}</td>
</tr>

  <tr >
  <td  class="one"  style=" height:4mm; padding-left:37mm; padding-top:4mm; text-align: center;"  > {{  date('j M Y h:i a', strtotime($boardingPass->ticket->segment->cruise->departure_date_time)) }}</td>
  <td class="first" colspan='2' ></td>
  <td class="three"style="text-align: center;" >{{  date('j M Y h:i a', strtotime($boardingPass->ticket->segment->cruise->departure_date_time)) }}</td>
</tr>
  <tr>
     <td  class="" style=" height:4mm; width:51mm; padding-top:4mm; padding-left:34mm; text-align:left;">{{$boardingPass->room->code}} </td>

    <td style="text-align: left;  width:40mm; padding-top:2mm;">   {{ $boardingPass->ticket->segment->cruise->cruise_number }} </td>     
        <td class=""  style=" height:7mm; width:60mm; text-align: left; padding-top: 2px; ">
        
       
  </td>
  
  <td colspan='2' class="first"  style=" font-size:9pt; text-align:left; height:4mm; padding-bottom:1mm; padding-left:5mm;" >{{$boardingPass->ticket->segment->cruise->cruise_number}}/K.Queen/{{ date('h:i a', strtotime($boardingPass->ticket->segment->cruise->departure_time)) }}</td>

  </tr>
  <tr>
  <td class="four" style="padding-left:30mm;"><!-- {{ $boardingPass->ticket->segment->cruise->ship->name }} --> K.Queen</td>
  <td  class="five" style=" text-align:left; font-size:9pt"> {{  date('h:i a', strtotime('+2 hour')) }} </td>
<td class="six"> <canvas class="bc1 barcode"></canvas></td>
  
  <td    style=" padding-right:5px; padding-top:4px; text-align: right;" colspan='2'><?php 
  $trpdate=date('h:i a', strtotime($boardingPass->ticket->segment->cruise->departure_time));
  
  ?> {{  date('h:i:a', strtotime('-1 hours', strtotime('$trpdate'))) }} </td>

  </tr>
  <tr>
  <td class="seven" style="padding-left: 70px;">
          {{$boardingPass->code}}
        </td>
       <td colspan='2'>E-T  : {{  $boardingPass->ticket->ticket_number }}</td>
       
        <td class=""  style="text-align:right;  ">{{$boardingPass->code}}<canvas class="bc2 barcode"> </canvas> 
        
          
        </td>
        
      </tr>

 
    </table>
  </div>
  </div>
  </div>
</body>

<script src="/js/JsBarcode.all.min.js"></script>
<script>
 JsBarcode(".barcode",'{{$boardingPass->code}}',{
  background: 'transparent'
 } );
 </script>
</html>