Commit b1acb1f7 authored by cshah's avatar cshah

DI90SUN041 - partial quantity is set as X when it is null


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@91356 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 736a70f6
...@@ -673,7 +673,8 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct ...@@ -673,7 +673,8 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct
// END VALIDATTION CODE - // END VALIDATTION CODE -
//Added on 25/10/06 //Added on 25/10/06
String varValue = "",stkExpLoc = ""; String varValue = "",stkExpLoc = "";
varValue = itmDBAccess.getEnvDis("999999","NEAREXP_LOC",null); //varValue = itmDBAccess.getEnvDis("999999","NEAREXP_LOC",null);
varValue = itmDBAccess.getEnvDis("999999","NEAREXP_LOC",conn);
if(varValue != null && varValue.trim().length() > 0 && !(varValue.equalsIgnoreCase("NULLFOUND"))) if(varValue != null && varValue.trim().length() > 0 && !(varValue.equalsIgnoreCase("NULLFOUND")))
{ {
stkExpLoc = varValue; stkExpLoc = varValue;
...@@ -728,14 +729,14 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct ...@@ -728,14 +729,14 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct
//Changes done by Chandni shah -01/09/10 //Changes done by Chandni shah -01/09/10
if(partQuantity == null || partQuantity.trim().length()== 0) // partial quantity is set as X when it is null if(partQuantity == null || partQuantity.trim().length()== 0) // partial quantity is set as X when it is null
{ {
partQuantity = "X"; partQuantity = " ";
} }
if (locCode == null || "null".equalsIgnoreCase(locCode) || locCode.trim().length() == 0) if (locCode == null || "null".equalsIgnoreCase(locCode) || locCode.trim().length() == 0)
{ {
System.out.println("If locCode = null || length() == 0"); System.out.println("If locCode = null || length() == 0");
locCode = "%"; locCode = "%";
System.out.println("If locCode is null then [%] :"+locCode); System.out.println("If locCodelocCode is null then [%] :" +locCode);
} }
if (lotNo == null || lotNo.trim().length() == 0) if (lotNo == null || lotNo.trim().length() == 0)
// The stock join location master and join invstat with location master inv_st, // The stock join location master and join invstat with location master inv_st,
...@@ -749,7 +750,8 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct ...@@ -749,7 +750,8 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct
+"AND A.SITE_CODE = '"+siteCodeReq+"' " +"AND A.SITE_CODE = '"+siteCodeReq+"' "
+"AND B.AVAILABLE = '"+availableYn+"' " +"AND B.AVAILABLE = '"+availableYn+"' "
+"AND A.QUANTITY > 0 " +"AND A.QUANTITY > 0 "
+"AND A.LOC_CODE LIKE '"+locCode+"' "; +"AND A.LOC_CODE LIKE '"+locCode+"' ";
System.out.println("locCode in query ===" + locCode );
} }
//Added by Chandni shah -01/09/10 //Added by Chandni shah -01/09/10
...@@ -764,7 +766,7 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct ...@@ -764,7 +766,7 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct
+"AND A.LOC_CODE = '"+locCode+"' " +"AND A.LOC_CODE = '"+locCode+"' "
+"AND A.LOT_NO = '"+lotNo+"' " +"AND A.LOT_NO = '"+lotNo+"' "
+"AND A.LOT_SL = '"+lotSl+"' " +"AND A.LOT_SL = '"+lotSl+"' "
+"AND (A.QUANTITY - A.ALLOC_QTY) >="+quantity +"AND (A.QUANTITY - A.ALLOC_QTY) >="+quantity+"'"
+" AND B.AVAILABLE = '"+availableYn+"'"; +" AND B.AVAILABLE = '"+availableYn+"'";
}// }//
System.out.println("sql :"+sql); System.out.println("sql :"+sql);
...@@ -778,8 +780,10 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct ...@@ -778,8 +780,10 @@ public class ConsumeIssueAct extends ActionHandlerEJB implements ConsumeIssueAct
//cctrCode = rs.getString(3);// //cctrCode = rs.getString(3);//
//System.out.println("cctrCode :"+cctrCode);// //System.out.println("cctrCode :"+cctrCode);//
} }
//Changes done by Chandni shah -01/09/10 //Changes done by Chandni shah -01/09/10
if (stockQuantity == 0 && "X".equals(partQuantity))
if (stockQuantity == 0 && "X".equals (partQuantity))
{ {
errCode = "VTNOSTK"; errCode = "VTNOSTK";
errString = itmDBAccess.getErrorString("",errCode,"","",conn); errString = itmDBAccess.getErrorString("",errCode,"","",conn);
......
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