 <style type="text/css">
<!--
.style20 {
	font-family: Verdana;
	font-size: 12px;
}
.style5 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 14px;
}
.style3 {
font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 13px;
}
.style10{ border-top:solid 1px; border-top-color:#999;}
.style11{ border-bottom:dashed 1px; border-bottom-color:#333333;}
.style4 {font-family: Verdana, Arial, Helvetica, sans-serif;
font-size: 13px;
}
.style23 {font-family: Verdana, Arial, Helvetica, sans-serif}
.style29 {font-size: 12px}
.style28 {	font-size: 16px;
	font-weight: bold;
}
.stylebottom
{
	border-right:1px solid #999;

	
	border-bottom:1px solid #999;
}	
-->
</style>
<div class="row-fluid">
<div class="span12">
<div class="table-responsive">
<div class="CSSTableGenerator">
<?php 
include ("../../include/db.php");
error_reporting(0);
ob_start();
session_start();
$session_branch=$_SESSION['branch'];
$session_user_type=$_SESSION['user_type'];
$branch_name11=$_GET['branch_name'];

$branch_name=$_GET['book_branch'];
function get_categ_branch_id($branch_name)
{
$sql_query11="select * from branch_creation where branch_id='$branch_name' and delete_status!='1'";
$rs11=mysql_query($sql_query11);
 while($rsdata11=mysql_fetch_object($rs11))
 {
 $id=$rsdata11->branch_name;
 } 
	return $id;
 }
   function get_categ_branch_id12($branch_name11)
{
$sql_query11="select * from branch_creation where branch_id='$branch_name11' and delete_status!='1'";
$rs11=mysql_query($sql_query11);
 while($rsdata11=mysql_fetch_object($rs11))
 {
 $id=$rsdata11->branch_name;
 } 
	return $id;
 }

 $bran_name=get_categ_branch_id($branch_name);
 $branc_name=get_categ_branch_id12($branch_name11);

if($session_user_type!=1)
{
$query="select * from branch_creation  WHERE branch_id='$session_branch'";
}
$rs=mysql_query($query);						 
                                                $i=0;
                                                while($list=mysql_fetch_array($rs))
                                                {
                                                $i=$i+1;
												$branch_address=$list['branch_address'];
												$head_off=$list['head_off'];
												$branch_off=$list['branch_off'];
												$branch_ph=$list['branch_ph'];
												$delivery_ph=$list['delivery_ph'];
												$delivery_off=$list['delivery_off'];
											    }


												?>									  
<table border="0" width="100%"  cellpadding="0" cellspacing="0">
<tr><td height="22" colspan="7"  align="center" style="font-size:14px; padding-center:5px; font-family:Verdana" ><div><b>Fabric Delivery Details</b></div>
    </td>
</tr>
 <?php if($session_user_type!=1)
{
?>
  <?php } ?><tr><td colspan="7"  align="center" class="style20" style=" padding-center:5px; font-family:Verdana" ></td></tr>
<tr><td colspan="7"  align="center" class="style20" style=" padding-center:5px; font-family:Verdana" ></td></tr>
<tr>
  <td width="4%" height="29"  align="left" class="style20" style="padding-left:50px;">&nbsp;</td>
  <td width="15%"  align="left" class="style20" ><span class="style20" >&nbsp;Delivery No </span></td>
  <td width="21%"  align="left" class="style20" ><span class="style20" style="padding-left:50px;">
    <?php if($_GET['from_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['from_date']));}?>
  </span></td>
<td colspan="2"  align="center" class="style20"></td>
<td width="10%" align="left" class="style20" scope="col">Jobcard No</td>
<td width="21%" align="left" class="style20" scope="col"><?php if($_GET['to_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['to_date'])); }?></td>
</tr>
<tr>
  <td height="34"  align="left" class="style20" style="padding-left:50px;">&nbsp;</td>
  <td height="34"  align="left" class="style20" ><span class="style20" >&nbsp;Customer Name</span></td>
  <td height="34"  align="left" class="style20" ><span class="style20" style="padding-left:50px;">
    <?php if($_GET['from_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['from_date']));}?>
  </span></td>
  <td width="14%"  align="center" class="style20">Job type</td>
  <td width="15%"  align="left" class="style20"><?php if($_GET['to_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['to_date'])); }?></td>
  <td align="left" class="style20" scope="col">Fabric type    </td>
  <td align="left" class="style20" scope="col"><?php if($_GET['to_date']==''){ echo $curdate=date('d-m-Y');} else { echo date("d-m-Y",strtotime($_GET['to_date'])); }?></td>
</tr>
</table>
<table width="90%" height="86" border="0" align="center"  cellpadding="0" cellspacing="0"  >
<tr>
      <td height="36"  align="center" class="style10 stylebottom style3" style="border-left:1px solid #999;"><strong>S.No</strong></td>
    <td scope="col" align="left" class="style10 stylebottom style3"><strong>&nbsp; Delivery Date</strong></td>
      <td scope="col" align="left" class="style10 stylebottom style3"><strong>&nbsp; Particulars</strong></td>
      <td scope="col" align="left" class="style10 stylebottom style3"><strong>&nbsp; Width</strong></td>
      <td scope="col" align="left" class="style10 stylebottom style3"><strong>&nbsp; Height</strong></td>
      <td width="131" align="center" class="style10 stylebottom style3" scope="col"><strong>Qty</strong></td>
      </tr>
  <?php
include("../../include/db.php");  

   $sql="select * from  delivery_challan_sub where job_no='$_GET[jobcard_no]' ";
    $rs=mysql_query($sql);
	$s_no=0;
   		while($rsdata=mysql_fetch_array($rs))
  			{
   				 $s_no=$s_no+1;
                 $id=$rsdata['id'];
                 $delivery_no=$rsdata['delivery_no'];
				 $date_time=$rsdata['date_time'];
				 $job_no=$rsdata['job_no'];
				 $created_by=$rsdata['created_by'];
                 $customer_name=$rsdata['cust_name'];
				 $style_no=$rsdata['style_no'];
				 $style_name=$rsdata['style_name'];
				 $combo=$rsdata['combo'];
				 $customer_po_no=$rsdata['customer_po_no'];
				 $job_type=$rsdata['job_type'];
				 $fabric_type=$rsdata['fabric_type'];
				 $delivery_date=$rsdata['delivery_date'];
				 $particulars=$rsdata['particulars'];
				 $rollno_width=$rsdata['rollno_width'];
				 $qty=$rsdata['qty'];
				 $kg_meter_height=$rsdata['kg_meter_height'];
 ?>
  <tr>
    <td width="49"  align="center" class="style3 stylebottom" style="border-left:1px solid #999;">&nbsp;<?php echo $s_no; ?></td>
    <td width="181" align="left" class="style3 stylebottom" >&nbsp;<?php echo date('d-m-Y',strtotime($delivery_date)); ?></td>
    <td width="475" align="left" class="style3 stylebottom" >&nbsp;<?php echo $particulars; ?></td>
    <td width="156" align="left" class="style3 stylebottom" >&nbsp;<?php echo $rollno_width; ?></td>
    <td width="138" align="left" class="style3 stylebottom" >&nbsp;<?php echo $kg_meter_height; ?></td>
    <td align="center" class="style3 stylebottom" >&nbsp;<?php echo $qty; ?>&nbsp;</td>
    </tr>
  <?php } ?>
  </thead>
</table>
</div>
<table border="0" width="99%"  align="center" cellpadding="0" cellspacing="0" >

 <tr>
    <th height="19" align="left" style="font-size:12px; font-family:sans-serif; padding-top:10px;" scope="col"><?php echo $confirmation;?></th>
	<th scope="cols" width="8%" align="right"><?php  
			  if ($num_results > $show) 
			  {
			  $show;
			include("include/footer_links.php");
			  }
	?></th>
 </tr>
</table>