Commit 3c2d1e3f authored by agaikwad's avatar agaikwad

Changed sql condition for pricelist discount Condition


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@101606 ce508802-f39f-4f6c-b175-0d175dae99d5
parent b0edaf87
...@@ -7927,27 +7927,35 @@ public class DespatchAct extends ActionHandlerEJB implements DespatchActLocal, D ...@@ -7927,27 +7927,35 @@ public class DespatchAct extends ActionHandlerEJB implements DespatchActLocal, D
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
if (rs.next()) if (rs.next())
{ {
Count = rs.getInt("COUNT"); Count = rs.getInt(1);
} }
rs.close(); rs.close();
rs = null; rs = null;
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
System.out.println("Count in Else discount Condition"+ Count);
//ibase3-webitm-dis5-12-1-01 //ibase3-webitm-dis5-12-1-01
// if no record found in price list for I (Inventory) then continue with the current logic else check in Stock table // if no record found in price list for I (Inventory) then continue with the current logic else check in Stock table
if(Count == 0 ) if(Count == 0 )
{ {
System.out.println("Count is 0 then List type is:"+listType);
if(! "L".equalsIgnoreCase(listType)) if(! "L".equalsIgnoreCase(listType))
{ {
System.out.println("Condition True");
pickRate = distCommon.pickRate(priceList,sDespDate,itemCode,lotNo,"D",sordQuantity, conn); pickRate = distCommon.pickRate(priceList,sDespDate,itemCode,lotNo,"D",sordQuantity, conn);
System.out.println("PicRate is in else discount condition"+pickRate);
} }
} }
else else
{ {
System.out.println("Count is not zero");
String listTyp= siteCode + "@" + locCode + "@" + lotNo; String listTyp= siteCode + "@" + locCode + "@" + lotNo;
System.out.println("Listtype is "+listType);
pickRate=distCommon.pickRate(priceList, sDespDate, itemCode, listTyp, "I", sordQuantity, conn); pickRate=distCommon.pickRate(priceList, sDespDate, itemCode, listTyp, "I", sordQuantity, conn);
System.out.println("PicRate "+pickRate);
} }
} }
sConv = genericUtility.getColumnValue("conv__rtuom_stduom",dom); sConv = genericUtility.getColumnValue("conv__rtuom_stduom",dom);
...@@ -7961,7 +7969,10 @@ public class DespatchAct extends ActionHandlerEJB implements DespatchActLocal, D ...@@ -7961,7 +7969,10 @@ public class DespatchAct extends ActionHandlerEJB implements DespatchActLocal, D
{ {
conv = 1; conv = 1;
} }
System.out.println("pickRate"+pickRate);
System.out.println("conv"+conv);
rateStduom1 = pickRate * conv; rateStduom1 = pickRate * conv;
System.out.println("pickRate * conv"+rateStduom1);
valueXmlString.append("<rate__stduom isSrvCallOnChg='0'>").append("<![CDATA[").append(rateStduom1).append("]]>").append("</rate__stduom>\r\n"); valueXmlString.append("<rate__stduom isSrvCallOnChg='0'>").append("<![CDATA[").append(rateStduom1).append("]]>").append("</rate__stduom>\r\n");
setNodeValue( dom, "rate__stduom", rateStduom1 ); setNodeValue( dom, "rate__stduom", rateStduom1 );
valueXmlString.append("<conv__rtuom_stduom isSrvCallOnChg='0'>").append("<![CDATA[").append(conv).append("]]>").append("</conv__rtuom_stduom>\r\n");///13-08 valueXmlString.append("<conv__rtuom_stduom isSrvCallOnChg='0'>").append("<![CDATA[").append(conv).append("]]>").append("</conv__rtuom_stduom>\r\n");///13-08
......
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