Commit ee5dce63 authored by msingh's avatar msingh

Changed by Manish on 21/04/16


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@101348 ce508802-f39f-4f6c-b175-0d175dae99d5
parent d93ac192
...@@ -2,10 +2,10 @@ package ibase.webitm.ejb.wms; ...@@ -2,10 +2,10 @@ package ibase.webitm.ejb.wms;
import ibase.system.config.ConnDriver; import ibase.system.config.ConnDriver;
import ibase.utility.CommonConstants; import ibase.utility.CommonConstants;
import ibase.utility.E12GenericUtility;
import ibase.webitm.ejb.ITMDBAccessEJB; import ibase.webitm.ejb.ITMDBAccessEJB;
import ibase.webitm.ejb.dis.DistCommon; import ibase.webitm.ejb.dis.DistCommon;
import ibase.webitm.reports.utility.XSDParser; import ibase.webitm.reports.utility.XSDParser;
import ibase.utility.E12GenericUtility;
import ibase.webitm.utility.ITMException; import ibase.webitm.utility.ITMException;
import java.io.File; import java.io.File;
...@@ -93,7 +93,8 @@ public class ConsolidatToDoc { ...@@ -93,7 +93,8 @@ public class ConsolidatToDoc {
Timestamp mfgDate = null, expDate = null, retestDate = null; Timestamp mfgDate = null, expDate = null, retestDate = null;
DistCommon disCommon = new DistCommon(); DistCommon disCommon = new DistCommon();
ConnDriver connDriver = null;
Connection tempConn = null; //Added by Manish on 19/04/16
try try
{ {
System.out.println("*********inside try block** CONSOLIDATE TO DOCK *****"); System.out.println("*********inside try block** CONSOLIDATE TO DOCK *****");
...@@ -1069,13 +1070,19 @@ public class ConsolidatToDoc { ...@@ -1069,13 +1070,19 @@ public class ConsolidatToDoc {
//Changed by Dhanraj on 19-SEP-14 for update despatch tare and filler weight [W14FSUN003] //Changed by Dhanraj on 19-SEP-14 for update despatch tare and filler weight [W14FSUN003]
System.out.println("PTCN ======For updatedespatch method====>> "+ptcn); System.out.println("PTCN ======For updatedespatch method====>> "+ptcn);
errString = updatedespatch(ptcn, conn); //Changed by Manish on 19/04/16 [start]
connDriver = new ConnDriver();
tempConn = connDriver.getConnectDB("DriverITM");
connDriver = null;
errString = updatedespatch(ptcn, tempConn);
//Changed by Manish on 19/04/16 [end]
//Changed by Dharnaj on 19-SEP-14 for [W14FSUN003] //Changed by Dharnaj on 19-SEP-14 for [W14FSUN003]
//sqlHdr = "update despatch set gross_weight = ?, tare_weight = ? ,nett_weight = ?, no_art = ? where desp_id = ? "; //added by Kunal on 08/09/12 as per S Manoharan Sir instruction //sqlHdr = "update despatch set gross_weight = ?, tare_weight = ? ,nett_weight = ?, no_art = ? where desp_id = ? "; //added by Kunal on 08/09/12 as per S Manoharan Sir instruction
sqlHdr = "update despatch set gross_weight = ?, tare_weight = tare_weight + ? ,nett_weight = ?, no_art = ? where desp_id = ? "; //added by Kunal on 08/09/12 as per S Manoharan Sir instruction sqlHdr = "update despatch set gross_weight = ?, tare_weight = tare_weight + ? ,nett_weight = ?, no_art = ? where desp_id = ? "; //added by Kunal on 08/09/12 as per S Manoharan Sir instruction
pstmtHdr = conn.prepareStatement(sqlHdr); // pstmtHdr = conn.prepareStatement(sqlHdr);
pstmtHdr = tempConn.prepareStatement(sqlHdr);
pstmtHdr.setDouble(1, totalGrossWeight); pstmtHdr.setDouble(1, totalGrossWeight);
pstmtHdr.setDouble(2, totalTareWeight); pstmtHdr.setDouble(2, totalTareWeight);
pstmtHdr.setDouble(3, totalNetWeight); pstmtHdr.setDouble(3, totalNetWeight);
...@@ -1083,9 +1090,18 @@ public class ConsolidatToDoc { ...@@ -1083,9 +1090,18 @@ public class ConsolidatToDoc {
pstmtHdr.setString(5, despId); pstmtHdr.setString(5, despId);
int upctr = pstmtHdr.executeUpdate(); int upctr = pstmtHdr.executeUpdate();
System.out.println("NO OF ROW UPDATED = "+upctr); System.out.println("NO OF ROW UPDATED = "+upctr);
if(upctr>0)
{
tempConn.commit();
}
else
{
tempConn.rollback();
}
pstmtHdr.close(); pstmtHdr.close();
pstmtHdr = null; pstmtHdr = null;
tempConn.close();
tempConn = null;
System.out.println("***************START***********************"); System.out.println("***************START***********************");
//Changed by Rohan on 10-06-12 to get reports for hazardous material.start //Changed by Rohan on 10-06-12 to get reports for hazardous material.start
...@@ -1155,7 +1171,34 @@ public class ConsolidatToDoc { ...@@ -1155,7 +1171,34 @@ public class ConsolidatToDoc {
tempList1 = (ArrayList)dataMap.get(keyList); tempList1 = (ArrayList)dataMap.get(keyList);
pstmt2 = conn.prepareStatement(sql2); pstmt2 = conn.prepareStatement(sql2);
//Changed by Manish on 19/04/16 [start]
sqlTran = "SELECT TRANS_MODE FROM DESPATCH WHERE DESP_ID IN(SELECT REF_ID FROM WAVE_TASK_DET "
+" WHERE WAVE_ID = ? AND REF_SER = ? AND PTCN = ? )";
pstmtitem = conn.prepareStatement(sqlTran);
pstmtitem.setString(1,waveId);
pstmtitem.setString(2,"S-DSP");
pstmtitem.setString(3,ptcn);
rsitem = pstmtitem.executeQuery();
if(rsitem.next())
{
tranMode = rsitem.getString("TRANS_MODE") == null?"":rsitem.getString("TRANS_MODE");
System.out.println("tranMode*****"+tranMode);
}
if(pstmtitem != null)
{
pstmtitem.close();
pstmtitem = null;
}
if(rsitem != null)
{
rsitem.close();
rsitem = null;
}
//Changed by Manish on 19/04/16 [end]
int orderLen = tempList1.size(); int orderLen = tempList1.size();
if ( orderLen > 0 ) if ( orderLen > 0 )
{ {
...@@ -1197,7 +1240,7 @@ public class ConsolidatToDoc { ...@@ -1197,7 +1240,7 @@ public class ConsolidatToDoc {
} }
//to check item is hazarous.end //to check item is hazarous.end
//to check transporter mode.start //to check transporter mode.start
sqlTran = "SELECT TRANS_MODE FROM DESPATCH WHERE DESP_ID IN(SELECT REF_ID FROM WAVE_TASK_DET " /*sqlTran = "SELECT TRANS_MODE FROM DESPATCH WHERE DESP_ID IN(SELECT REF_ID FROM WAVE_TASK_DET "
+" WHERE WAVE_ID = ? AND REF_SER = ? AND PTCN = ? )"; +" WHERE WAVE_ID = ? AND REF_SER = ? AND PTCN = ? )";
pstmtitem = conn.prepareStatement(sqlTran); pstmtitem = conn.prepareStatement(sqlTran);
...@@ -1221,7 +1264,7 @@ public class ConsolidatToDoc { ...@@ -1221,7 +1264,7 @@ public class ConsolidatToDoc {
{ {
rsitem.close(); rsitem.close();
rsitem = null; rsitem = null;
} }*/
//to check transporter mode.end //to check transporter mode.end
if("Y".equalsIgnoreCase(hazMaterial) && "A".equalsIgnoreCase(tranMode)) if("Y".equalsIgnoreCase(hazMaterial) && "A".equalsIgnoreCase(tranMode))
{ {
...@@ -1837,6 +1880,7 @@ public class ConsolidatToDoc { ...@@ -1837,6 +1880,7 @@ public class ConsolidatToDoc {
String outputFilename = ""; String outputFilename = "";
TreeMap argMap = null; TreeMap argMap = null;
DistCommon discommon = new DistCommon(); DistCommon discommon = new DistCommon();
//GenericUtility genericUtility = GenericUtility.getInstance();
E12GenericUtility genericUtility = new E12GenericUtility(); E12GenericUtility genericUtility = new E12GenericUtility();
try try
{ {
......
...@@ -10,11 +10,12 @@ import ibase.webitm.ejb.*; ...@@ -10,11 +10,12 @@ import ibase.webitm.ejb.*;
import ibase.webitm.ejb.dis.DistCommon; import ibase.webitm.ejb.dis.DistCommon;
import ibase.webitm.ejb.dis.InvAllocTraceBean; import ibase.webitm.ejb.dis.InvAllocTraceBean;
import ibase.webitm.ejb.dis.StockUpdate; import ibase.webitm.ejb.dis.StockUpdate;
import ibase.utility.E12GenericUtility; import ibase.webitm.utility.GenericUtility;
import ibase.webitm.utility.ITMException; import ibase.webitm.utility.ITMException;
import ibase.webitm.ejb.ITMDBAccessEJB; import ibase.webitm.ejb.ITMDBAccessEJB;
import ibase.webitm.utility.TransIDGenerator; import ibase.webitm.utility.TransIDGenerator;
import ibase.utility.CommonConstants; import ibase.utility.CommonConstants;
import ibase.utility.E12GenericUtility;
import java.io.*; import java.io.*;
import java.rmi.RemoteException; import java.rmi.RemoteException;
...@@ -56,6 +57,7 @@ public class DockTranConf extends ValidatorEJB implements DockTranConfLocal,Dock ...@@ -56,6 +57,7 @@ public class DockTranConf extends ValidatorEJB implements DockTranConfLocal,Dock
java.sql.Timestamp expDate = null,mfgDate = null,restestDate = null; java.sql.Timestamp expDate = null,mfgDate = null,restestDate = null;
Document dom = null; Document dom = null;
E12GenericUtility genericUtility = new E12GenericUtility(); E12GenericUtility genericUtility = new E12GenericUtility();
java.util.Date currDate1 = new java.util.Date(); java.util.Date currDate1 = new java.util.Date();
...@@ -399,8 +401,10 @@ public class DockTranConf extends ValidatorEJB implements DockTranConfLocal,Dock ...@@ -399,8 +401,10 @@ public class DockTranConf extends ValidatorEJB implements DockTranConfLocal,Dock
strAllocate.put("lot_no",lotNo); strAllocate.put("lot_no",lotNo);
strAllocate.put("lot_sl",lotSl); strAllocate.put("lot_sl",lotSl);
strAllocate.put("alloc_qty",new Double(quantity)); strAllocate.put("alloc_qty",new Double(quantity));
strAllocate.put("chg_user",genericUtility.getValueFromXTRA_PARAMS(xtraParams,"loginCode")); /*strAllocate.put("chg_user",GenericUtility.getInstance().getValueFromXTRA_PARAMS(xtraParams,"loginCode"));
strAllocate.put("chg_term",genericUtility.getValueFromXTRA_PARAMS(xtraParams,"termId")); strAllocate.put("chg_term",GenericUtility.getInstance().getValueFromXTRA_PARAMS(xtraParams,"termId"));*/
strAllocate.put("chg_user",new E12GenericUtility().getValueFromXTRA_PARAMS(xtraParams,"loginCode"));
strAllocate.put("chg_term",new E12GenericUtility().getValueFromXTRA_PARAMS(xtraParams,"termId"));
strAllocate.put("chg_win","w_pick_iss"); strAllocate.put("chg_win","w_pick_iss");
//} //}
...@@ -824,6 +828,13 @@ public class DockTranConf extends ValidatorEJB implements DockTranConfLocal,Dock ...@@ -824,6 +828,13 @@ public class DockTranConf extends ValidatorEJB implements DockTranConfLocal,Dock
pstmtUpd.setString(2, pickisstranId); pstmtUpd.setString(2, pickisstranId);
pstmtUpd.setInt(3, lineNo); pstmtUpd.setInt(3, lineNo);
updCnt = pstmtUpd.executeUpdate(); updCnt = pstmtUpd.executeUpdate();
//Changes by Manish on 21/04/16 [start]
if(pstmtUpd != null)
{
pstmtUpd.close();
pstmtUpd = null;
}
//Changes by Manish on 21/04/16 [end]
} }
if(rs != null) if(rs != null)
{ {
......
...@@ -6,6 +6,7 @@ package ibase.webitm.ejb.wms; ...@@ -6,6 +6,7 @@ package ibase.webitm.ejb.wms;
import ibase.system.config.ConnDriver; import ibase.system.config.ConnDriver;
import ibase.utility.CommonConstants; import ibase.utility.CommonConstants;
import ibase.utility.E12GenericUtility;
import ibase.webitm.bean.wms.ShipmentStatus; import ibase.webitm.bean.wms.ShipmentStatus;
import ibase.webitm.ejb.ITMDBAccessEJB; import ibase.webitm.ejb.ITMDBAccessEJB;
import ibase.webitm.ejb.MasterStatefulLocal; import ibase.webitm.ejb.MasterStatefulLocal;
...@@ -14,7 +15,6 @@ import ibase.webitm.ejb.dis.DistCommon; ...@@ -14,7 +15,6 @@ import ibase.webitm.ejb.dis.DistCommon;
import ibase.webitm.ejb.dis.InvAllocTraceBean; import ibase.webitm.ejb.dis.InvAllocTraceBean;
import ibase.webitm.ejb.fin.FinCommon; import ibase.webitm.ejb.fin.FinCommon;
import ibase.webitm.reports.utility.XSDParser; import ibase.webitm.reports.utility.XSDParser;
import ibase.utility.E12GenericUtility;
import ibase.webitm.utility.ITMException; import ibase.webitm.utility.ITMException;
import ibase.webitm.utility.TransIDGenerator; import ibase.webitm.utility.TransIDGenerator;
import ibase.webitm.utility.wms.CommonWmsUtil; import ibase.webitm.utility.wms.CommonWmsUtil;
...@@ -6316,8 +6316,10 @@ public class WaveGenerationPrc extends ProcessEJB implements WaveGenerationPrcLo ...@@ -6316,8 +6316,10 @@ public class WaveGenerationPrc extends ProcessEJB implements WaveGenerationPrcLo
strAllocate.put("lot_no",lotNo); strAllocate.put("lot_no",lotNo);
strAllocate.put("lot_sl",lotSl); strAllocate.put("lot_sl",lotSl);
strAllocate.put("alloc_qty",new Double(lotQtyToBeAllocated)); strAllocate.put("alloc_qty",new Double(lotQtyToBeAllocated));
strAllocate.put("chg_user",genericUtility.getValueFromXTRA_PARAMS(xtraParams,"loginCode")); /*strAllocate.put("chg_user",GenericUtility.getInstance().getValueFromXTRA_PARAMS(xtraParams,"loginCode"));
strAllocate.put("chg_term",genericUtility.getValueFromXTRA_PARAMS(xtraParams,"termId")); strAllocate.put("chg_term",GenericUtility.getInstance().getValueFromXTRA_PARAMS(xtraParams,"termId"));*/
strAllocate.put("chg_user",new E12GenericUtility().getValueFromXTRA_PARAMS(xtraParams,"loginCode"));
strAllocate.put("chg_term",new E12GenericUtility().getValueFromXTRA_PARAMS(xtraParams,"termId"));
strAllocate.put("chg_win","W_WAVEGEN"); strAllocate.put("chg_win","W_WAVEGEN");
...@@ -7192,7 +7194,13 @@ public class WaveGenerationPrc extends ProcessEJB implements WaveGenerationPrcLo ...@@ -7192,7 +7194,13 @@ public class WaveGenerationPrc extends ProcessEJB implements WaveGenerationPrcLo
} }
//Changes by Dadaso pawar on 17/03/15 [End] //Changes by Dadaso pawar on 17/03/15 [End]
pstmt.executeUpdate(); pstmt.executeUpdate();
//Changes by Manish on 21/04/16 [start]
if(pstmt != null)
{
pstmt.close();
pstmt = null;
}
//Changes by Manish on 21/04/16 [End]
System.out.println("Start Wave Genartion......................."); System.out.println("Start Wave Genartion.......................");
invStatLoc = discommon.getDisparams("999999","RESERV_LOCATION",conn); invStatLoc = discommon.getDisparams("999999","RESERV_LOCATION",conn);
...@@ -17342,7 +17350,7 @@ public class WaveGenerationPrc extends ProcessEJB implements WaveGenerationPrcLo ...@@ -17342,7 +17350,7 @@ public class WaveGenerationPrc extends ProcessEJB implements WaveGenerationPrcLo
boolean isOdd = false; boolean isOdd = false;
int sumOdd = 0, sumEven = 0; int sumOdd = 0, sumEven = 0;
String inputStr = "", sscc18 = "", runNumberStr =""; //mfgCode = "0351672", String inputStr = "", sscc18 = "", runNumberStr =""; //mfgCode = "0351672",
//ibase.utility.E12GenericUtility genUtility = ibase.utility.new E12GenericUtility(); //ibase.utility.GenericUtility genUtility = ibase.utility.GenericUtility.getInstance();
int ctr, curDigit = 0, chkDigit = 0, padLen = 0; // runNumber = 4967235 int ctr, curDigit = 0, chkDigit = 0, padLen = 0; // runNumber = 4967235
try try
{ {
......
package ibase.webitm.utility.wms; package ibase.webitm.utility.wms;
import ibase.system.config.ConnDriver; import ibase.system.config.ConnDriver;
import ibase.utility.CommonConstants; import ibase.utility.CommonConstants;
import ibase.utility.E12GenericUtility;
import ibase.utility.EMail; import ibase.utility.EMail;
import ibase.webitm.bean.wms.Attribute; import ibase.webitm.bean.wms.Attribute;
import ibase.webitm.bean.wms.PaypalParameters; import ibase.webitm.bean.wms.PaypalParameters;
import ibase.webitm.bean.wms.PaypalRefundParams; import ibase.webitm.bean.wms.PaypalRefundParams;
import ibase.webitm.bean.wms.Product; import ibase.webitm.bean.wms.Product;
import ibase.webitm.bean.wms.ShipmentStatus; import ibase.webitm.bean.wms.ShipmentStatus;
import ibase.utility.E12GenericUtility;
import ibase.webitm.utility.ITMException; import ibase.webitm.utility.ITMException;
import ibase.webitm.utility.TransIDGenerator; import ibase.webitm.utility.TransIDGenerator;
...@@ -1390,12 +1390,14 @@ public class CommonWmsUtil { ...@@ -1390,12 +1390,14 @@ public class CommonWmsUtil {
try try
{ {
System.out.println("@@@@ in try bilock===");
BufferedReader in = new BufferedReader( BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream())); new InputStreamReader(con.getInputStream()));
String inputLine; String inputLine;
response = new StringBuilder(); response = new StringBuilder();
while ((inputLine = in.readLine()) != null) while ((inputLine = in.readLine()) != null)
{ {
System.out.println("@@@@ inputLine===");
response.append(inputLine); response.append(inputLine);
} }
responseShipTrack = response.toString(); responseShipTrack = response.toString();
......
...@@ -10,6 +10,7 @@ import java.sql.PreparedStatement; ...@@ -10,6 +10,7 @@ import java.sql.PreparedStatement;
import java.sql.ResultSet; import java.sql.ResultSet;
import java.sql.SQLException; import java.sql.SQLException;
import java.text.SimpleDateFormat; import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.HashMap; import java.util.HashMap;
import java.util.logging.FileHandler; import java.util.logging.FileHandler;
import java.util.logging.Handler; import java.util.logging.Handler;
...@@ -26,11 +27,11 @@ import org.w3c.dom.Document; ...@@ -26,11 +27,11 @@ import org.w3c.dom.Document;
import ibase.scheduler.utility.interfaces.Schedule; import ibase.scheduler.utility.interfaces.Schedule;
import ibase.system.config.ConnDriver; import ibase.system.config.ConnDriver;
import ibase.utility.CommonConstants; import ibase.utility.CommonConstants;
import ibase.utility.E12GenericUtility;
import ibase.utility.UserInfoBean; import ibase.utility.UserInfoBean;
import ibase.webitm.bean.wms.ShipmentStatus; import ibase.webitm.bean.wms.ShipmentStatus;
import ibase.webitm.ejb.dis.DistCommon; import ibase.webitm.ejb.dis.DistCommon;
import ibase.webitm.ejb.wms.UploadOrderEJB; import ibase.webitm.ejb.wms.UploadOrderEJB;
import ibase.utility.E12GenericUtility;
import ibase.webitm.utility.ITMException; import ibase.webitm.utility.ITMException;
public class DDUpdTrackSchedule implements Schedule public class DDUpdTrackSchedule implements Schedule
...@@ -79,6 +80,10 @@ public class DDUpdTrackSchedule implements Schedule ...@@ -79,6 +80,10 @@ public class DDUpdTrackSchedule implements Schedule
ResultSet rs = null; ResultSet rs = null;
E12GenericUtility genericUtility = new E12GenericUtility(); E12GenericUtility genericUtility = new E12GenericUtility();
java.util.Date currDate = new java.util.Date(); java.util.Date currDate = new java.util.Date();
Calendar cal = Calendar.getInstance();
cal.setTime(currDate);
cal.add(Calendar.DATE, -1);
java.util.Date prvDate = cal.getTime();// One Day before current date
try try
{ {
ConnDriver connDriver = new ConnDriver(); ConnDriver connDriver = new ConnDriver();
...@@ -89,8 +94,9 @@ public class DDUpdTrackSchedule implements Schedule ...@@ -89,8 +94,9 @@ public class DDUpdTrackSchedule implements Schedule
String applDateFormat = genericUtility.getApplDateFormat(); String applDateFormat = genericUtility.getApplDateFormat();
String dbDateFormat = genericUtility.getDBDateFormat(); String dbDateFormat = genericUtility.getDBDateFormat();
SimpleDateFormat sdf = new SimpleDateFormat(applDateFormat); SimpleDateFormat sdf = new SimpleDateFormat(applDateFormat);
String currDateStr = sdf.format(currDate); //String currDateStr = sdf.format(currDate);
java.sql.Timestamp tranDate = java.sql.Timestamp.valueOf(genericUtility.getValidDateString( currDateStr , applDateFormat, dbDateFormat ) + " 00:00:00.0") ; String prvDateStr = sdf.format(prvDate);
java.sql.Timestamp tranDate = java.sql.Timestamp.valueOf(genericUtility.getValidDateString( prvDateStr , applDateFormat, dbDateFormat ) + " 00:00:00.0") ;
ShipmentStatus objShipment = new ShipmentStatus(); ShipmentStatus objShipment = new ShipmentStatus();
CommonWmsUtil wmsUtil = new CommonWmsUtil(); CommonWmsUtil wmsUtil = new CommonWmsUtil();
...@@ -111,14 +117,15 @@ public class DDUpdTrackSchedule implements Schedule ...@@ -111,14 +117,15 @@ public class DDUpdTrackSchedule implements Schedule
saleOrd = rs.getString(1); saleOrd = rs.getString(1);
ptcn = rs.getString(2); ptcn = rs.getString(2);
errString = updateTracking(saleOrd, ptcn, apiShipUrl, apiKey, objShipment, wmsUtil, conn); errString = updateTracking(saleOrd, ptcn, apiShipUrl, apiKey, objShipment, wmsUtil, conn);
writeLog(saleOrd,sw.toString()); System.out.println("RETURN STRING FROM updateTracking IS====["+errString+"]");
writeLog(errString);
} }
catch(Exception ex) catch(Exception ex)
{ {
System.out.println("Exception caught for SaleOrder["+saleOrd+"] so rollbacking and going for next despatch"); System.out.println("Exception caught for SaleOrder["+saleOrd+"] so rollbacking and going for next despatch");
conn.rollback(); conn.rollback();
ex.printStackTrace(pw); ex.printStackTrace(pw);
writeLog(saleOrd,sw.toString()); writeLog(errString);
continue; continue;
} }
} }
...@@ -178,7 +185,8 @@ public class DDUpdTrackSchedule implements Schedule ...@@ -178,7 +185,8 @@ public class DDUpdTrackSchedule implements Schedule
objShipment.setStatus("complete"); objShipment.setStatus("complete");
objShipment.setTrackingNumbers(wmsUtil.getTrackingNo(ptcn, conn)); objShipment.setTrackingNumbers(wmsUtil.getTrackingNo(ptcn, conn));
objShipment.setComment("Sale Order Complete"); objShipment.setComment("Sale Order Complete");
retString = wmsUtil.CallTrackShipStatus(objShipment, apiShipUrl); retString = wmsUtil.CallTrackShipStatus(objShipment, apiShipUrl);
System.out.println("RETURN STRING FROM CallTrackShipStatus IS====["+retString+"]");
System.out.println("status tracking update in magento END"); System.out.println("status tracking update in magento END");
} }
catch(Exception e) catch(Exception e)
...@@ -219,14 +227,21 @@ public class DDUpdTrackSchedule implements Schedule ...@@ -219,14 +227,21 @@ public class DDUpdTrackSchedule implements Schedule
return xtraParamsBuff.toString(); return xtraParamsBuff.toString();
} }
public void writeLog(String saleOrder,String errString) throws Exception public void writeLog(String errString) throws Exception
{ {
FileOutputStream fos1 = null; FileOutputStream fos1 = null;
String fileName = ""; String fileName = "";
final Logger logger = Logger.getLogger(DDUpdTrackSchedule.class.getName()); final Logger logger = Logger.getLogger(DDUpdTrackSchedule.class.getName());
java.util.Date currDate = new java.util.Date();
// SimpleDateFormat sdf = new SimpleDateFormat("dd-MM-yyyy HH:mm:ss");
SimpleDateFormat sdf = new SimpleDateFormat("dd-MM-yyyy");
try try
{ {
fileName = "DDUPDTRACK_"+saleOrder+"_ORDERSTATUS";
String time = sdf.format(currDate);
time = time.replaceAll(":", "-");
System.out.println("currDate is :::"+time);
fileName = "SHIPSTATUS_"+time;
System.out.println("Schdular Log Name is ="+fileName); System.out.println("Schdular Log Name is ="+fileName);
......
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