Current File : //home/obabain/anms_obaba_in/ViewProformaInvoices.jsp |
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
pageEncoding="ISO-8859-1"%>
<%@ include file="Connection.jsp" %>
<%@include file="master_one.jsp" %>
<%
Statement st=con.createStatement();
ResultSet rsRowCnt = 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">
<script src='https://code.jquery.com/jquery-3.3.1.js'></script>
<script src='https://cdn.datatables.net/1.10.19/js/jquery.dataTables.min.js'></script>
<script src="https://cdn.datatables.net/1.10.19/js/dataTables.bootstrap4.min.js" charset="utf-8">
</script>
<!-- <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/css/bootstrap.min.css">
-->
<!-- <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/twitter-bootstrap/4.1.1/css/bootstrap.css"> -->
<link rel="stylesheet" href="https://cdn.datatables.net/1.10.19/css/dataTables.bootstrap4.min.css">
</head>
<style>
.dropbtn {
color: white;
padding: 12px;
font-size: 16px;
border: none;
cursor: pointer;
height:35px;
}
.dropdown {
position: relative;
display: inline-block;
}
.dropdown-content {
display: none;
position: absolute;
background-color: #f9f9f9;
min-width: 160px;
box-shadow: 0px 8px 16px 0px rgba(0,0,0,0.2);
z-index: 1;
}
.dropdown-content a {
color: black;
padding: 12px 16px;
text-decoration: none;
display: block;
}
.dropdown-content a:hover {background-color: #f1f1f1}
.dropdown:hover .dropdown-content {
display: block;
}
.dropdown:hover .dropbtn {
background-color: #3e8e41;
}
</style>
<style>
table {
border-collapse: collapse;
border-spacing: 0;
width: 100%;
border: 1px solid #ddd;
}
tr, td {
text-align: left;
padding: 8px;
}
tr:nth-child(even){background-color: #f2f2f2}
</style>
<body>
<script type="text/javascript">
$(document).ready(function() {
$('#example').DataTable();
} );
</script>
<form>
<div class="content">
<div class="row">
<div class="col-md-9" style="background-color:#eae9e9;width:80%;">
<div class="panel panel-default" >
<div class="panel-heading main-color-bg">
<h3 class="panel-title">Proforma Invoices</h3>
</div>
</div>
<div class="headerbar-item pull-right" style="margin-top:-55px;"><a class="btn btn-danger" style="background:" onclick="goBack()">Back</a>
<a class="btn btn-danger" style="background:" href="ProformaInvoiceMain.jsp">New</a>
</div>
<br>
<table class="table table-bordered" id="example">
<thead>
<tr>
<!-- <th>Status</th> -->
<th>Date</th>
<th> Proforma Invoice No.</th>
<th>Client</th>
<th>Total</th>
<th>Balance</th>
<th>options</th>
</tr>
</thead>
<tbody>
<%
ResultSet rs=null;
rs=st.executeQuery("select tb.*,(select client_name from ip_clients where client_id=tb.supplier_id)suppl,(select description from ip_status where id=tb.salesinv_status)stat,(tb.total-IFNULL(tb.received_amt,0)) bal from ip_proforma_invoice tb order by sinvoice_id ");
while(rs.next())
{
%>
<tr>
<%-- <td><%=rs.getString("stat") %></td> --%>
<td><%=rs.getString("invoice_date_created")%></td>
<%-- <td><a href="wasteViewSIbyNO.jsp?Id=<%=rs.getString("sinvoice_id")%>">
<%=rs.getString("sales_invoice_no")%></a></td> --%>
<td><a href="ViewPRbyNO.jsp?Id=<%=rs.getString("sinvoice_id")%>">
<%=rs.getString("sales_invoice_no")%></a></td>
<td><%=rs.getString("suppl") %></td>
<td><%=rs.getString("total")%></td>
<td><%=rs.getString("bal")%></td>
<td>
<div class="dropdown">
<button class="dropbtn">Options</button>
<div class="dropdown-content">
<a href="prpdf.jsp?Id=<%=rs.getString("sinvoice_id")%>&inv=<%=rs.getString("type")%>&type=Original Copy For Customer"><span class="fontstyle">Download PDF(Original)</span></a>
<a href="prpdf.jsp?Id=<%=rs.getString("sinvoice_id")%>&inv=<%=rs.getString("type")%>&type=Duplicate Copy For Transporter"><span class="fontstyle">Download PDF(Duplicate)</span></a>
<a href="prpdf.jsp?Id=<%=rs.getString("sinvoice_id")%>&inv=<%=rs.getString("type")%>&type=Triplicate Copy For Supplier"><span class="fontstyle">Download PDF(Triplicate)</span></a>
<a href="prpdf.jsp?Id=<%=rs.getString("sinvoice_id")%>&inv=<%=rs.getString("type")%>&type=Extra copy"><span class="fontstyle">Download PDF(Extra)</span></a>
<%-- <a href="Editsalesinvoice.jsp?Id=<%=rs.getString("sinvoice_id")%>"><span class="fontstyle">Edit</span></a> --%>
<a href="deleteprInvoice.jsp?Id=<%=rs.getString("sinvoice_id")%>" onclick = "if (! confirm('Continue?')) { return false; }">
<span class="fontstyle">Delete</span>
</a>
</div>
</div>
</td>
<%} %>
</tr>
</tbody>
</table>
</div>
</div>
</div>
</div>
</form>
<script type="text/javascript">
function goBack() {
window.history.back();
};
</script>
</body>
</html>