Commit da7bd8c0 authored by ssalve's avatar ssalve

Sarita : Done changes to 1. remove Lookup for ITMDBAccessEJB and created...

Sarita : Done changes to 1. remove Lookup for ITMDBAccessEJB and created object and  2. use connection method of ITMDBAccessEJB for calling getErrorString 

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@187989 ce508802-f39f-4f6c-b175-0d175dae99d5
parent dca0b115
......@@ -5,7 +5,7 @@ import java.rmi.RemoteException;
import ibase.system.config.ConnDriver;
import ibase.utility.EMail;
import ibase.webitm.ejb.ITMDBAccessEJB;
import ibase.webitm.ejb.ITMDBAccessLocal;
//import ibase.webitm.ejb.ITMDBAccessLocal;//Commented by sarita on 20 JULY 18
import ibase.webitm.ejb.ValidatorEJB;
import ibase.webitm.utility.GenericUtility;
import ibase.webitm.utility.ITMException;
......@@ -51,8 +51,10 @@ public class EmpTranPromCanc extends ActionHandlerEJB implements EmpTranPromCanc
String confirm = "";
String retString = "";
ITMDBAccessLocal itmDBAccessLocal = (ITMDBAccessLocal) new ITMDBAccessEJB();
//Added & Commented by sarita to create object of ITMDBAccessEJB instead ITMDBAccessLocal on 20 JULY 18.[START]
//ITMDBAccessLocal itmDBAccessLocal = (ITMDBAccessLocal) new ITMDBAccessEJB();
ITMDBAccessEJB itmDBAccessEJB = new ITMDBAccessEJB();
//Added & Commented by sarita to create object of ITMDBAccessEJB instead ITMDBAccessLocal on 20 JULY 18.[END]
try
{
......@@ -79,7 +81,10 @@ public class EmpTranPromCanc extends ActionHandlerEJB implements EmpTranPromCanc
}
else
{
retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT01", userID);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [START]
//retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT01", userID);
retString = itmDBAccessEJB.getErrorString("","VTEMPEVT01",userID,"",conn);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [END]
}
System.out.println(" confirm [" + confirm + "] ");
closePstmtRset(pstmt, rs);
......@@ -99,25 +104,40 @@ public class EmpTranPromCanc extends ActionHandlerEJB implements EmpTranPromCanc
System.out.println("canceled the request [::" + updStatus);
if(updStatus > 0)
{
retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT01", userID);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [START]
//retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT01", userID);
retString = itmDBAccessEJB.getErrorString("","VTEMPEVT01",userID,"",conn);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [END]
conn.commit();
}
else
{
retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT02", userID);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [START]
//retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT02", userID);
retString = itmDBAccessEJB.getErrorString("","VTEMPEVT02",userID,"",conn);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [END]
conn.rollback();
}
} else
{
retString = itmDBAccessLocal.getErrorString("", "EMPAPRV", userID);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [START]
//retString = itmDBAccessLocal.getErrorString("", "EMPAPRV", userID);
retString = itmDBAccessEJB.getErrorString("","EMPAPRV",userID,"",conn);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [END]
}
} else if (confirm.equalsIgnoreCase("X"))
{
retString = itmDBAccessLocal.getErrorString("", "VTCANCEL", userID);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [START]
//retString = itmDBAccessLocal.getErrorString("", "VTCANCEL", userID);
retString = itmDBAccessEJB.getErrorString("","VTCANCEL",userID,"",conn);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [END]
} else if (confirm.equalsIgnoreCase("Y"))
{
retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT03", userID);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [START]
//retString = itmDBAccessLocal.getErrorString("", "VTEMPEVT03", userID);
retString = itmDBAccessEJB.getErrorString("","VTEMPEVT03",userID,"",conn);
//Added and commented by sarita on to call getErrorString connection method on 20 JULY 2018 [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