Current File : /home/obabain/public_html/abc/M_orderForm.jsp |
<%@include file="master.jsp" %>
<style type="text/css">
.highlight-error {
border-color: red;
}
.inlineTable {
display: inline-block;
}
table, th, td {
border: px solid black;
}
/* a.btn:hover {
-webkit-transform: scale(1.1);
-moz-transform: scale(1.1);
-o-transform: scale(1.1);
}
--a.btn {
-webkit-transform: scale(0.8);
-moz-transform: scale(0.8);
-o-transform: scale(0.8);
-webkit-transition-duration: 0.5s;
-moz-transition-duration: 0.5s;
-o-transition-duration: 0.5s;
}
.btn.outline {
background: none;
padding: 5px 20px;
}
.btn-primary.outline {
border: 2px solid #0099cc;
color: #0099cc;
}-->*/
.panel-default > .panel-heading-custom {
background: #ff0000; color: #fff;
}
</style>
<!-- <link href="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/css/bootstrap.min.css" rel="stylesheet" id="bootstrap-css">-->
<script src="//maxcdn.bootstrapcdn.com/bootstrap/3.3.0/js/bootstrap.min.js"></script>
<script src="//code.jquery.com/jquery-1.11.1.min.js"></script>
<script src="http://code.jquery.com/jquery-2.1.1.min.js"></script>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<%!int i; String s=null;%>
<body>
<%
String count=null;String id=null;String sys_id=null;
Statement st=con1.createStatement();
ResultSet rs = null;
rs = st.executeQuery("select tb.*,(select concat(Prefix,MO_Id))code from system_generated_id tb");
while(rs.next()){
count=rs.getString("code");
id=rs.getString("MO_Id");
i=Integer.parseInt(id)+1;
s=String.valueOf(i);
if(s.length()==1)
{
sys_id="00"+s;
}
else{
sys_id="0"+s;
}
System.out.println(count);
}
/* st.executeUpdate("INSERT INTO manufacture_order(mocus_id)VALUES('"+count+"');");
st.executeUpdate("update system_generated_id set MO_Id='"+sys_id+"'"); */
%>
<script type="text/javascript">
function getqc(targetField,targetField1,targetField2,targetField3)
{
var w3=window.open('Productselect3.jsp','_blank','top=80,left=70,width=1400,height=650,scrollbars=1')
w3.targetField=targetField;
w3.targetField1=targetField1;
w3.targetField2=targetField2;
w3.targetField3=targetField3;
w3.focus();
}
</script>
<script>
function setSearchRslt2(targetField,targetField1,targetField2,targetField3,returnvalue,returnvalue1,returnvalue2,returnvalue3)
{
targetField.value = returnvalue;
targetField1.value = returnvalue1;
targetField2.value = returnvalue2;
targetField3.value = returnvalue3;
window.focus();
}
</script>
<script type="text/javascript">
function getqc1(targetField,targetField1)
{
var w3=window.open('machineSelect.jsp','_blank','top=80,left=70,width=1400,height=650,scrollbars=1')
w3.targetField=targetField;
w3.targetField1=targetField1;
w3.focus();
}
</script>
<script>
function setSearchRslt3(targetField,targetField1,returnvalue,returnvalue1)
{
targetField.value = returnvalue;
targetField1.value = returnvalue1;
window.focus();
}
</script>
<div class="row">
<form action="addmorder.jsp" 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">Manufacturing Order Form</h3>
</div>
<!-- <div class="pull-right" >
<div class="headerbar-item pull-right" style="margin-top:10px;">
<a href="ProductionOrder.jsp" style="background:#204b58;" class="btn btn-info">Order Form</a>
<a class="btn btn-info" style="background:#204b58" href="ProductPrintPdf.jsp">Print</a>
</div>
</div>
-->
<!-- <div class="onerow" ><div class="btn">
<button type="button" class="btn btn-primary">Conform Production </button>
<button type="button" class="btn btn-primary">Cancel Production</button>
<button type="button" class="btn "style="margin-left:300px;">NEW</button>
<button type="button" class="btn btn-primary"style="margin-left:px;">Ready to produce</button>
<button type="button" class="btn btn-primary">Production Start</button>
<button type="button" class="btn btn-primary">Done</button>
</div>
</div>-->
<br><div class="panel-body" >
<div class="row" >
<!-- <div class="row">
<div class="form-group col-xs-2">
<div class="onerow">
<p><label for="status" style="margin:5px;">
Invoice No.</label></p>
<input type="text" class="form-control" name="invoiceno" value="" readonly="readonly">
</div>
</div> -->
<div class="form-group col-xs-2" style="margin-left:20px;">
<p><label for="status" style="margin:5px;">
Manufacturing Order</label></p>
<input id="lastname" class="input-group-lg reg_name" value="<%=count%>" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="address" placeholder=""/>
</div>
<div class="form-group col-xs-2" style="margin-left:20px;" >
<p><label for="status" style="margin:5px;">
Schedule date</label></p>
<input id="lastname" class="form-controle" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;margin-left:10px;" type="date"
name="sh_date" placeholder=""/>
</div>
<input type="hidden" name="mo_id">
<input type="hidden" name="p_id">
<input type="hidden" name="type">
 
