<?php 
$sql = "select * from comprative";
$PurchOrdersResult = DB_query($sql,$db);?>
<link rel="stylesheet" href="css/new_mxerp.css">
<div class="body_contain">
<div class="tab_div">
<h1>Comparative</h1>
<table  border="1" width="100%" cellspacing="0" cellpadding="3">
<tr class="row1">
	<td class="tabledata"><strong>Comparison Number</strong></td>
	<td class="tabledata"><strong>Comparison  Date</strong></td>
	<td class="tabledata"><strong>Site</strong></td>
	<td class="tabledata"><strong>View Comparison</strong></td>
	<!--<th width="17%"><strong>Create Purchase Order </strong></th>--> 
</tr>
<?php
$j = 1;
$k=0;
if(DB_num_rows($PurchOrdersResult)>0)
{
	while ($row=DB_fetch_array($PurchOrdersResult)) 
	{?> 
	<tr class="row1">
	<td><?php echo $row['comparative_no'];?></td>
	<td><?php echo ConvertSQLDate($row['comparative_date']);?></td>
	<td><?php echo $row['site'];?></td>
 <td>  
<?php if($_SESSION['frmView']==1){ ?>
	<a href="index.php?route=POModule/comp_POrder<?php echo $rurl;?>&comprative_no=<?php echo $row['id']?>"><center><img src="images/search.gif"  width="20" height="20"/></center></a>
	 <?php }else{ ?>
	<?php echo 'No Permission'; ?>
	<?php }?>
	  </td>
	  <!--<td> 
			<a href="index.php?route=POModule/Comp-order-list<?php echo $rurl;?>&CGROUP=<?php echo $row['comprative_no']?>"> <img src="images/icon-edit.png"  width="20" height="20"/></a>
	</td>-->
	</tr>
<?php $j++;} 	}	else{?>
<tr>
		<td colspan="5"><font color="#FF0000">No Record Found!</font></td>
</tr>
<?php }?>
</table>
