Commit 04193611 authored by blad's avatar blad

Updated components has been uploaded for remove new getConnection() method in FIN.


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@101892 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 104df434
......@@ -99,10 +99,7 @@ public class MilestonePayGen
{
System.out.println("getXmlData inside dom !!!!!!!!");
SimpleDateFormat sdf1 = new SimpleDateFormat(e12GenericUtility.getApplDateFormat());
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
SimpleDateFormat simpleDateFormat = new SimpleDateFormat(e12GenericUtility.getApplDateFormat());
java.util.Calendar cal = java.util.Calendar.getInstance();
......@@ -466,10 +463,7 @@ public class MilestonePayGen
{
System.out.println("getXmlData inside dom !!!!!!!!");
SimpleDateFormat sdf1 = new SimpleDateFormat(e12GenericUtility.getApplDateFormat());
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
NodeList hdrDommList = dom.getElementsByTagName("Detail2");
System.out.println("length of details 2 xml===>["+hdrDommList.getLength()+"]");
......@@ -1666,10 +1660,7 @@ public class MilestonePayGen
try
{
E12GenericUtility genericUtility = new E12GenericUtility();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
System.out.println("saveSampleData>>>>>>>"+saveSampleData);
if (saveSampleData != null && saveSampleData.trim().length() > 0)
{
......@@ -2202,54 +2193,4 @@ public class MilestonePayGen
return calRelAmt;
}
//Added By Bhushan on 06-06-2016 :START
private UserInfoBean userInfo = null;
public UserInfoBean getUserInfo()
{
return this.userInfo;
}
public void setUserInfo(UserInfoBean userInfo)
{
this.userInfo = userInfo;
}
public Connection getConnection()throws RemoteException,ITMException
{
Connection conn = null;
try
{
if(this.userInfo != null)
{
String transDB = this.userInfo.getTransDB();
System.out.println("getConnection :: transDB :: ["+transDB+"]");
if( transDB != null && transDB.trim().length() > 0 && !"null".equalsIgnoreCase(transDB))
{
ConnDriver connDriver = null;
connDriver = new ConnDriver();
conn = connDriver.getConnectDB(transDB);
connDriver = null;
}
else
{
throw new ITMException(new Exception("Connection file not specified in trans_db column of users table."));
}
}
else
{
throw new ITMException(new Exception("UserInfo is null."));
}
}
catch(Exception e)
{
System.out.println("Exception :[getConnection] :==>\n"+e.getMessage()); //$NON-NLS-1$
e.printStackTrace();
throw new ITMException(e);
}
return conn;
}
//Added By Bhushan on 06-06-2016 :END
}
\ No newline at end of file
......@@ -125,10 +125,7 @@ public class PurcVchrMultiAttachmentBean
try
{
ConnDriver connDriver = new ConnDriver();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
String sql = "select v.tran_id as voucher_id,v.confirmed,l.tran_id as ref_id,l.purc_order,l.status,l.tran_date"
+" from VOUCHER v, LC_VOUCHER l where v.purc_order=l.purc_order and v.tran_id=? Order by v.purc_order";
......@@ -264,10 +261,7 @@ public class PurcVchrMultiAttachmentBean
try
{
ConnDriver connDriver = new ConnDriver();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
String sql = "select tran_id from lc_voucher where tran_id=?";
......@@ -461,10 +455,7 @@ public class PurcVchrMultiAttachmentBean
try
{
ConnDriver connDriver = new ConnDriver();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
conn.setAutoCommit(false);
InitialContext ctx = new InitialContext(new AppConnectParm().getProperty());
......@@ -639,54 +630,5 @@ public class PurcVchrMultiAttachmentBean
return documentNames;
}
//Added By Bhushan on 06-06-2016 :START
private UserInfoBean userInfo1 = null;
public UserInfoBean getUserInfo()
{
return this.userInfo;
}
public void setUserInfo(UserInfoBean userInfo)
{
this.userInfo = userInfo;
}
public Connection getConnection()throws RemoteException,ITMException
{
Connection conn = null;
try
{
if(this.userInfo != null)
{
String transDB = this.userInfo.getTransDB();
System.out.println("getConnection :: transDB :: ["+transDB+"]");
if( transDB != null && transDB.trim().length() > 0 && !"null".equalsIgnoreCase(transDB))
{
ConnDriver connDriver = null;
connDriver = new ConnDriver();
conn = connDriver.getConnectDB(transDB);
connDriver = null;
}
else
{
throw new ITMException(new Exception("Connection file not specified in trans_db column of users table."));
}
}
else
{
throw new ITMException(new Exception("UserInfo is null."));
}
}
catch(Exception e)
{
System.out.println("Exception :[getConnection] :==>\n"+e.getMessage()); //$NON-NLS-1$
e.printStackTrace();
throw new ITMException(e);
}
return conn;
}
//Added By Bhushan on 06-06-2016 :END
}
......@@ -43,10 +43,7 @@ public class RPTValAprvWF
try
{
connDriver = new ConnDriver();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
if(refSer != null && refSer.equalsIgnoreCase("P-ORD"))
{
......@@ -184,10 +181,7 @@ public class RPTValAprvWF
try
{
connDriver = new ConnDriver();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
E12GenericUtility genericUtility = new ibase.utility.E12GenericUtility();
sdf = new SimpleDateFormat(genericUtility.getApplDateFormat());
......@@ -1062,10 +1056,7 @@ public class RPTValAprvWF
try
{
connDriver = new ConnDriver();
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
InetAddress ownIP=InetAddress.getLocalHost();
termID = checkNull(ownIP.getHostAddress());
System.out.println("termID :-["+termID+"]");
......@@ -1328,53 +1319,4 @@ public class RPTValAprvWF
}
return input.trim();
}
//Added By Bhushan on 06-06-2016 :START
private UserInfoBean userInfo = null;
public UserInfoBean getUserInfo()
{
return this.userInfo;
}
public void setUserInfo(UserInfoBean userInfo)
{
this.userInfo = userInfo;
}
public Connection getConnection()throws RemoteException,ITMException
{
Connection conn = null;
try
{
if(this.userInfo != null)
{
String transDB = this.userInfo.getTransDB();
System.out.println("getConnection :: transDB :: ["+transDB+"]");
if( transDB != null && transDB.trim().length() > 0 && !"null".equalsIgnoreCase(transDB))
{
ConnDriver connDriver = null;
connDriver = new ConnDriver();
conn = connDriver.getConnectDB(transDB);
connDriver = null;
}
else
{
throw new ITMException(new Exception("Connection file not specified in trans_db column of users table."));
}
}
else
{
throw new ITMException(new Exception("UserInfo is null."));
}
}
catch(Exception e)
{
System.out.println("Exception :[getConnection] :==>\n"+e.getMessage()); //$NON-NLS-1$
e.printStackTrace();
throw new ITMException(e);
}
return conn;
}
//Added By Bhushan on 06-06-2016 :END
}
......@@ -31,10 +31,7 @@ public class ThreeWayMatchCond {
int resultCnt = 0;
try {
//Changes and Commented By Bhushan on 06-06-2016 :START
//conn = connDriver.getConnectDB("DriverITM");
conn = getConnection();
//Changes and Commented By Bhushan on 06-06-2016 :END
conn = connDriver.getConnectDB("DriverITM");
connDriver = null;
conn.setAutoCommit(false);
timestamp = new Timestamp(System.currentTimeMillis());
......@@ -242,52 +239,4 @@ public class ThreeWayMatchCond {
return retString;
}
//Added By Bhushan on 06-06-2016 :START
private UserInfoBean userInfo = null;
public UserInfoBean getUserInfo()
{
return this.userInfo;
}
public void setUserInfo(UserInfoBean userInfo)
{
this.userInfo = userInfo;
}
public Connection getConnection()throws RemoteException,ITMException
{
Connection conn = null;
try
{
if(this.userInfo != null)
{
String transDB = this.userInfo.getTransDB();
System.out.println("getConnection :: transDB :: ["+transDB+"]");
if( transDB != null && transDB.trim().length() > 0 && !"null".equalsIgnoreCase(transDB))
{
ConnDriver connDriver = null;
connDriver = new ConnDriver();
conn = connDriver.getConnectDB(transDB);
connDriver = null;
}
else
{
throw new ITMException(new Exception("Connection file not specified in trans_db column of users table."));
}
}
else
{
throw new ITMException(new Exception("UserInfo is null."));
}
}
catch(Exception e)
{
System.out.println("Exception :[getConnection] :==>\n"+e.getMessage()); //$NON-NLS-1$
e.printStackTrace();
throw new ITMException(e);
}
return conn;
}
//Added By Bhushan on 06-06-2016 :END
}
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