<div class="form-group col-xs-2" style="margin-left:30px;">
<p><label for="status" style="margin:5px;">
Product</label></p>
<table><tr>
<td>
<input id="lastname" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="product" placeholder=""/></td>
<td><button onclick="getqc(document.form1.product,document.form1.bom,document.form1.p_id,document.form1.type)" type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button>
</td>
</tr>
</table>
</div>
<div class="form-group col-xs-2" style="margin-left:60px;">
<p><label for="status" style="margin:5px;">
BOM </label></p>
<input id="lastname" class="" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc; type="text"
name="bom" placeholder=""/>
</div>
</div>
<!-- 2nd row -->
<br> <br>
<div class="row" >
<div class="form-group col-xs-2" style="margin-left:20px;">
<p><label for="status" style="margin:5px;">
Product Qty</label></p>
<input id="lastname" class="input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="pro_qty" placeholder=""/>
</div>
<div class="form-group col-xs-2" style="margin-left:28px;" >
<p><label for="status" style="margin:5px;">
Responsible Person</label></p>
<input id="firstname" class=" " style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="resperson" placeholder=""/>
</div>
 
<div class="form-group col-xs-2" style="margin-left:20px;">
<p><label for="status" style="margin:5px;">
Select Machin</label></p>
<table><tr>
<td><input class="form-control" type="text" name="machine_name" value="" id="register_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;"/></td>
<td> <button onclick="getqc1(document.form1.machine_name,document.form1.machin_capacity)" type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button></td>
<!-- <td><a href=" machineselectby.jsp"> <button type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button></a></td> -->
</tr>
</table>
</div>
<div class="form-group col-xs-2" style="margin-left:60px;" >
<p><label for="status" style="margin:5px;">
Machine Capacity</label></p>
<input class="form-control" type="text" name="machin_capacity" value="" id="register_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;"/>
</div>
<%-- <div class="form-group col-xs-2" style="margin-left:30px;">
<p><label for="status" style="margin:5px;">
Location</label></p>
<select class=" input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" name="loc1">
<%
ResultSet rs15=st.executeQuery("select * from salesarea");
while(rs15.next())
{
%>
<option value="<%=rs15.getString("id")%>"><%=rs15.getString("salesarea") %></option>
<%
}
%>
</select>
</div> --%>
<%-- <div class="form-group col-xs-2" style="margin-left:50px;">
<p><label for="status" style="margin:5px;">
RawMaterial Location</label></p>
<select class=" input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" name="loc">
<%
ResultSet rs14=st.executeQuery("select * from salesarea");
while(rs14.next())
{
%>
<option value="<%=rs14.getString("id")%>"><%=rs14.getString("salesarea") %></option>
<%
}
%>
</select>
</div> --%>
</div>
<!-- 3rd row -->
<br>
<div class="row" >
<!--
<div class="form-group col-xs-2" style="margin-left:20px;">
<p><label for="status" style="margin:5px;">
Select Machin</label></p>
<table><tr>
<td><input class="form-control" type="text" name="machine_name" value="" id="register_name" style="width:150px;height:34px;border-radius:5px;border:1px solid #ccc;"/></td>
<td> <button onclick="getqc1(document.form1.machine_name,document.form1.machin_capacity)" type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button></td>
<td><a href=" machineselectby.jsp"> <button type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button></a></td>
</tr>
</table>
</div>
<div class="form-group col-xs-2" style="margin-left:40px;" >
<p><label for="status" style="margin:5px;">
Machine Capacity</label></p>
<input class="form-control" type="text" name="machin_capacity" value="" id="register_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;"/>
</div> -->
<div class="form-group col-xs-2" style="margin-left:30px;">
<p><label for="status" style="margin:5px;">
Location</label></p>
<select class=" input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" name="loc1">
<%
ResultSet rs15=st.executeQuery("select * from salesarea");
while(rs15.next())
{
%>
<option value="<%=rs15.getString("id")%>"><%=rs15.getString("salesarea") %></option>
<%
}
%>
</select>
</div>
</div>
<%-- <label for="lastname" style="margin-left:-40px;">Manufacturing Order:</label>
<input id="lastname" class="input-group-lg reg_name" value="<%=count%>" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="address" placeholder=""/>
<input type="hidden" name="p_id">
<input type="hidden" name="type">
<label for="lastname" style="margin-left:50px;">Schedule date:</label>
<input id="lastname" class="form-controle" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;margin-left:10px;" type="date"
name="sh_date" placeholder=""/>
<div class="form-group col-xs-2">
<p> <label for="lastname" style="margin:5px;"> </label></p>
</div> --%>
</div>
<!--
<div class="row" >
<label for="lastname" style="margin-left:-40px;">Product :</label>
<input id="lastname" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="product" placeholder=""/>
<button onclick="getqc(document.form1.product,document.form1.bom,document.form1.p_id,document.form1.type)" type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button>
<label for="lastname" style="margin-left:35px;">Bill of Material:</label>
<input id="lastname" class="" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc; type="text"
name="bom" placeholder=""/>
<div class="form-group col-xs-2">
<p> <label for="firstname" style="margin:5px;" ></label></p>
</div>
</div> -->
<!-- <div class="row" >
<label for="lastname" style="margin-left:240px;">Product Qty</label>
<input id="lastname" class="input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="pro_qty" placeholder=""/>
<label for="firstname" style="margin-left:55px;">Responsible Person</label>
<input id="firstname" class=" " style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" type="text"
name="resperson" placeholder=""/>
</div> -->
<div class="row" >
<%-- <label for="lastname" style="margin-left:175px;">RawMaterial Location</label>
<select class=" input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" name="loc">
<%
ResultSet rs14=st.executeQuery("select * from salesarea");
while(rs14.next())
{
%>
<option value="<%=rs14.getString("id")%>"><%=rs14.getString("salesarea") %></option>
<%
}
%>
</select> --%>
<%--
<label for="lastname" style="margin-left:55px;">Location:</label>
<select class=" input-group-lg reg_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;" name="loc1">
<%
ResultSet rs15=st.executeQuery("select * from salesarea");
while(rs15.next())
{
%>
<option value="<%=rs15.getString("id")%>"><%=rs15.getString("salesarea") %></option>
<%
}
%>
</select>
--%>
</div>
<!--
<br>
<table>
<tr> -->
<!-- -td class="tdLabel"><label for="" style="margin-left:170px">Machin Id:</label></td>
<td><input class="form-control" type="text" name="t_name" value="" id="register_name" style="width:160px;"/>
</td> machineselectby.jsp -->
<!-- <td class="tdLabel"><label for="" style="margin-left:210px" >Select Machin:</label></td>
<td><input class="form-control" type="text" name="machine_name" value="" id="register_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;"/></td>
<td> <button onclick="getqc1(document.form1.machine_name,document.form1.machin_capacity)" type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button></td>
<td><a href=" machineselectby.jsp"> <button type="button" class="btn btn-default" ><span class="glyphicon glyphicon-search"></span></button></a></td>
<td class="tdLabel"><label for="" style="margin-left:45px">Machine Capacity:</label></td>
<td><input class="form-control" type="text" name="machin_capacity" value="" id="register_name" style="width:170px;height:34px;border-radius:5px;border:1px solid #ccc;"/></td>
</tr>
</table> -->
<!-- <table>
<tr>
<td class="tdLabel"><label for="" style="margin-left:65px" >Manufacture Date:</label></td>
<td><input class="form-control" type="text" name="t_name" value="" id="register_name" style="width:160px;"/></td>
</tr>
</table> -->
<!-- </div> -->
<div class="modal-footer" id="contact_submit">
<input type="button" value="Back" style="background:#204b58;margin-right:720px" class="btn btn-info" />
<a class="btn btn-default" href="">Reset</a>
<!-- <button type="submit" style="background:#204b58" class="btn btn-info" >Save Changes</button>-->
<!-- <a href="ViewM_orderForm.jsp" style="background:#204b58;" class="btn btn-info">
-->
<button type="submit" style="background:#204b58" class="btn btn-info" >Save Changes</button>
<!-- <strong>Save Change</strong> </a> -->
</div>
<!-- </form> -->
<hr>
</div>
</div>
</div>
</div>
</section>
<script type="text/javascript">
function openwin(targetField,targetField2,targetField3,targetField4,targetField5,targetField6){
var w1=window.open('machineSelect.jsp','_blank','top=80,left=70,width=1400,height=650,scrollbars=1');
w1.targetField=targetField;
w1.targetField2=targetField2;
w1.targetField3=targetField3;
w1.targetField4=targetField4;
w1.targetField5=targetField5;
w1.targetField6=targetField6;
w1.focus();
};
</script>
<%-- <% }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">
$('[data-type="adhaar-number"]').keyup(function() {
var value = $(this).val();
value = value.replace(/\D/g, "").split(/(?:([\d]{4}))/g).filter(s=s.length > 0).join("-");
$(this).val(value);
});
$('[data-type="adhaar-number"]').on("change, blur", function() {
var value = $(this).val();
var maxLength = $(this).attr("maxLength");
if (value.length != maxLength) {
$(this).addClass("highlight-error");
alert("Aadhar card number not valid");
} else {
$(this).removeClass("highlight-error");
}
});</script>
<!-- <script>
function setSearchRslt7(targetField,targetField2,targetField3,targetField4,targetField5,targetField6,returnvalue,returnvalue2,returnvalue3,returnvalue4,returnvalue5,returnvalue6)
{
var table = document.getElementById("myTable");
var lastRow = table.rows.length;
var row = table.insertRow(lastRow);
var cell1 = row.insertCell(0);
var cell2 = row.insertCell(1);
var cell3 = row.insertCell(2);
var cell4 = row.insertCell(3);
var cell5 = row.insertCell(4);
var cell6 = row.insertCell(5);
var cell7 = row.insertCell(6);
var cell8 = row.insertCell(7);
var cell9 = row.insertCell(8);
targetField.value=returnvalue;
targetField2.value=returnvalue2;
targetField3.value=returnvalue3;
targetField4.value=returnvalue4;
targetField5.value=returnvalue5;
targetField6.value=returnvalue6;
cell9.innerHTML = "<a href='#' onclick='deleteRow(this)'><i class='glyphicon glyphicon-trash'></i> </a>";
// cell5.innerHTML = "<input type='text' name='txttotal' class='txtstyle'>";
if(lastRow==2)
document.getElementById("myTable").deleteRow(2);
}
</script>
<script langauge="JavaScript">
function deleteRow(btn) {
var row = btn.parentNode.parentNode;
row.parentNode.removeChild(row);
}
</script> -->
</form>
</div>
</body>
</html>