Commit 8e709aef authored by asikarwar's avatar asikarwar

made change bcoz stduom and rateuom is not working in last version


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@92838 ce508802-f39f-4f6c-b175-0d175dae99d5
parent e36aebbe
......@@ -82,13 +82,13 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
String itemCode = "",ditemCode = "";
String packCode = "";
String hitemCode = "",tranId = "";
String rate = "",drate = "";
Double rate1 = 0.0;
String indentNo = "";
String tranDateS = "";
String unitRate="";
System.out.println("editFlag ---->>>["+editFlag+"]");
String unit = "";
String rate = "",drate = "";
Double rate1 = 0.0;
String updateFlag = "",status = "";
int ctr = 0;
int currentFormNo = 0;
......@@ -143,7 +143,6 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
if (indentNo != null && indentNo.trim().length() > 0 )
{
itemCode=checkNull(this.genericUtility.getColumnValue("item_code", dom));
tranId=checkNull(this.genericUtility.getColumnValue("tran_id", dom));
// added by cpandey Validation for duplicate tran id in boqhdr on 07/03/13
sql = "select count(*) from boqhdr where tran_id = ?";
pstmt = conn.prepareStatement(sql);
......@@ -184,6 +183,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
errFields.add(childNodeName.toLowerCase());
}
//end of addition
//changes done by cpandey for approved indent no status = 'A'
sql = "select count(*) from indent where status = 'A' and item_code = ?";
pstmt = conn.prepareStatement(sql);
......@@ -282,6 +282,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
}
}
//end of changes on 05/11/12
//end of changes on 05/11/12
else if (childNodeName.trim().equalsIgnoreCase("unit__rate"))
{
unitRate=checkNull(this.genericUtility.getColumnValue("unit__rate", dom));
......@@ -543,6 +544,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
}
}*/
}
//end of changes on 05/11/12
else if (childNodeName.trim().equalsIgnoreCase("rate"))
{
drate=checkNull(this.genericUtility.getColumnValue("rate", dom));
......@@ -558,8 +560,6 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
}
}
//end of changes on 05/11/12
else if (childNodeName.trim().equalsIgnoreCase("unit__rate"))
{
unitRate=checkNull(this.genericUtility.getColumnValue("unit__rate", dom));
......@@ -855,7 +855,6 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
parentNode = parentNodeList.item(0);
childNodeList = parentNode.getChildNodes();
valueXmlString.append("<Detail1>");
childNodeListLength = childNodeList.getLength();
do
{
......@@ -869,7 +868,6 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
ctr++;
}
while ((ctr < childNodeListLength) && (!childNodeName.equals(currentColumn)));
System.out.println("CURRENT COLUMN ["+currentColumn+"]");
if (currentColumn.trim().equalsIgnoreCase("itm_defaultedit"))
......@@ -1023,7 +1021,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
valueXmlString.append("<site_descr>").append("<![CDATA["+descr+"]]>").append("</site_descr>");
}
else if (currentColumn.trim().equalsIgnoreCase("unit__rate"))
else if (childNodeName.trim().equalsIgnoreCase("unit__rate"))
{
unitRate=checkNull(this.genericUtility.getColumnValue("unit__rate", dom));
quantity=checkDoubleNull(this.genericUtility.getColumnValue("quantity", dom));
......@@ -1172,7 +1170,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
valueXmlString.append("<supplier_sh_name>").append("<![CDATA["+shName+"]]>").append("</supplier_sh_name>");
}
else if (currentColumn.equalsIgnoreCase("proj_code"))
else if (childNodeName.equalsIgnoreCase("proj_code"))
{
projCode=checkNull(this.genericUtility.getColumnValue("proj_code", dom));
sql = "select descr from project where proj_code = ?";
......@@ -1216,20 +1214,18 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
childNodeList = parentNode.getChildNodes();
valueXmlString.append("<Detail2>");
childNodeListLength = childNodeList.getLength();
System.out.println("childNodeList"+childNodeList.getLength());
/*for (ctr = 0; ctr < childNodeListLength; ctr++)
for (ctr = 0; ctr < childNodeListLength; ctr++)
{
childNode = childNodeList.item(ctr);
childNodeName = childNode.getNodeName();*/
if (currentColumn.trim().equalsIgnoreCase("itm_default"))
childNodeName = childNode.getNodeName();
if (childNodeName.trim().equalsIgnoreCase("itm_default"))
{
}
else if (currentColumn.trim().equalsIgnoreCase("item_code"))
{
itemCode=checkNull(this.genericUtility.getColumnValue("item_code", dom));
sql = "select descr ,item_ser ,unit ,unit__pur,unit__rate ,pack_code from item where item_code = ?";
sql = "select descr ,item_ser ,unit ,unit__pur,unit__rate ,pack_code from item where item_code = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, itemCode);
rs = pstmt.executeQuery();
......@@ -1270,7 +1266,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
valueXmlString.append("<packing_descr >").append("<![CDATA["+descrPackCode+"]]>").append("</packing_descr>");
}
else if (currentColumn.trim().equalsIgnoreCase("unit__rate"))
else if (childNodeName.trim().equalsIgnoreCase("unit__rate"))
{
System.out.println("unit__rate ITEM CHANGE =");
unitRate=checkNull(this.genericUtility.getColumnValue("unit__rate", dom));
......@@ -1296,25 +1292,25 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
System.out.println("convQtyList = "+convQtyList);
convQtuomStduom = Double.parseDouble(convQtyList.get(0).toString());
//arraylist for rate stduom
//arraylist for rate stduom
ArrayList convRateList = distCommon.getConvQuantityFact(unit, unitRate, itemCode, rate, 0, conn);
convQtuomStduom = Double.parseDouble(convRateList.get(0).toString());
rateStduom = Double.parseDouble(convRateList.get(1).toString());
System.out.println("meffQty ["+convQtuomStduom+"]");
//changes done by cpandey for rate__stduom -- rateStduom
//changes done by cpandey for rate__stduom -- rateStduom
System.out.println("meffQty ["+rateStduom+"]");
valueXmlString.append("<conv__qty_stduom >").append("<![CDATA["+convQtuomStduom+"]]>").append("</conv__qty_stduom>");
//valueXmlString.append("<rate__stduom >").append("<![CDATA["+quantityStduom+"]]>").append("</rate__stduom>");
//valueXmlString.append("<rate__stduom >").append("<![CDATA["+quantityStduom+"]]>").append("</rate__stduom>");
valueXmlString.append("<rate__stduom >").append("<![CDATA["+rateStduom+"]]>").append("</rate__stduom>");
System.out.println("convRateList = "+convRateList);
System.out.println("meffQty ["+convQtuomStduom+"]");
quantityStduom = Double.parseDouble(convQtyList.get(1).toString());
System.out.println("meffQty ["+quantityStduom+"]");
//changes done by cpandey for quantity__stduom -- quantityStduom
//changes done by cpandey for quantity__stduom -- quantityStduom
valueXmlString.append("<conv__rate_stduom >").append("<![CDATA["+convQtuomStduom+"]]>").append("</conv__rate_stduom>");
// valueXmlString.append("<quantity__stduom >").append("<![CDATA["+rateStduom+"]]>").append("</quantity__stduom>");
// valueXmlString.append("<quantity__stduom >").append("<![CDATA["+rateStduom+"]]>").append("</quantity__stduom>");
valueXmlString.append("<quantity__stduom >").append("<![CDATA["+quantityStduom+"]]>").append("</quantity__stduom>");
}
......@@ -1386,7 +1382,7 @@ implements BillofQuantityICLocal, BillofQuantityICRemote
valueXmlString.append("<packing_descr >").append("<![CDATA["+descrPackCode+"]]>").append("</packing_descr>");
}
//}
}
valueXmlString.append("</Detail2>");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment