Commit 3359a948 authored by ssalve's avatar ssalve

changes for E12GenericUtility and DBConnect


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@105730 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 2f71b6c1
package ibase.webitm.ejb.fin;
import ibase.system.config.ConnDriver;
import ibase.utility.E12GenericUtility;
import ibase.utility.UserInfoBean;
import ibase.webitm.utility.ITMException;
......@@ -66,6 +67,8 @@ public class AccountsIC extends ValidatorEJB implements AccountsICRemote, Accoun
int currentFormNo=0;
int ctr=0,cnt=0;
Connection conn = null;
//Added by sarita on 01/06/2017
ConnDriver connDriver = null;
PreparedStatement pstmt = null;
ResultSet rs = null ;
NodeList parentNodeList = null;
......@@ -84,7 +87,13 @@ public class AccountsIC extends ValidatorEJB implements AccountsICRemote, Accoun
StringBuffer errStringXml = new StringBuffer("<?xml version = \"1.0\"?> \r\n <Root> <Errors>");
try
{
conn = getConnection();
//changes and commented by sarita for DBConnection on 01/06/2017 :START
//conn = getConnection();
connDriver = new ConnDriver();
conn = connDriver.getConnectDB("DriverITM");
conn.setAutoCommit(false);
connDriver = null;
//changes and commented by sarita for DBConnection on 01/06/2017 :END
userId = genericUtility.getValueFromXTRA_PARAMS(xtraParams, "loginCode");
if(objContext != null && objContext.trim().length() > 0)
{
......@@ -410,6 +419,8 @@ public class AccountsIC extends ValidatorEJB implements AccountsICRemote, Accoun
public String itemChanged(Document dom, Document dom1, Document dom2,String objContext, String currentColumn, String editFlag, String xtraParams) throws RemoteException,ITMException
{
Connection conn = null;
//Added by sarita on 01/06/2017
ConnDriver connDriver = null;
PreparedStatement pstmt = null;
ResultSet rs = null ;
SimpleDateFormat sdf;
......@@ -432,7 +443,13 @@ public class AccountsIC extends ValidatorEJB implements AccountsICRemote, Accoun
try
{
conn = getConnection();
//changes and commented by sarita for DBConnection on 01/06/2017 :START
//conn = getConnection();
connDriver = new ConnDriver();
conn = connDriver.getConnectDB("DriverITM");
conn.setAutoCommit(false);
connDriver = null;
//changes and commented by sarita for DBConnection on 01/06/2017 :END
sdf = new SimpleDateFormat(genericUtility.getApplDateFormat());
if(objContext != null && objContext.trim().length()>0)
......
......@@ -72,10 +72,13 @@ public class LoanPartyIC extends ValidatorEJB implements LoanPartyICLocal, LoanP
String code="",tempCode="",descr = "";
try
{
//conn = connDriver.getConnectDB("DriverITM");
//conn.setAutoCommit(false);
//connDriver = null;
conn = getConnection();
//changes and commented by sarita for DBConnection on 01/06/2017
conn = connDriver.getConnectDB("DriverITM");
conn.setAutoCommit(false);
connDriver = null;
//conn = getConnection();
//changes and commented by sarita for DBConnection on 01/06/2017
if (objContext != null && objContext.trim().length() > 0)
{
currentFormNo = Integer.parseInt(objContext.trim());
......@@ -801,8 +804,10 @@ public class LoanPartyIC extends ValidatorEJB implements LoanPartyICLocal, LoanP
try
{
SimpleDateFormat sdf1= new SimpleDateFormat(genericUtility.getDBDateFormat());
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//changes and commented by sarita for DBConnection on 01/06/2017
conn = connDriver.getConnectDB("DriverITM");
//conn = getConnection();
//changes and commented by sarita for DBConnection on 01/06/2017
userId = getValueFromXTRA_PARAMS(xtraParams, "loginCode");
if (objContext != null && objContext.trim().length() > 0)
{
......
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