Commit 51c111be authored by jshinde's avatar jshinde

Request ID:W15GSUN001 Create transaction screen Pallet Request .


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@98798 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 07d9c221
......@@ -112,7 +112,7 @@ public class PalletReqIC extends ValidatorEJB implements PalletReqICLocal, Palle
double stockhold=0;
ResultSet rs= null;
String loginSite = "";
ArrayList locList = new ArrayList();
ArrayList<String> palletList = new ArrayList();
PreparedStatement pstmt = null;
int palletCount = 0;
Connection conn = null;
......@@ -233,17 +233,28 @@ public class PalletReqIC extends ValidatorEJB implements PalletReqICLocal, Palle
System.out.println("DOM2----->>["+genericUtility.serializeDom(dom2).toString()+"]");
parentNodeList = dom2.getElementsByTagName("Detail2");
parentNode = parentNodeList.item(0);
for(int intPrnt = 0;intPrnt < parentNodeList.getLength();intPrnt++)
{
parentNode = parentNodeList.item(intPrnt);
childNodeList = parentNode.getChildNodes();
childNodeListLength = childNodeList.getLength();
for (ctr = 0; ctr < childNodeListLength; ctr++)
{
childNode = childNodeList.item(ctr);
childNodeName = childNode.getNodeName();
String palletNo = checkNullAndTrim(genericUtility.getColumnValue("pallet_no",dom));
String tranId = checkNullAndTrim(genericUtility.getColumnValue("tran_id",dom2));
System.out.println("TRAN ID" +tranId);
System.out.println("PALLET" +palletNo);
if("pallet_no".equalsIgnoreCase(childNodeName))
{
if(childNode.getFirstChild()!=null)
{
palletNo = childNode.getFirstChild().getNodeValue();
}
if( "E".equalsIgnoreCase(editFlag) || "A".equalsIgnoreCase(editFlag))
{
if(palletNo.length() == 0 || palletNo.equalsIgnoreCase(""))
......@@ -273,26 +284,39 @@ public class PalletReqIC extends ValidatorEJB implements PalletReqICLocal, Palle
errList.add( errCode );
errFields.add( childNodeName.toLowerCase() );
}
else
{
System.out.println("AFTER ELSE" +palletList);
for(int i=0;i<palletList.size();i++)
{
System.out.println("palletarray"+palletList.get(i));
}
if(palletList.contains(palletNo))
{
System.out.println("PALLETNO>>>>>>>" +palletNo);
errCode = "VMPALLETSM";//pallet no same
errList.add( errCode );
errFields.add( childNodeName.toLowerCase() );
}
else
{
palletList.add(palletNo);
System.out.println("ADD PALLET" +palletNo);
}
}
}
rs.close();
pstmt.close();
}
}
}
else if("loc_code".equalsIgnoreCase(childNodeName))
{
String locCodeHeader = checkNullAndTrim(genericUtility.getColumnValue("loc_code",dom1));
String locCodeDetail = checkNullAndTrim(genericUtility.getColumnValue("loc_code",dom2));
System.out.println("LOC CODE>locCodeDetail>>>>>>" +locCodeDetail);
System.out.println("LOC CODE>locCodeHeader>>>>>>" +locCodeHeader);
if(!(locCodeHeader.equals(locCodeDetail)))
{
errCode = "VMLOCATSAM";//Entered Location Code in detail form should be same as header form
errList.add( errCode );
errFields.add( childNodeName.toLowerCase() );
}
}
}//FOR LOOP end
break;
} //switch end
......
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