Commit b1932ffc authored by jshinde's avatar jshinde

Request Id: W15JSUN010

,Repalletization or pallet consolidation.


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@99929 ce508802-f39f-4f6c-b175-0d175dae99d5
parent a52305df
This diff is collapsed.
/**
* PURPOSE : Local Interface for ConsolidatePalletIC component
* AUTHOR : Jagruti Shinde
* DATE : 14-01-2016
*/
package ibase.webitm.ejb.wms;
import ibase.webitm.utility.ITMException;
import ibase.webitm.ejb.*;
import ibase.webitm.utility.ITMException;
import java.rmi.RemoteException;
import org.w3c.dom.*;
import javax.ejb.*;
@javax.ejb.Local
public interface ConsolidatePalletICLocal extends ValidatorLocal
{
public String wfValData() throws RemoteException, ITMException;
public String wfValData(String xmlString, String xmlString1, String xmlString2, String objContext,String editFlag, String xtraParams) throws RemoteException, ITMException;
public String wfValData(Document dom, Document dom1, Document dom2, String objContext, String xtraParams,String editFlag) throws RemoteException, ITMException;
public String itemChanged() throws RemoteException, ITMException;
public String itemChanged(String xmlString, String xmlString1, String xmlString2, String objContext, String currentColumn, String editFlag, String xtraParams) throws RemoteException, ITMException;
public String itemChanged( Document currFormDataDom, Document hdrDataDom, Document allFormDataDom, String objContext, String currentColumn,String editFlag, String xtraParams ) throws RemoteException,ITMException;
}
/**
* PURPOSE : Remote Interface for ConsolidatePalletIC component
* AUTHOR : Jagruti Shinde
* DATE : 14-01-2016
*/
package ibase.webitm.ejb.wms;
import ibase.webitm.utility.ITMException;
import ibase.webitm.ejb.*;
import ibase.webitm.utility.ITMException;
import java.rmi.RemoteException;
import org.w3c.dom.*;
import javax.ejb.*;
@javax.ejb.Remote
public interface ConsolidatePalletICRemote extends ValidatorRemote
{
public String wfValData() throws RemoteException, ITMException;
public String wfValData(String xmlString, String xmlString1, String xmlString2, String objContext,String editFlag, String xtraParams) throws RemoteException, ITMException;
public String wfValData(Document dom, Document dom1, Document dom2, String objContext, String xtraParams,String editFlag) throws RemoteException, ITMException;
public String itemChanged() throws RemoteException, ITMException;
public String itemChanged(String xmlString, String xmlString1, String xmlString2, String objContext, String currentColumn, String editFlag, String xtraParams) throws RemoteException, ITMException;
public String itemChanged( Document currFormDataDom, Document hdrDataDom, Document allFormDataDom, String objContext, String currentColumn,String editFlag, String xtraParams ) throws RemoteException,ITMException;
}
......@@ -19,7 +19,7 @@ import javax.ejb.Stateless;
@Stateless
public class PalletReqConf extends ActionHandlerEJB
implements PalletReqConfLocal, PalletReqConfRemote
implements PalletReqConfLocal, PalletReqConfRemote
{
String loginEmpCode = "";
String confDateStr = "";
......@@ -66,7 +66,7 @@ public class PalletReqConf extends ActionHandlerEJB
String lineNo = ""; String itemCode = ""; String lotNo = ""; String lotSl = ""; String noArt = ""; String quantity = "";
String empCodeAprv = ""; String siteCode = "";
String loginSite = ""; String qtyPerArt = ""; String refSer = "PRS";
String descr = ""; String unit = ""; String itemType = ""; String mfgDate = ""; String expiryDate = "";
String descr = "",unit = "",itemType = "",mfgDate = "", expiryDate = "",tranType="";
ArrayList palletList = new ArrayList();
ArrayList lineList = new ArrayList();
int cntPal = 0;
......@@ -154,7 +154,7 @@ public class PalletReqConf extends ActionHandlerEJB
pstmt = null;
}
sql = "SELECT D.PALLET_NO ,D.LINE_NO,D.ITEM_CODE,D.LOT_NO,D.LOT_SL,D.NO_ART,D.QUANTITY FROM PALLET_REQ_DET D WHERE TRAN_ID=?";
sql = "SELECT D.PALLET_NO ,D.LINE_NO,D.ITEM_CODE,D.LOT_NO,D.LOT_SL,D.NO_ART,D.QUANTITY ,H.TRAN_TYPE FROM PALLET_REQ_DET D ,PALLET_REQ_HDR H WHERE D.TRAN_ID = H.TRAN_ID AND D.TRAN_ID=?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, tranId);
......@@ -177,7 +177,14 @@ public class PalletReqConf extends ActionHandlerEJB
noArt = checkNullAndTrim(rs.getString("NO_ART"));
quantity = checkNullAndTrim(rs.getString("QUANTITY"));
lineNo = checkNullAndTrim(rs.getString("LINE_NO"));
tranType=checkNullAndTrim(rs.getString("TRAN_TYPE"));
System.out.println("Tran Type="+tranType);
//if((tranType == null) && (tranType.length() == 0))
if(tranType == null || tranType.length() == 0)
{
System.out.println(" in null trantype");
if ((itemCode != null) && (itemCode.length() > 0))
{
sql = "SELECT S.QTY_PER_ART,I.DESCR ,S.UNIT,I.ITEM_TYPE ,S.MFG_DATE,S.EXP_DATE FROM STOCK S ,ITEM I WHERE S.SITE_CODE=? AND S.LOC_CODE IN (?,?) AND S.ITEM_CODE= ? AND S.LOT_NO= ? AND S.LOT_SL= ? AND S.ITEM_CODE=I.ITEM_CODE";
......@@ -231,7 +238,7 @@ public class PalletReqConf extends ActionHandlerEJB
hm.put("STRO_PREF", "");
interfaceArrList.add(hm);
System.out.println("interfacearraylist" + interfaceArrList.size());
System.out.println("interfacearraylist::PRS" + interfaceArrList.size());
}
rs1.close();
pstmt1.close();
......@@ -262,7 +269,37 @@ public class PalletReqConf extends ActionHandlerEJB
hm.put("STRO_PREF", "");
interfaceArrList.add(hm);
System.out.println("interfacearraylist" + interfaceArrList.size());
System.out.println("interfacearraylist::PR" + interfaceArrList.size());
}
}//IF TRAN_TYPE END
else
{
System.out.println(" in rpz trantype");
HashMap hm = new HashMap();
hm.put("REF_ID", tranId);
hm.put("REF_SER", "RPZ");
hm.put("TRAN_DATE", checkNullAndTrim(String.valueOf(today)));
hm.put("PALLET_NO", palletNo);
hm.put("LINE_NO", lineNo);
hm.put("DESCR", "");
hm.put("UNIT", "");
hm.put("ITEM_TYPE", "");
hm.put("FAMILY_GRP", "");
hm.put("TRAN_ID", "");
hm.put("IN_OUT", "R");
hm.put("EXP_DATE", "");
hm.put("MFG_DATE", "");
hm.put("PALLET_STATUS", palletStatus);
hm.put("MSG_STAT", "N");
hm.put("LOCK_STAT", "");
hm.put("ERR_COD", "");
hm.put("ERR_DESC", "");
hm.put("QC_TYPE", "");
hm.put("TRANS_DT_ACK", "");
hm.put("STRO_PREF", "");
interfaceArrList.add(hm);
System.out.println("interfacearraylist::RPZ" + interfaceArrList.size());
}
}
rs.close();
......@@ -303,30 +340,6 @@ public class PalletReqConf extends ActionHandlerEJB
throw new ITMException(e);
}
}
/*try
{
int count;
System.out.println("is error in finally" + isError);
if (isError)
{
conn.rollback();
}
else
{
conn.commit();
errString = itmdbAccess.getErrorString("", "VMTRANSACN", "", "", conn);
}
if (conn != null)
{
conn.close();
conn = null;
}
}
catch (Exception e)
{
e.printStackTrace();
throw new ITMException(e);
}*/
return errString;
}
......
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