Commit fb3748af authored by ngadkari's avatar ngadkari

Error while confirming the expense voucher if sitePay is null

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@188173 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 2be67baf
...@@ -21,7 +21,7 @@ import org.w3c.dom.NodeList; ...@@ -21,7 +21,7 @@ import org.w3c.dom.NodeList;
@Stateless @Stateless
public class RecPayXfrPrc extends ProcessEJB implements RecPayXfrPrcLocal,RecPayXfrPrcRemote public class RecPayXfrPrc extends ProcessEJB implements RecPayXfrPrcLocal,RecPayXfrPrcRemote
{ {
E12GenericUtility genericUtility = null; E12GenericUtility genericUtility = new E12GenericUtility();// chnages by Nandkumar Gadkari on 25/07/18
public String getData(String xmlString, String xmlString2, String windowName, String xtraParams) throws RemoteException, ITMException public String getData(String xmlString, String xmlString2, String windowName, String xtraParams) throws RemoteException, ITMException
{ {
...@@ -34,12 +34,12 @@ public class RecPayXfrPrc extends ProcessEJB implements RecPayXfrPrcLocal,RecPay ...@@ -34,12 +34,12 @@ public class RecPayXfrPrc extends ProcessEJB implements RecPayXfrPrcLocal,RecPay
//System.out.println(">>>>>xmlString:getData"+xmlString+">>>>xmlString2:"+xmlString2); //System.out.println(">>>>>xmlString:getData"+xmlString+">>>>xmlString2:"+xmlString2);
if (xmlString != null && xmlString.trim().length() != 0) if (xmlString != null && xmlString.trim().length() != 0)
{ {
genericUtility= new E12GenericUtility(); //genericUtility= new E12GenericUtility();
dom = genericUtility.parseString(xmlString); dom = genericUtility.parseString(xmlString);
} }
if (xmlString2 != null && xmlString2.trim().length() != 0) if (xmlString2 != null && xmlString2.trim().length() != 0)
{ {
genericUtility= new E12GenericUtility(); //genericUtility= new E12GenericUtility();
dom1 = genericUtility.parseString(xmlString2); dom1 = genericUtility.parseString(xmlString2);
} }
retString = getData(dom, dom1, windowName, xtraParams); retString = getData(dom, dom1, windowName, xtraParams);
...@@ -658,6 +658,7 @@ public class RecPayXfrPrc extends ProcessEJB implements RecPayXfrPrcLocal,RecPay ...@@ -658,6 +658,7 @@ public class RecPayXfrPrc extends ProcessEJB implements RecPayXfrPrcLocal,RecPay
pstmt.close(); pstmt.close();
pstmt = null; pstmt = null;
} }
genericUtility=null;// added by Nandkumar Gadkari on 25/07/18
} }
catch(Exception e) catch(Exception e)
......
...@@ -2336,6 +2336,10 @@ public class RetainerContractReleasePrc extends ProcessEJB implements RetainerCo ...@@ -2336,6 +2336,10 @@ public class RetainerContractReleasePrc extends ProcessEJB implements RetainerCo
System.out.println("Exception :saveData :saveData :==>"); System.out.println("Exception :saveData :saveData :==>");
throw new ITMException(e); throw new ITMException(e);
} }
finally // added by Nandkumar Gadkari on 25/07/18
{
genericUtility=null;
}
return retString; return retString;
} }
......
...@@ -52,7 +52,8 @@ public class AcctAnalPrc extends ProcessEJB implements AcctAnalPrcLocal ,AcctAna ...@@ -52,7 +52,8 @@ public class AcctAnalPrc extends ProcessEJB implements AcctAnalPrcLocal ,AcctAna
System.out.println("XML String :"+xmlString); System.out.println("XML String :"+xmlString);
// GenericUtility genericUtility = GenericUtility.getInstance(); // GenericUtility genericUtility = GenericUtility.getInstance();
E12GenericUtility genericUtility = new E12GenericUtility(); E12GenericUtility genericUtility = new E12GenericUtility();
dom = genericUtility.parseString(xmlString); dom = genericUtility.parseString(xmlString);
genericUtility=null; //added by Ngadkari on 26/07/18
} }
resString = process(dom,dom1,windowName,xtraParams); resString = process(dom,dom1,windowName,xtraParams);
} }
...@@ -61,6 +62,9 @@ public class AcctAnalPrc extends ProcessEJB implements AcctAnalPrcLocal ,AcctAna ...@@ -61,6 +62,9 @@ public class AcctAnalPrc extends ProcessEJB implements AcctAnalPrcLocal ,AcctAna
System.out.println("Exception :AcctAnalEJB : process(String xmlString):" + e.getMessage() + ":"); System.out.println("Exception :AcctAnalEJB : process(String xmlString):" + e.getMessage() + ":");
throw new ITMException(e); throw new ITMException(e);
} }
System.out.println("returning from Process "+resString); System.out.println("returning from Process "+resString);
return resString; return resString;
} }
...@@ -179,6 +183,8 @@ conn = getConnection(); ...@@ -179,6 +183,8 @@ conn = getConnection();
System.out.println("Closing Database Connection......"); System.out.println("Closing Database Connection......");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by nandkumar gadkari on 26/07/18
}catch(Exception se){} }catch(Exception se){}
} }
return retString; return retString;
......
...@@ -55,7 +55,8 @@ public class AcctCctrPrc extends ProcessEJB implements AcctCctrPrcLocal,AcctCctr ...@@ -55,7 +55,8 @@ public class AcctCctrPrc extends ProcessEJB implements AcctCctrPrcLocal,AcctCctr
System.out.println("XML String :"+xmlString); System.out.println("XML String :"+xmlString);
// GenericUtility genericUtility = GenericUtility.getInstance(); // GenericUtility genericUtility = GenericUtility.getInstance();
E12GenericUtility genericUtility = new E12GenericUtility(); E12GenericUtility genericUtility = new E12GenericUtility();
dom = genericUtility.parseString(xmlString); dom = genericUtility.parseString(xmlString);
genericUtility=null; //added by Ngadkari on 26/07/18
} }
retString = process(dom,dom1,windowName,xtraParams); retString = process(dom,dom1,windowName,xtraParams);
} }
...@@ -192,6 +193,7 @@ conn = getConnection(); ...@@ -192,6 +193,7 @@ conn = getConnection();
System.out.println("Closing Database Connection......"); System.out.println("Closing Database Connection......");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by NGadkari on 26/07/18
}catch(Exception se){} }catch(Exception se){}
} }
return retString; return retString;
......
...@@ -64,6 +64,10 @@ public class AnalAcctPrc extends ProcessEJB implements AnalAcctPrcLocal ,AnalAc ...@@ -64,6 +64,10 @@ public class AnalAcctPrc extends ProcessEJB implements AnalAcctPrcLocal ,AnalAc
System.out.println("Exception :AnalAcctCpyEJB :process() :: " + e.getMessage() + ":"); System.out.println("Exception :AnalAcctCpyEJB :process() :: " + e.getMessage() + ":");
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Ngadkari on 26/07/18
}
return retStr; return retStr;
} }
public String process(Document headerDom, Document detailDom, String windowName, String xtraParams) throws RemoteException,ITMException public String process(Document headerDom, Document detailDom, String windowName, String xtraParams) throws RemoteException,ITMException
...@@ -178,6 +182,7 @@ conn = getConnection(); ...@@ -178,6 +182,7 @@ conn = getConnection();
System.out.println("Closing Connection......"); System.out.println("Closing Connection......");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Ngadkari on 26/07/18
}catch(SQLException se){} }catch(SQLException se){}
} }
return errString; return errString;
......
...@@ -140,7 +140,7 @@ public class BankPifRtgsprc implements Schedule // extends ProcessEJB implements ...@@ -140,7 +140,7 @@ public class BankPifRtgsprc implements Schedule // extends ProcessEJB implements
Document detailDom = null; Document detailDom = null;
Document headerDom = null; Document headerDom = null;
// GenericUtility genericUtility = GenericUtility.getInstance(); // GenericUtility genericUtility = GenericUtility.getInstance();
E12GenericUtility genericUtility = new E12GenericUtility(); // E12GenericUtility genericUtility = new E12GenericUtility(); //commented by Nandkumar Gadkari on 26/07/18
try { try {
if (xmlString != null && xmlString.trim().length() != 0) { if (xmlString != null && xmlString.trim().length() != 0) {
headerDom = genericUtility.parseString(xmlString); headerDom = genericUtility.parseString(xmlString);
...@@ -166,7 +166,7 @@ public class BankPifRtgsprc implements Schedule // extends ProcessEJB implements ...@@ -166,7 +166,7 @@ public class BankPifRtgsprc implements Schedule // extends ProcessEJB implements
Connection conn = null; Connection conn = null;
// GenericUtility genericUtility = GenericUtility.getInstance(); // GenericUtility genericUtility = GenericUtility.getInstance();
E12GenericUtility genericUtility = new E12GenericUtility(); //E12GenericUtility genericUtility = new E12GenericUtility(); //commented by Nandkumar Gadkari on 26/07/18
PreparedStatement pstmt = null; PreparedStatement pstmt = null;
ResultSet rs = null; ResultSet rs = null;
String sql = ""; String sql = "";
......
...@@ -27,7 +27,7 @@ import javax.ejb.Stateless; // added for ejb3 ...@@ -27,7 +27,7 @@ import javax.ejb.Stateless; // added for ejb3
// added for ejb3 // added for ejb3
public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal, public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal,
BankRecoPrcRemote // SessionBean BankRecoPrcRemote // SessionBean
{ {
/* /*
* public void ejbCreate() throws RemoteException, CreateException { try { * public void ejbCreate() throws RemoteException, CreateException { try {
* System.out.println("ProcessEJB ejbCreate called........."); * System.out.println("ProcessEJB ejbCreate called.........");
...@@ -64,6 +64,10 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal, ...@@ -64,6 +64,10 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal,
+ e.getMessage() + ":"); + e.getMessage() + ":");
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
return rtrStr; return rtrStr;
} }
...@@ -251,6 +255,8 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal, ...@@ -251,6 +255,8 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal,
System.out.println("Closing Connection....."); System.out.println("Closing Connection.....");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
} catch (Exception e) { } catch (Exception e) {
} }
} }
...@@ -279,6 +285,10 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal, ...@@ -279,6 +285,10 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal,
System.out.println("Exception :BankRecoEJB :getData(String xmlString, String xmlString2, String windowName, String xtraParams):"+ e.getMessage() + ":"); System.out.println("Exception :BankRecoEJB :getData(String xmlString, String xmlString2, String windowName, String xtraParams):"+ e.getMessage() + ":");
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
return retStr; return retStr;
} }
...@@ -412,6 +422,8 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal, ...@@ -412,6 +422,8 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal,
System.out.println("Closing Connection....."); System.out.println("Closing Connection.....");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
} catch (Exception se) { } catch (Exception se) {
} }
} }
...@@ -1077,6 +1089,10 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal, ...@@ -1077,6 +1089,10 @@ public class BankRecoPrc extends ProcessEJB implements BankRecoPrcLocal,
e.printStackTrace(); e.printStackTrace();
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
// 12/05/09 manoharan passed connection not to be closed // 12/05/09 manoharan passed connection not to be closed
/* /*
* finally { try { System.out.println("Closing Connection......"); * finally { try { System.out.println("Closing Connection......");
......
...@@ -77,6 +77,10 @@ public class BankStartRecoPrc extends ProcessEJB implements BankStartRecoPrcLoca ...@@ -77,6 +77,10 @@ public class BankStartRecoPrc extends ProcessEJB implements BankStartRecoPrcLoca
System.out.println("Exception :BankRecoEJB :getData(String xmlString, String xmlString2, String windowName, String xtraParams):" + e.getMessage() + ":"); System.out.println("Exception :BankRecoEJB :getData(String xmlString, String xmlString2, String windowName, String xtraParams):" + e.getMessage() + ":");
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
return rtrStr; return rtrStr;
} }
...@@ -171,6 +175,8 @@ conn = getConnection(); ...@@ -171,6 +175,8 @@ conn = getConnection();
{ {
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
} }
catch(Exception e){} catch(Exception e){}
} }
...@@ -203,6 +209,10 @@ conn = getConnection(); ...@@ -203,6 +209,10 @@ conn = getConnection();
e.printStackTrace(); e.printStackTrace();
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
return retStr; return retStr;
} }
public String process(Document headerDom, Document detailDom, String windowName, String xtraParams) throws RemoteException,ITMException public String process(Document headerDom, Document detailDom, String windowName, String xtraParams) throws RemoteException,ITMException
...@@ -230,6 +240,8 @@ conn = getConnection(); ...@@ -230,6 +240,8 @@ conn = getConnection();
Node parentNode = null; Node parentNode = null;
Node childNode = null; Node childNode = null;
ConnDriver connDriver = new ConnDriver(); ConnDriver connDriver = new ConnDriver();
E12GenericUtility genericUtility = new E12GenericUtility(); //added by Nandkumar Gadkari on 26/07/18
ITMDBAccessEJB itmDBAccessEJB = new ITMDBAccessEJB(); ITMDBAccessEJB itmDBAccessEJB = new ITMDBAccessEJB();
try try
{ {
...@@ -349,6 +361,8 @@ conn = getConnection(); ...@@ -349,6 +361,8 @@ conn = getConnection();
{ {
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}catch(Exception se){} }catch(Exception se){}
} }
System.out.println("errString: "+errString); System.out.println("errString: "+errString);
......
...@@ -68,6 +68,10 @@ public class CctrAcctPrc extends ProcessEJB implements CctrAcctPrcLocal,CctrAcct ...@@ -68,6 +68,10 @@ public class CctrAcctPrc extends ProcessEJB implements CctrAcctPrcLocal,CctrAcct
System.out.println("Exception :cctrAcctEJB :process(xmlString) ::" + e.getMessage() + ":"); System.out.println("Exception :cctrAcctEJB :process(xmlString) ::" + e.getMessage() + ":");
throw new ITMException(e); throw new ITMException(e);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
return retStr; return retStr;
} }
public String process(Document headerDom, Document detailDom, String windowName, String xtraParams) throws RemoteException,ITMException public String process(Document headerDom, Document detailDom, String windowName, String xtraParams) throws RemoteException,ITMException
...@@ -184,6 +188,8 @@ conn = getConnection(); ...@@ -184,6 +188,8 @@ conn = getConnection();
System.out.println("Closing Connection......"); System.out.println("Closing Connection......");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}catch(SQLException se){} }catch(SQLException se){}
} }
return errString; return errString;
......
...@@ -1728,6 +1728,10 @@ conn = getConnection(); ...@@ -1728,6 +1728,10 @@ conn = getConnection();
} }
}//End by Abhijit Gaikwad }//End by Abhijit Gaikwad
System.out.println("sitePayment"+sitePayment+" !=siteCode"+siteCode); System.out.println("sitePayment"+sitePayment+" !=siteCode"+siteCode);
if(sitePayment== null || sitePayment.trim().length() == 0 ) // Condition added by Nandkumar Gadkari on 26/07/18
{
sitePayment=siteCode;
}
if((!sitePayment.trim().equals(siteCode.trim())) && (("I").equalsIgnoreCase(runMode))) if((!sitePayment.trim().equals(siteCode.trim())) && (("I").equalsIgnoreCase(runMode)))
{ {
......
...@@ -56,6 +56,10 @@ public class MiscVouchTdsPrc extends ProcessEJB implements MiscVouchTdsPrcLocal, ...@@ -56,6 +56,10 @@ public class MiscVouchTdsPrc extends ProcessEJB implements MiscVouchTdsPrcLocal,
System.out.println("Exception in MiscVouchTdsEJB :: "+se.getMessage()); System.out.println("Exception in MiscVouchTdsEJB :: "+se.getMessage());
throw new ITMException(se); throw new ITMException(se);
} }
finally
{
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}
return retString; return retString;
} }
public String getData(Document dom, Document dom2, String windowName, String xtraParams) throws RemoteException,ITMException public String getData(Document dom, Document dom2, String windowName, String xtraParams) throws RemoteException,ITMException
...@@ -161,6 +165,8 @@ conn = getConnection(); ...@@ -161,6 +165,8 @@ conn = getConnection();
{ {
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}catch(Exception se){} }catch(Exception se){}
} }
return retString.toString(); return retString.toString();
...@@ -177,6 +183,8 @@ conn = getConnection(); ...@@ -177,6 +183,8 @@ conn = getConnection();
dom1 = genericUtility.parseString(xmlString); dom1 = genericUtility.parseString(xmlString);
dom2 = genericUtility.parseString(xmlString2); dom2 = genericUtility.parseString(xmlString2);
retString = process(dom1,dom2,windowName,xtraParams); retString = process(dom1,dom2,windowName,xtraParams);
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
} }
catch(Exception e) catch(Exception e)
{ {
...@@ -369,6 +377,8 @@ conn = getConnection(); ...@@ -369,6 +377,8 @@ conn = getConnection();
System.out.println("Closing Connection....."); System.out.println("Closing Connection.....");
conn.close(); conn.close();
conn = null; conn = null;
genericUtility=null; //added by Nandkumar Gadkari on 26/07/18
}catch(Exception se){} }catch(Exception se){}
} }
return retString; return retString;
......
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