Current File : /home/obabain/public_html/abc/ViewBillofMaterial_3.jsp
<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1"%>
     <%@ include file="Connection.jsp"%>

<%
  Statement st=con.createStatement();
  ResultSet rs=null;
%>

<%@include file="master.jsp"%>

<style type="text/css">
.highlight-error {
  border-color: red;  
}
</style>

   <!-- hide and show script -->  
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
<script>
$(document).ready(function(){
  $("#hide").click(function(){
    $("p").hide();
  });
               
  $("#show").click(function(){
    $("p").show();
  });
});
</script> 


 <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://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"> 

<!-- plugin tableEdit load -->
<script src="js/tableEdit-0.1.js"></script>

<!-- load plugin for element -->

<body>

<script type="text/javascript">
$(document).ready(function() {
    $('#example').DataTable();
} );
</script> 

<form method="post" id="contact" name="form1">
<section id="main">
<div class="container">
 <div class="row" style="width:110%">
    <div class="col-md-10">
       <div class="panel panel-default" >
       <div class="panel-heading main-color-bg">
        <h3 class="panel-title">Indent&nbsp;List:</h3>
        </div>
            
       <div class="panel-body">
          <div class="headerbar-item pull-right" style="margin-top:10px;">
           <input type="button" value="Back" style="background:#204b58" class="btn btn-info"  onclick="goBack()"/>
            <a class="btn btn-info" style="background:#204b58"  href="transfer_stock.jsp">New</a></div>
            <br><br><br>
<table class="table table-striped table-bordered" id="example">
        <thead>              
<tr class="success"> 
 <th>Indent No.</th>
 <th>Product</th>
 <th>Qty</th>
 <th>Unit</th>
<!--  <th>Edit</th> -->
 <th>Pdf</th>
<!--  <th>Hide/Show</th> --> 
</tr>
</thead>        
<tbody>     
       <%     
       rs=st.executeQuery("select tb.*,(select unit_name_plrl from ip_units where unit_id=tb.unit)un from bom_rawmaterial tb where type='F'");
       while(rs.next())
       {
       %>  
       <tr>
       <td> <a href="viewRawmaterial_1.jsp?id=<%=rs.getString("fg_id")%>"><%=rs.getString("bom_no")%></a></td>
       
      <td>  <b><%=rs.getString("product")%> </b> </td>
     
      <td> <%=rs.getString("quantity")%></td><td> <%=rs.getString("unit")%> </td>
      
    <%--   <td> <a class="glyphicon glyphicon-pencil" href="editFGbom.jsp?did=<%=rs.getString("B_id")%>"></a> </td> --%>
      
      <td> <a href="PrintPdf_1.jsp?id=<%=rs.getString("fg_id")%>&&bom_no=<%=rs.getString("bom_no")%>"><button type="button">Print</button> </a> </td>
       
     <!--  <td>   <button id="show">Show</button> <button id="hide">Hide</button> </td>  --> 
       </tr>     
        <%--
       <tr>
       <td>
       <table id="myTable" class="table table-bordered">
       <thead>
<tr>
<th>Raw Material</th>
<th>Quantity</th>
<th>Unit</th>

</tr>
</thead>
<%
Statement st1=con.createStatement();
ResultSet rs1=st1.executeQuery("select tb.*,(select unit_name_plrl from ip_units where unit_id=tb.unit)uni from bom_rawmaterial tb where type='R' and d1_id="+rs.getString("fg_id")+"");
while(rs1.next())
{
%>
<tbody>

<tr>

<td>
<%=rs1.getString("product") %>
</td>
<td><%=rs1.getString("quantity") %></td>
<td><%=rs1.getString("uni") %></td>
</tr>

</tbody>
<%} %>

</table>
</td>
       </tr> --%>
       <%}%>
       </tbody>
       </table>

   <!-- <div>   
      <p style="display:none;">If you click on the "Hide" button, I will disappear.</p>    
   </div>
 -->

<!-- <script>
function myFunction() {
    var x = document.getElementById("myDIV");
    if (x.style.display === "none") {
        x.style.display = "block";
    } else {
        x.style.display = "none";
    }
}
</script> -->
       
      <div class="modal-footer" id="contact_submit">
      
        <div class="row">
           
      <!-- <a class="btn btn-default" href="#"  style="margin-right:10px">Reset</a> -->
        <!--  <button type="submit" style="background:" class="" ></button>-->
      </div>
      </div>
 </div>
    </div>
  </div>
</div>
</div> 
</section>
<%-- <% }else{ 
     response.sendRedirect("login.jsp");
    } %> --%>
    
    
 <!-- <script src="http://cdn.ckeditor.com/4.6.1/standard/ckeditor.js"></script>
     <script src="http://cdn.ckeditor.com/4.6.1/standard/ckeditor.js"></script>  
   
 <script src="https://code.jquery.com/jquery-1.11.1.min.js"></script>
<script src="https://cdn.jsdelivr.net/jquery.validation/1.16.0/jquery.validate.min.js"></script> 
<script src="https://cdn.jsdelivr.net/jquery.validation/1.16.0/additional-methods.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script type="text/javascript">         
</script> -->


<%@include file="footer.jsp" %>
</form>
<script type="text/javascript">
function goBack() {
    window.history.back();
   
};
</script>


</body>
</html>