Commit aa31424f authored by jshaikh's avatar jshaikh

Replaced login code by entity code

git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@175710 ce508802-f39f-4f6c-b175-0d175dae99d5
parent 7a864c7b
......@@ -30,6 +30,8 @@ public class ImportantEventServlet extends HttpServlet
public void doPost(HttpServletRequest request, HttpServletResponse response)
throws IOException, ServletException
{
System.out.println("@@@@@@@@@@@@@@@@ImportantEventServlet@@@@@@@@@@@@@@@@ DOPOST @@@@@@@@@");
ImpEventsRemote impEventsRemote = null;
InitialContext context = null;
......@@ -43,18 +45,17 @@ public class ImportantEventServlet extends HttpServlet
try
{
response.setContentType("application/xml");
session = request.getSession(true);
session = request.getSession(true);
userInfo = (ibase.utility.UserInfoBean) session.getAttribute("USER_INFO");
if(userInfo != null)
{
empCode = userInfo.getEmpCode();
empCode = userInfo.getEntityCode();
}
dataSourceName = request.getParameter("dataSourceName");
context = new InitialContext(appConnectParm.getProperty());
impEventsRemote = (ImpEventsRemote)context.lookup("ibase/ImpEvents/remote");
jsonObjData = (JSONObject) impEventsRemote.getEvents(empCode,dataSourceName);
outputStream = response.getOutputStream();
context = new InitialContext(appConnectParm.getProperty());
impEventsRemote = (ImpEventsRemote)context.lookup("ibase/ImpEvents/remote");
jsonObjData = (JSONObject) impEventsRemote.getEvents(empCode,dataSourceName);
outputStream = response.getOutputStream();
outputStream.write(jsonObjData.toString().getBytes());
outputStream.flush();
outputStream.close();
......
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