| Current Path : /var/www/html/mmishra/irp/pcstore/report/ |
| Current File : /var/www/html/mmishra/irp/pcstore/report/issued_computer.php |
<?php
//show page head
include "../page_header.inc";
echo "<b>Issued Product</b><br>";
$pc_code = $_REQUEST["pc_code"];
echo "<br>Enter Product Code <input type='text' name='pc_code' value='$pc_code' size='15'> ";
echo "<input type='submit' name='submit' value='SEARCH'>";
echo "<table width='100%'><tr><th width='10%'>ID</th><th width='15%'>Description</th><th width='15%' nowrap>Issue Date</th><th width='20%'>Purpose</th><th width='20%'>Cusomer</th><th width='20%'>Remark</th></tr>";
$sql1 = "select pm.row_id,pm.series_code,pm.pc_code,pi.issue_date,pi.destination,pi.issue_for,pi.user_code,pi.remark from $product_master pm, $product_issued pi where pm.row_id=pi.pc_code ";
if ($pc_code) $sql1 .= " and pm.pc_code='$pc_code' ";
$sql1 .= "order by pm.series_code, pi.issue_date";
$rs1 = mysql_query($sql1, $con);
if(!$rs1) echo sql_error();
while ($o = mysql_fetch_object($rs1)){
$i++; $j++;
$row_id = $o->row_id;
$user_code = $o->user_code;
$customer = customer($user_code, $con);
$pc_code = $o->pc_code;
$issue_date = $o->issue_date;
$destination = $o->destination;
$issue_for = $o->issue_for;
$remark = $o->remark;
if ($series_code != $o->series_code){
$series_code = $o->series_code;
$series = series($series_code, $con);
echo "<tr><td colspan='5'><font size='+1' color='red'>Product Series: $series</td></tr>";
$i=1;
}
if ($i % 2) echo "<tr id='row1' valign='top'>"; else echo "<tr id='row2' valign='top'>";
echo "<td>$row_id</td><td><a href='../report/form_computer_issue.php?pc_code=$row_id'>$pc_code</a></td><td align='center' nowrap>$issue_date</td><td>$destination ($issue_for)</td><td>$customer</td><td>$remark</td></tr>";
}
echo "</table>";
echo "<font color='red' size='+1'>Total: $j</font>";
include "../page_footer.inc";
?>