Commit 26bbfc43 authored by rtiwari's avatar rtiwari

updated


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@94182 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 168ab2bc
...@@ -44,12 +44,9 @@ import ibase.webitm.ejb.fin.FinCommon; ...@@ -44,12 +44,9 @@ import ibase.webitm.ejb.fin.FinCommon;
@Stateless @Stateless
public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTransferPrcRemote public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTransferPrcRemote
{ {
/**
* VARIABLE ONLY FOR STK UPDATE */
//ITMDBAccessEJB itmDBAccessEJB1 = new ITMDBAccessEJB();
CommonConstants commonConstants = new CommonConstants(); CommonConstants commonConstants = new CommonConstants();
DistCommon disCommon = new DistCommon(); DistCommon disCommon = new DistCommon();
//GenericUtility genericUtility1 = GenericUtility.getInstance();
String userId = null; String userId = null;
String termId = null; String termId = null;
double quantity=0,qtyStduom=0,rate = 0,potencyPerc=0,netAmt= 0,grossWeight=0; double quantity=0,qtyStduom=0,rate = 0,potencyPerc=0,netAmt= 0,grossWeight=0;
...@@ -63,11 +60,9 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -63,11 +60,9 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
String suppCodeMfg="",grade="",batchNo="",unitAlt="",remarks="",refIdFor="",refSerFor=""; String suppCodeMfg="",grade="",batchNo="",unitAlt="",remarks="",refIdFor="",refSerFor="";
Timestamp creaDateStr=null,date=null,mfgDate=null,expDate = null,currDate=null,retestDateDate=null; Timestamp creaDateStr=null,date=null,mfgDate=null,expDate = null,currDate=null,retestDateDate=null;
Timestamp lastPhycDate=null,tranDate= null,retestDate =null; Timestamp lastPhycDate=null,tranDate= null,retestDate =null;
String suppCode=""; // added by cpatil String suppCode="";
String chgTerm="",chgUser=""; // added by cpatil String chgTerm="",chgUser="";
//
String considerAllocate = "Y", partialUsed = ""; String considerAllocate = "Y", partialUsed = "";
//
String lotSlOrg=""; String lotSlOrg="";
GenericUtility genericUtility = GenericUtility.getInstance(); GenericUtility genericUtility = GenericUtility.getInstance();
...@@ -3753,7 +3748,7 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -3753,7 +3748,7 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
} }
else if(this.tranType.equalsIgnoreCase("R")) else if(this.tranType.equalsIgnoreCase("R"))
{ {
updateStockMap = updateLotInfo( updateStockMap , conn); // added by cpatil calling function updateStockMap = updateLotInfo( updateStockMap , conn);
//if( errString != null && errString.trim().length() > 0) //if( errString != null && errString.trim().length() > 0)
//{ //{
...@@ -3928,7 +3923,7 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -3928,7 +3923,7 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
+"where item_code = '"+this.itemCode+"'" +"where item_code = '"+this.itemCode+"'"
+"and site_code = '"+this.siteCode +"'" +"and site_code = '"+this.siteCode +"'"
+"and lot_no = '"+this.lotNo+"'" +"and lot_no = '"+this.lotNo+"'"
//+"and lot_sl = '"+this.lotSl+"'" //Commented by gulzar as discussed with Manoharan sir on 05/01/12 //+"and lot_sl = '"+this.lotSl+"'"
+"and crea_date is not null "; +"and crea_date is not null ";
pstmt = conn.prepareStatement(sql); pstmt = conn.prepareStatement(sql);
rs = pstmt.executeQuery(); rs = pstmt.executeQuery();
...@@ -4235,9 +4230,9 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -4235,9 +4230,9 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
} }
}//end of stockValuation="N" }//end of stockValuation="N"
} }
catch (SQLException sqx) // 04/02/12 manoharan this catch block added for trapping record lock catch (SQLException sqx)
{ {
//Change by Rohan on 18-02-13 for throwing exception
SQLException ex ; SQLException ex ;
while (sqx != null) while (sqx != null)
...@@ -4251,18 +4246,18 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -4251,18 +4246,18 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
{ {
System.out.println("The SQLException occurs in UpdatStock [Stockupdate] getSQLState [" + sqlState + "] getErrorCode [" + errorCode + "] Exception["+sqx + "]"); System.out.println("The SQLException occurs in UpdatStock [Stockupdate] getSQLState [" + sqlState + "] getErrorCode [" + errorCode + "] Exception["+sqx + "]");
} }
//Change by Rohan on 18-02-13 for throwing exception
ex = sqx; ex = sqx;
sqx.printStackTrace(); sqx.printStackTrace();
sqx = sqx.getNextException(); sqx = sqx.getNextException();
//Change by Rohan on 18-02-13 for throwing exception.start
if(sqx == null) if(sqx == null)
{ {
sqx = ex; sqx = ex;
break; break;
} }
//Change by Rohan on 18-02-13 for throwing exception.end
} }
throw new ITMException(sqx); throw new ITMException(sqx);
...@@ -5107,7 +5102,6 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -5107,7 +5102,6 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
} }
//if isnull(s_updatestock.retest_date) then s_updatestock.retest_date = mretest_date //if isnull(s_updatestock.retest_date) then s_updatestock.retest_date = mretest_date
// System.out.println("@@@@ updateStockMap.get(retest_date) ["+updateStockMap.get("retest_date").toString()+"]"); // added by cpatil on 05-03-13 // System.out.println("@@@@ updateStockMap.get(retest_date) ["+updateStockMap.get("retest_date").toString()+"]"); // added by cpatil on 05-03-13
//change done by kunal on 30/04/13 comment SOP bug fixing
if( updateStockMap.get("retest_date")!= null && updateStockMap.get("retest_date").toString() != "01/01/1990" ) if( updateStockMap.get("retest_date")!= null && updateStockMap.get("retest_date").toString() != "01/01/1990" )
{ {
sql2 = " select available from invstat where inv_stat = ( select inv_stat from location where loc_code = ? ) "; sql2 = " select available from invstat where inv_stat = ( select inv_stat from location where loc_code = ? ) ";
...@@ -5145,7 +5139,7 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr ...@@ -5145,7 +5139,7 @@ public class WoTransferPrc extends ProcessEJB implements WoTransferPrcLocal,WoTr
pstmt2 = null; pstmt2 = null;
System.out.println("@@@@ cnt1:::"+cnt1); System.out.println("@@@@ cnt1:::"+cnt1);
} }
} // end by cpatil }
else else
{ {
if(updateStockMap.get("retest_date")== null) if(updateStockMap.get("retest_date")== null)
......
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