Current File : //home/obabain/public_html/abc/supplierRA.jsp |
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ include file="Connection.jsp" %>
<%!
double i=0;
String i1=null;
%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
<title>Insert title here</title>
</head>
<body>
<%@include file="master.jsp" %>
<form>
<div class="content">
<div class="row">
<div class="col-md-9" style="background-color:white;">
<div class="panel panel-default" >
<div class="panel-heading main-color-bg">
<h3 class="panel-title">Suppliers Rating List</h3>
</div>
</div>
<!-- <div class="col-md-12" >
<input class="form-control" type="text" placeholder="Search suppliers..." name="filter">
</div> -->
<div class="headerbar-item pull-right" style="margin-top:10px;"><a class="btn btn-primary" style="background:#204b58" onclick="goBack()">Back</a>
</div><br><br>
<div>
<br>
<table class="table table-bordered" id="myTable"style="border:2">
<thead>
<tr style="background-color:#FFDAB9; ">
<th>Sl.No</th>
<th>Supplier Name/Address</th>
<th>Scope of Supply</th>
<th>No.of Pc or Kgs</th>
<th>OK</th>
<th> Rating %</th>
<th>Remarks</th>
</tr>
</thead>
<tbody>
<%
ResultSet rs=null;
Statement st=con.createStatement();
rs=st.executeQuery("select tb.*,(select supplier_name from ip_suppliers where supplier_id=tb.suplier_id)as sname,(select product_name from ip_products where product_id=tb.product)as pro,((acqty/tqty)*100)tot from ip_sup_deli_rating tb ");
while(rs.next())
{
%>
<tr style="height:30px; ">
<td> <%=rs.getString("d_id") %> </td>
<td><%=rs.getString("sname") %></td>
<td>
<%=rs.getString("pro") %>
</td>
<td><%=rs.getString("tqty") %> </td>
<td><%=rs.getString("acqty") %> </td>
<td>
<%
i=Double.parseDouble(rs.getString("tot"));
i1=String.format("%.2f", i);
%>
<%=i1 %> </td>
<td>
</td>
</tr>
<%} %>
</tbody>
</table>
</div>
</div>
</div>
</div>
<%@include file="footer.jsp" %>
</form>
<script type="text/javascript">
function goBack() {
window.history.back();
};
</script>
</body>
</html>