Commit 5e2aaad9 authored by rbhogale's avatar rbhogale

Changed by Rohan on 29-may-13 for validation of location in active picking


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@93171 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 3a5672d0
...@@ -2369,6 +2369,10 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC ...@@ -2369,6 +2369,10 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
int noOfLocCode = 0; int noOfLocCode = 0;
NodeList locCodeNodeList = null; NodeList locCodeNodeList = null;
HashMap<String, String> locCodeList = new HashMap<String, String>(); HashMap<String, String> locCodeList = new HashMap<String, String>();
String itemCode1 = "";
String lotNo1 = "";
String locKeyVal = "";
String[] temp ;
//Changed by Rohan on 26-04-13 for define variable.end //Changed by Rohan on 26-04-13 for define variable.end
childList = parentList.item(0).getChildNodes(); childList = parentList.item(0).getChildNodes();
...@@ -2757,21 +2761,62 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC ...@@ -2757,21 +2761,62 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
if ( locCodeNodeList.item( idx ).getFirstChild() != null ) if ( locCodeNodeList.item( idx ).getFirstChild() != null )
{ {
currentLoction = GenericUtility.getInstance().getColumnValueFromNode("loc_code__to",locCodeNodeList.item(idx)).trim(); currentLoction = GenericUtility.getInstance().getColumnValueFromNode("loc_code__to",locCodeNodeList.item(idx)).trim();
System.out.println("Current location["+currentLoction); itemCode1 = GenericUtility.getInstance().getColumnValueFromNode("item_code",locCodeNodeList.item(idx)).trim();
if(!locCodeList.containsKey(currentLoction)) lotNo1 = GenericUtility.getInstance().getColumnValueFromNode("lot_no",locCodeNodeList.item(idx)).trim();
System.out.println("Current location["+currentLoction+"itemCode1"+itemCode1+"lotNo1"+lotNo1);
//Chnaged by Rohan on 29-05-13 for bug fixing.start
if(singleLotSl.trim().equalsIgnoreCase("Y"))
{
if(!locCodeList.containsKey(currentLoction))
{
locCodeList.put(currentLoction,"ACTLOC");
}
else
{
errList.add( "DUPLOCCODE" );
errFields.add( childNodeName.toLowerCase() );
}
}
//Chnaged by Rohan on 29-05-13 for bug fixing.start
else if(itemLotOpt.trim().equalsIgnoreCase("0"))
{ {
locCodeList.put(currentLoction,"ACTLOC"); if(!locCodeList.containsKey(currentLoction))
System.out.println("Additing location to list"+currentLoction); {
locCodeList.put(currentLoction,itemCode1+":"+lotNo1);
}
else
{
locKeyVal = locCodeList.get(currentLoction);
temp = locKeyVal.split(":");
if(!temp[0].trim().equalsIgnoreCase(itemCode1.trim()) || !temp[1].trim().equalsIgnoreCase(lotNo1.trim()))
{
errList.add( "SNGIEMLOT" );
errFields.add( childNodeName.toLowerCase() );
}
}
} }
else else
{ {
errList.add( "DUPLOCCODE" ); if(!locCodeList.containsKey(currentLoction))
errFields.add( childNodeName.toLowerCase() ); {
locCodeList.put(currentLoction,itemCode1);
}
else
{
locKeyVal = locCodeList.get(currentLoction);
if(!locKeyVal.trim().equalsIgnoreCase(itemCode1.trim()))
{
errList.add( "SGITMMULLT" );
errFields.add( childNodeName.toLowerCase() );
}
}
} }
} //Chnaged by Rohan on 29-05-13 for bug fixing.end
} }
} }
} }
}
//Changed by Rohan on 26-03-13 for define validation out of singleLotSl validation.end //Changed by Rohan on 26-03-13 for define validation out of singleLotSl validation.end
sql = "SELECT RIH.CONFIRMED FROM REPL_ISS_HDR RIH, REPL_ISS_DET RID" sql = "SELECT RIH.CONFIRMED FROM REPL_ISS_HDR RIH, REPL_ISS_DET RID"
+ " WHERE RIH.TRAN_ID = RID.TRAN_ID AND RID.ITEM_CODE = ?" + " WHERE RIH.TRAN_ID = RID.TRAN_ID AND RID.ITEM_CODE = ?"
......
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