Commit 5eeaf28c authored by ppatro's avatar ppatro

changed by sankara on 06/01/2014 for updated source ,metadata and srd and sql for wms points


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@94090 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 5013ef9e
......@@ -2012,7 +2012,10 @@ public class ExpStockTransferIC extends ValidatorEJB implements ExpStockTransfer
" AND ITEM_CODE = ? " +
" AND LOC_CODE = ? " +
" AND LOT_NO = ? " +
" AND LOT_SL = ? ";
" AND LOT_SL = ? "+//;
//Changed By Pragyan 26-DEC-13 To check lock code to avoid duplicate records.
" AND LOCK_CODE = ? ";
pstmt1 = conn.prepareStatement(sql);
while (rs.next())
......@@ -2037,7 +2040,10 @@ public class ExpStockTransferIC extends ValidatorEJB implements ExpStockTransfer
pstmt1.setString(3, locCode);
pstmt1.setString(4, lotNo);
pstmt1.setString(5, lotSl);
//Changed By Pragyan 26-DEC-13 To check lock code to avoid duplicate records.
pstmt1.setString(6, locType);
rs1 = pstmt1.executeQuery();
if( rs1.next() )
{
holdQty = rs1.getInt("HOLD_QTY");
......
......@@ -131,7 +131,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
long oldMsnNo = 0;
String oldCarrierSymbol = "",carrierSymbol ="";
String oldCarrierFriendlyName = "",carrierFriendlyName = "";
String response = "",refType = "";
String response = "",refType = "",frtTerm = "",sSQL = "";
Connection conn = null;
int parentNodeListLength = 0;
......@@ -141,7 +141,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
double packSize = 0.0;
double weight = 0.0,actWeight = 0.0,itemWeght = 0.0,shipQty = 0.0;
double totalFrtAmt = 0.0;
NodeList parentNodeList = null;
NodeList childNodeList = null;
Node parentNode = null;
......@@ -149,7 +149,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
PreparedStatement pstmt = null,pstmt1 = null,ptcnPSTMT = null,
pstmtUpdCarton = null,pstmtChg = null, pstmtPrintStatus = null,
pstmtMaster = null,pstmtCrtnChg = null,pstmtGetTrack = null;
pstmtMaster = null,pstmtCrtnChg = null,pstmtGetTrack = null,pstmtDesp = null;
ResultSet rs = null,rs1 = null,ptcnRS = null ,rsPrintStatus = null,
rsMaster = null,rsGetTrack = null;
ITMDBAccessEJB itmDBAccessEJB = new ITMDBAccessEJB();
......@@ -158,7 +158,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
List arryOuterCartonNo = new ArrayList();
LinkedHashMap linkedMap = new LinkedHashMap();
ArrayList ptcnList = new ArrayList();
int pUpd = 0;
try
{
......@@ -530,6 +530,15 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
Collections.sort(arryOuterCartonNo);
shipment2.setPackages2(packages2);
///Changed By Pragyan To change the date and set current date as of shipment date.start
java.util.Date date = new java.util.Date();
Calendar calendar = Calendar.getInstance();
calendar.setTime(date);
shipment2.setShipDate(calendar);
////Changed By Pragyan To change the date and set current date as of shipment date.end
///Changed By Pragyan To change the date.end
System.out.println("Generating Label for the date ["+calendar.getTime().getTime()+"]");
//Changed By Pragyan as 11-jul-13 suggested by brian change it to default rotation
//ShipmentResultReturn2 objReturn2=soap.shipWithLabel(shipment2, ShipWithLabelType.PNG, ImageRotation.Rotation_180);
ShipmentResultReturn2 objReturn2=soap.shipWithLabel(shipment2, ShipWithLabelType.PNG, ImageRotation.Rotation_Default);
......@@ -707,8 +716,47 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
throw new Exception("Carton Master updated");
}
HashMap sordMap = getSordInfo(saleOrder,conn);
frtTerm = (String)sordMap.get("FRT_TERM");
totalFrtAmt = objShipResult.getTotal();
System.out.println("Update in desp update freight Amt totalFrtAmt ["+totalFrtAmt+"] For frtTerm["+frtTerm+"]saleOrder["+saleOrder+"]");
if("O".equalsIgnoreCase(frtTerm))
{
sSQL = "UPDATE DESPATCH SET FREIGHT_AMT_ADD = ? WHERE PTCN = ?";
pstmtDesp = conn.prepareStatement(sSQL);
pstmtDesp.setDouble(1, totalFrtAmt);
pstmtDesp.setString(2, ptcn);
pUpd = pstmtDesp.executeUpdate();
System.out.println("Update in desp update freight Amt upd ["+pUpd+"] For");
if(pstmtDesp != null)
{
pstmtDesp.close();
pstmtDesp = null;
}
sSQL = "UPDATE SHIP_DOCS SET FREIGHT_AMT_ADD = ? WHERE PTCN = ?";
pstmtDesp = conn.prepareStatement(sSQL);
pstmtDesp.setDouble(1, totalFrtAmt);
pstmtDesp.setString(2, ptcn);
pUpd = pstmtDesp.executeUpdate();
System.out.println("Update in Ship Docs update freight Amt upd ["+pUpd+"] For");
if(pstmtDesp != null)
{
pstmtDesp.close();
pstmtDesp = null;
}
}
}//else
/*}
else
......@@ -1364,7 +1412,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
String custCode = "",stanCode = "",siteCodeShip = "",stateCodeDlv = "",shipConsGrp = ""
//Changed By Rekha to get additional fields for ADSI
,custName="",custShName = "",shipCity="",shipCountry = "",shipAdd1 = "",shipAdd2 = "",shipAdd3 = "",
shipPh="",shipFax ="",shipMailId = "",custPord = "";
shipPh="",shipFax ="",shipMailId = "",custPord = "",frtTerm="";
try
{
......@@ -1392,7 +1440,9 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
+" C.COUNT_CODE AS COUNT_CODE,"
+" C.TELE1 AS PHONE,"
+" C.FAX AS FAX,"
+" C.EMAIL_ADDR AS EMAIL_ID"
+" C.EMAIL_ADDR AS EMAIL_ID,"
//changed by Pragyan on 23/12/13 for getting FRT TERM.
+" S.FRT_TERM AS FRT_TERM"
+" FROM SORDER S,CUSTOMER C "
+ " WHERE S.CUST_CODE__DLV = C.CUST_CODE "
+ " AND S.SALE_ORDER = ? ";
......@@ -1419,6 +1469,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
shipMailId = rs.getString("EMAIL_ID");
shipFax = rs.getString("FAX");
custPord = rs.getString("CUST_PORD");
frtTerm = rs.getString("FRT_TERM");
}
sordInfoMap.put("CUST_CODE", custCode);
......@@ -1446,7 +1497,7 @@ public class GenerateLabelsPrc extends ProcessEJB implements GenerateLabelsPrcLo
{
sordInfoMap.put("SHIP_CONS_GRP", custCode);
}
sordInfoMap.put("FRT_TERM", frtTerm);
if( rs != null )
{
......
......@@ -629,7 +629,53 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
errFields.add( childNodeName.toLowerCase() );
}
//changed by sankara on 18/11/13 validation for different assign user end.
//changed by sankara on 03/01/13 for doing replenishment order wise start.
sql = " SELECT SITE_CODE, ITEM_CODE, LOC_CODE, LOT_NO, LOT_SL FROM REPL_ORD_DET WHERE REPL_ORDER = ? ";
pstmt = conn.prepareStatement( sql );
pstmt.setString( 1, replOrder );
rs = pstmt.executeQuery();
if( rs.next() )
{
siteCode = checkNull (rs.getString("SITE_CODE"));
itemCode = checkNull (rs.getString("ITEM_CODE"));
locCode = checkNull (rs.getString("LOC_CODE"));
lotNo = checkNull (rs.getString("LOT_NO"));
lpnNo = checkNull (rs.getString("LOT_SL"));
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
sql = " SELECT R.REPL_ORDER FROM REPL_ORD_HDR R, WAVE_TASK W, WAVE_TASK_DET WD, REPL_ORD_DET RT WHERE " +
" R.REPL_ORDER = WD.REF_ID AND R.REPL_ORDER = RT.REPL_ORDER AND R.WAVE_ID = W.WAVE_ID AND W.WAVE_ID = WD.WAVE_ID " +
" AND WD.STATUS ='N' AND W.CANCEL = 'N' AND ( RT.CANCEL_MODE='N' OR RT.CANCEL_MODE IS NULL ) " +
" AND RT.SITE_CODE = ? AND RT.ITEM_CODE = ? AND RT.LOC_CODE = ? AND RT.LOT_NO = ? AND RT.LOT_SL = ? " +
" ORDER BY REPL_ORDER ";
pstmt = conn.prepareStatement( sql );
pstmt.setString( 1, siteCode );
pstmt.setString( 2, itemCode );
pstmt.setString( 3, locCode );
pstmt.setString( 4, lotNo );
pstmt.setString( 5, lpnNo );
rs = pstmt.executeQuery();
if( rs.next() )
{
replOrd = checkNull(rs.getString("REPL_ORDER"));
System.out.println("replOrd-->"+replOrd);
System.out.println("headerreplOrder-->"+replOrder);
if( !replOrder.trim().equalsIgnoreCase( replOrd ) )
{
errList.add( "VTREPLORDR" );
errFields.add( childNodeName.toLowerCase() );
}
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
//changed by sankara on 03/01/13 for doing replenishment order wise end.
}
else if( "site_code".equalsIgnoreCase( childNodeName ) )
{
......@@ -819,40 +865,6 @@ public class ReplIssIC extends ValidatorEJB implements ReplIssICLocal, ReplIssIC
errFields.add( childNodeName.toLowerCase() );
// end 26/10/11 manoharan all the errors should be returned so that warnings can be processed
}
//changed by sankara on 05/12/13 for doing replenishment order wise start.
sql = " SELECT R.REPL_ORDER FROM REPL_ORD_HDR R, WAVE_TASK W, WAVE_TASK_DET WD, REPL_ORD_DET RT, STOCK S, LOCATION L " +
" WHERE R.REPL_ORDER = WD.REF_ID AND R.REPL_ORDER = RT.REPL_ORDER AND R.WAVE_ID = W.WAVE_ID AND S.LOC_CODE = L.LOC_CODE " +
" AND RT.LOC_CODE = L.LOC_CODE AND WD.STATUS = 'N' AND W.CANCEL = 'N' AND ( RT.CANCEL_MODE='N' OR RT.CANCEL_MODE IS NULL ) " +
" AND S.SITE_CODE = ? " +
" AND S.ITEM_CODE = ? " +
" AND S.LOC_CODE = ? " +
" AND S.LOT_NO = ? " +
" AND S.LOT_SL = ? "+
" ORDER BY REPL_ORDER ";
pstmt = conn.prepareStatement( sql );
pstmt.setString( 1, siteCode );
pstmt.setString( 2, itemCode );
pstmt.setString( 3, locCode );
pstmt.setString( 4, lotNo );
pstmt.setString( 5, lpnNo );
rs = pstmt.executeQuery();
if( rs.next() )
{
replOrd = checkNull(rs.getString("REPL_ORDER"));
System.out.println("replOrd-->"+replOrd);
System.out.println("headerreplOrder-->"+replOrder);
if( !replOrder.trim().equalsIgnoreCase( replOrd ) )
{
errList.add( "VTREPLORDR" );
errFields.add( childNodeName.toLowerCase() );
}
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
//changed by sankara on 05/12/13 for doing replenishment order wise end.
}
//else if ( "lot_sl_new".equalsIgnoreCase( childNodeName ) ) //added by kunal mandhre on 05/JUN/12 - WM1ESUN007
else if ( "lot_sl__new".equalsIgnoreCase( childNodeName ) && "active_repl_iss".equalsIgnoreCase(getObjNameFromDom(currFormDataDom, "objName", objContext)) ) //added by kunal mandhre on 05/JUN/12 - WM1ESUN007
......
......@@ -160,6 +160,11 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
String taroShipName= "";
String shipTypeName= "";
//changed by sumitp on 10/03/13 for declare varibles end.
//Changed By Pragyan 18-DEC-13 To check ADSI Connection is required.(KB/Ashish mail Dt.121413)
String isADSIConnReq = "N";
//changed by sankara on 03/01/14 for update pro_no
String tranProNofrom = "";
String tranProNoto = "";
try
{
conn = connDriver.getConnectDB( "DriverITM" );
......@@ -192,6 +197,7 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
System.out.println("-- confirmed ["+confirmed+"] noOfPallet ["+noOfPallet+"] refSer ["+refSer.trim()+"]");
rs.close();rs = null;
pstmt.close();pstmt = null;
//isADSIConnReq = discommon.getDisparams("999999","CONN_TO_ADSI_APP",conn);
if( "Y".equalsIgnoreCase(confirmed))
{
......@@ -413,8 +419,10 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
if("D-ISS".equalsIgnoreCase(refSer.trim()) || "C-ISS".equalsIgnoreCase(refSer.trim()) || "P-RET".equalsIgnoreCase(refSer.trim()) || "".equalsIgnoreCase(refSer.trim()))
{
sql = "SELECT T.SERVICE_CODE,S.PACK_SIZE FROM SHIPMENT S,TRANSPORTER T WHERE T.TRAN_CODE = S.TRAN_CODE AND"
//Changed By Pragyan to take on Point not connecting to ADSI
/*sql = "SELECT T.SERVICE_CODE,S.PACK_SIZE FROM SHIPMENT S,TRANSPORTER T WHERE T.TRAN_CODE = S.TRAN_CODE AND"
+" S.SHIPMENT_ID = ? "; */
sql = "SELECT T.SERVICE_CODE,S.PACK_SIZE,T.ADSI_FLAG FROM SHIPMENT S,TRANSPORTER T WHERE T.TRAN_CODE = S.TRAN_CODE AND"
+" S.SHIPMENT_ID = ? ";
PreparedStatement pstmtTrans = conn.prepareStatement(sql);
pstmtTrans.setString(1, tranId);
......@@ -423,6 +431,7 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
{
serviceCode = checkNull(rsTrans.getString("SERVICE_CODE"));
dimensionDouble = rsTrans.getDouble("PACK_SIZE");
isADSIConnReq = checkNull(rsTrans.getString("ADSI_FLAG"));
}
if(pstmtTrans != null)
......@@ -436,8 +445,9 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
rsTrans.close();
rsTrans = null;
}
if(serviceCode != null && serviceCode.trim().length() > 0)
//isADSIConnReq
//if(serviceCode != null && serviceCode.trim().length() > 0)
if("Y".equalsIgnoreCase(isADSIConnReq) && serviceCode != null && serviceCode.trim().length() > 0)
{
System.out.println("Enetr in manual Shipment whit shipment ID"+tranId);
......@@ -981,6 +991,26 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
pstmt1.close();
pstmt1 = null;
//changed by sankara on 03/01/14 for update of pro no start.
sql = " SELECT PRONO_FROM, PRONO_TO, PRONO_LAST, CHK_DIGIT_YN FROM TRANSPORTER WHERE TRAN_CODE = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, tranCode);
rs = pstmt.executeQuery();
if( rs.next() )
{
tranProNofrom = rs.getString(1);
System.out.println("tranProNofrom::::"+tranProNofrom);
tranProNoto= rs.getString(2);
System.out.println("tranProNoto::::"+tranProNoto);
tranProNo = rs.getString(3);
System.out.println("tranprolastno::::"+tranProNo);
chDigitYn = rs.getString("CHK_DIGIT_YN");
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
//changed by sankara on 03/01/14 for update of pro no end.
if((tranProNo != null && proNo != null) && proNo.length() > tranProNo.length())
{
proNo = proNo.substring(0,tranProNo.length());
......@@ -989,6 +1019,12 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
{
proNo = proNo.substring(0,proNo.length() - 1);
}
//changed by sankara on 03/01/14 for update of pro no start.
else if( tranProNofrom == null && tranProNoto == null && tranProNo == null )
{
proNo = "";
}
//changed by sankara on 03/01/14 for update of pro no end.
System.out.println(" pro_no ["+proNo+"]");
sql = "UPDATE TRANSPORTER SET PRONO_LAST = ? WHERE TRAN_CODE = ?";
......@@ -2976,6 +3012,8 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
PreparedStatement pstmt = null;
ResultSet rs = null;
//changed by sankara on 03/01/14 for update pro_no
String shiprono = "";
System.out.println(" sumit inside update shipment ");
try
{
......@@ -2998,7 +3036,26 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
pstmt.close();
pstmt = null;
}
//changed by sankara on 03/01/14 for update pro_no start.
sql = " SELECT PRO_NO FROM SHIPMENT WHERE SHIPMENT_ID = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, shipmentId);
rs = pstmt.executeQuery();
if( rs.next() )
{
shiprono = checkNull( rs.getString("PRO_NO") );
}
if( rs != null)
{
rs.close();
rs = null;
}
if( pstmt != null)
{
pstmt.close();
pstmt = null;
}
//changed by sankara on 03/01/14 for update pro_no end.
sql = "SELECT tran_name, PRONO_LAST , PRONO_FROM, PREFIX FROM transporter WHERE tran_code = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, tranCode);
......@@ -3028,8 +3085,9 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
{
pronoLast = Long.parseLong(descr1) + 1;
}
if(pronoLast != 0)
{
// changed by sankara on 03/01/14 for update pro_no
//if(pronoLast != 0)
//{
//valueXmlString.append( "<lr_no><![CDATA[" ).append( pronoLast ).append( "]]></lr_no>\r\n" ); // commented to generate SSCC18 complaint number
//valueXmlString.append( "<lr_no><![CDATA[" ).append( getSSCC(prefix, pronoLast, conn) ).append( "]]></lr_no>\r\n" ); // added to generate SSCC18 complaint number //commented as per suggestion
......@@ -3077,9 +3135,40 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
//valueXmlString.append( "<lr_no><![CDATA[" ).append( sProno ).append( "]]></lr_no>\r\n" );
}
// changed by sankara on 03/01/14 for update pro_no
//}
// changed by sankara on 03/01/14 for update pro_no start.
/*sql = "UPDATE SHIPMENT SET LR_NO = ? , PRO_NO = ? WHERE SHIPMENT_ID = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, lrNo);
pstmt.setString(2, sProno);
pstmt.setString(3, shipmentId);
update = pstmt.executeUpdate();
if( update > 0)
{
System.out.println(" shipment updated sucessfully");
}*/
if(shiprono != null && shiprono.trim().length() > 0 )
{
sql = "UPDATE SHIPMENT SET LR_NO = ? , PRO_NO = ? WHERE SHIPMENT_ID = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, lrNo);
pstmt.setString(2, shiprono);
pstmt.setString(3, shipmentId);
update = pstmt.executeUpdate();
if( update > 0)
{
System.out.println(" shipment updated sucessfully");
}
}
else
{
if( "0".equalsIgnoreCase(sProno) )
{
sProno = "";
}
sql = "UPDATE SHIPMENT SET LR_NO = ? , PRO_NO = ? WHERE SHIPMENT_ID = ?";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, lrNo);
pstmt.setString(2, sProno);
......@@ -3089,7 +3178,8 @@ public class ShipmentConf extends ActionHandlerEJB implements ShipmentConfLocal,
{
System.out.println(" shipment updated sucessfully");
}
}
// changed by sankara on 03/01/14 for update pro_no end.
if(pstmt != null)
{
pstmt.close();
......
......@@ -1258,6 +1258,8 @@ public String itemChanged( Document dom, Document dom1, Document dom2, String ob
String lrNo = "";
GenericUtility genericUtility = GenericUtility.getInstance();
//changed by sankara on 03/01/14 for freight_amt_add in ship_docs
String freightamount = "";
try
{
siteCode = getValueFromXTRA_PARAMS(xtraParams, "loginSiteCode");
......@@ -2037,7 +2039,21 @@ public String itemChanged( Document dom, Document dom1, Document dom2, String ob
//valueXmlString.append( "<Detail2>\r\n" );
}
valueXmlString.append( "<ref_ser><![CDATA[S-DSP]]></ref_ser>\r\n" );
//changed by sankara on 03/01/14 display despatch freight_amt_add in ship_docs start.
sql = " SELECT FREIGHT_AMT_ADD FROM DESPATCH WHERE PTCN = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, columnValue);
rs = pstmt.executeQuery();
if( rs.next() )
{
freightamount = checkNull(rs.getString("FREIGHT_AMT_ADD"));
}
rs.close();
rs = null;
pstmt.close();
pstmt = null;
valueXmlString.append( "<freight_amt_add><![CDATA[" ).append(freightamount).append( "]]></freight_amt_add>\r\n" );
//changed by sankara on 03/01/14 display despatch freight_amt_add in ship_docs end.
}
else if( currentColumn.trim().equalsIgnoreCase( "curr_code" ) )
......
......@@ -50,7 +50,14 @@ public class ShipmentPos extends ValidatorEJB implements ShipmentPosLocal, Shipm
DistCommon distCommon = new DistCommon();
PreparedStatement pstmt = null;
ResultSet rs = null;
//changed by sankara on 03/01/14 for update freight_amt_add in despatch start.
String freightamount = "";
NodeList parentNodeList = null;
Node parentNode = null;
int parentNodeListLength = 0;
String refid = "";
int updatecount = 0;
//changed by sankara on 03/01/14 for update freight_amt_add in despatch end.
try
{
String applDateFormat = genericUtility.getApplDateFormat();
......@@ -65,6 +72,28 @@ public class ShipmentPos extends ValidatorEJB implements ShipmentPosLocal, Shipm
// Changed by sankara on 16/08/13 for checking transporter code null
//transporterCode = genericUtility.getColumnValueFromNode("tran_code", dom.getElementsByTagName("Detail1").item(0));
transporterCode = checkNull(genericUtility.getColumnValueFromNode("tran_code", dom.getElementsByTagName("Detail1").item(0)));
//changed by sankara on 03/01/14 for update freight_amt_add in deepatch start.
NodeList detail2List = dom.getElementsByTagName("Detail2");
parentNodeListLength = detail2List.getLength();
for(int row = 0; row < parentNodeListLength; row++)
{
refid = GenericUtility.getInstance().getColumnValueFromNode("ref_id", dom.getElementsByTagName("Detail2").item(row));
freightamount = GenericUtility.getInstance().getColumnValueFromNode("freight_amt_add", dom.getElementsByTagName("Detail2").item(row));
System.out.println(" refid ["+refid+"] freightamount ["+freightamount+"]");
sql = " UPDATE DESPATCH SET FREIGHT_AMT_ADD = ? WHERE DESP_ID = ? ";
pstmt = conn.prepareStatement(sql);
pstmt.setString(1, freightamount);
pstmt.setString(2, refid);
updatecount = pstmt.executeUpdate();
if( updatecount > 0 )
{
System.out.println(" update seccessfully ");
}
pstmt.close(); pstmt = null;
}
//changed by sankara on 03/01/14 for update freight_amt_add in deepatch end.
//Changed By Pragyan to get PTCN
/*sql = " SELECT D.REF_ID AS REF_ID, P.WAVE_ID AS WAVE_ID FROM SHIP_DOCS D, SHIPMENT S, DESPATCH P WHERE S.SHIPMENT_ID = D.SHIPMENT_ID" +
" AND P.DESP_ID = D.REF_ID AND S.SHIPMENT_ID = ? ";*/
......
......@@ -225,6 +225,8 @@ public class WaveCancelEJB extends ActionHandlerEJB implements WaveCancelEJBLoca
ITMDBAccessEJB itmDBAccess = new ITMDBAccessEJB();
ADSIShippingSoap soap = null;
int updateSorder = 0;
//Changed By Pragyan 18-DEC-13 To check ADSI Connection is required.(KB/Ashish mail Dt.121413)
String isADSIConnReq = "N";
try
{
......@@ -246,7 +248,7 @@ public class WaveCancelEJB extends ActionHandlerEJB implements WaveCancelEJBLoca
stagingLocMpick = discommon.getDisparams( "999999", "STAGING_LOC_MPK", conn );
dsoInvstat = discommon.getDisparams( "999999", "DEEP_STORE_INVSTAT", conn );
invPndReserve = discommon.getDisparams("999999","PND_INVSTAT",conn);
//isADSIConnReq = discommon.getDisparams("999999","CONN_TO_ADSI_APP",conn);
GenericUtility genericUtility = GenericUtility.getInstance();
//java.sql.Timestamp currDate = new java.sql.Timestamp( System.currentTimeMillis() );
distStkUpd = getComponent("DistStkUpd");
......@@ -982,8 +984,11 @@ public class WaveCancelEJB extends ActionHandlerEJB implements WaveCancelEJBLoca
System.out.println("RefSeries checking for void packages"+refSer+"}");
System.out.println("PTCN LIST"+ptcnVoidPackagesMap.toString()+"}");
//isADSIConnReq
//Changed by Rohan on 16-07-13 for define map of ptcn for void packages.start
if(!(ptcnVoidPackagesMap.containsKey(ptcn)) && isTrackingNoExist(ptcn,conn))
//if(!(ptcnVoidPackagesMap.containsKey(ptcn)) && isTrackingNoExist(ptcn,conn))
if("Y".equalsIgnoreCase(isADSIConnReq) && !(ptcnVoidPackagesMap.containsKey(ptcn)) && isTrackingNoExist(ptcn,conn))
{
/* if(refSer.equalsIgnoreCase("M-PICK") || refSer.equalsIgnoreCase("P-PICK") )
{*/
......
......@@ -44958,3 +44958,37 @@ insert into obj_itemchange(obj_name,form_no,field_name) values ('sordform_tr',1,
-- ADDED BY KUNAL ON 04/JAN/13 for SOF 181 N POINT END
commit;
--changed by sankara on 06/01/2014 for pro_no,freight_amt_add points
ALTER TABLE TRANSPORTER ADD ADSI_FLAG CHAR(1);
ALTER TABLE SHIP_DOCS ADD FREIGHT_AMT_ADD NUMBER(14,3);
ALTER TABLE DESPATCH ADD FREIGHT_AMT_ADD NUMBER(14, 3);
DELETE FROM MESSAGES WHERE MSG_NO='VTREPLORDR';
INSERT INTO messages (
msg_no ,
msg_str ,
msg_descr ,
msg_type ,
msg_opt ,
msg_time ,
alarm ,
err_source ,
chg_date ,
chg_user ,
chg_term ,
override_input ,
mail_option )
VALUES (
'VTREPLORDR',
'Pending Active Replineshment',
'Active Replineshment Pending from the current location. Please complete Active Replineshment first',
'E',
'Y',
NULL,
NULL,
NULL,
fn_sysdate(),
'Base ',
'Base ',
NULL,
NULL);
commit;
\ No newline at end of file
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