Commit bd3abf88 authored by vvengurlekar's avatar vvengurlekar

changes done in ejb and servlet as currancy and format value scale added


git-svn-id: http://15.206.35.175/svn/proteus/business-java/trunk@105550 ce508802-f39f-4f6c-b175-0d175dae99d5
parent e37eea9e
...@@ -14,9 +14,9 @@ import org.json.simple.JSONObject; ...@@ -14,9 +14,9 @@ import org.json.simple.JSONObject;
public interface ProfitNLossSummaryLocal extends ValidatorLocal { public interface ProfitNLossSummaryLocal extends ValidatorLocal {
public JSONObject getProfitBalanceSheetDetails(String sitecode, String acctprd,String formatcode,String reporttype,String dataSourceName) throws RemoteException, ITMException; public JSONObject getProfitBalanceSheetDetails(String sitecode, String acctprd,String formatcode,String reporttype,String dataSourceName, String formatValueScale) throws RemoteException, ITMException;
public JSONObject generateReport(String siteCode,String acctPrd, String formatCode,String reportType,String dataSourceName) throws RemoteException, ITMException; public JSONObject generateReport(String siteCode,String acctPrd, String formatCode,String reportType,String dataSourceName, String formatValueScale) throws RemoteException, ITMException;
public boolean populateSubGroup(String siteCode,String siteDescr,String titleCode,double curGroupTotal,double preGroupTotal, public boolean populateSubGroup(String siteCode,String siteDescr,String titleCode,double curGroupTotal,double preGroupTotal,
int printLevel,String acctPrd,String prdFrom,String prdTo,String prevPrd,String prevPrdCodeFrom,String prevPrdCodeTo,String formatCode, int printLevel,String acctPrd,String prdFrom,String prdTo,String prevPrd,String prevPrdCodeFrom,String prevPrdCodeTo,String formatCode,
String reportType,String factor,JSONObject rawDataJson,String dataSourceName,String titleCodeParent,Connection conn,StringBuffer rowBuffer) throws RemoteException, ITMException; String reportType,String factor,JSONObject rawDataJson,String dataSourceName,String titleCodeParent,Connection conn,StringBuffer rowBuffer, String formatValueScale) throws RemoteException, ITMException;
} }
...@@ -14,10 +14,10 @@ import org.json.simple.JSONObject; ...@@ -14,10 +14,10 @@ import org.json.simple.JSONObject;
public interface ProfitNLossSummaryRemote extends ValidatorRemote{ public interface ProfitNLossSummaryRemote extends ValidatorRemote{
//public JSONObject getProfitBalanceSheetDetails(String sitecode, String prdfrom,String prdto,String acctprd,String formatcode,String reporttype,String dataSourceName) throws RemoteException, ITMException; //public JSONObject getProfitBalanceSheetDetails(String sitecode, String prdfrom,String prdto,String acctprd,String formatcode,String reporttype,String dataSourceName) throws RemoteException, ITMException;
public JSONObject getProfitBalanceSheetDetails(String sitecode, String acctprd,String formatcode,String reporttype,String dataSourceName) throws RemoteException, ITMException; public JSONObject getProfitBalanceSheetDetails(String sitecode, String acctprd,String formatcode,String reporttype,String dataSourceName, String formatValueScale) throws RemoteException, ITMException;
//public JSONObject generateReport(String siteCode,String acctPrd,String prdFrom,String prdTo, String formatCode,String reportType,String dataSourceName) throws RemoteException, ITMException; //public JSONObject generateReport(String siteCode,String acctPrd,String prdFrom,String prdTo, String formatCode,String reportType,String dataSourceName) throws RemoteException, ITMException;
public JSONObject generateReport(String siteCode,String acctPrd, String formatCode,String reportType,String dataSourceName) throws RemoteException, ITMException; public JSONObject generateReport(String siteCode,String acctPrd, String formatCode,String reportType,String dataSourceName, String formatValueScale) throws RemoteException, ITMException;
public boolean populateSubGroup(String siteCode,String siteDescr,String titleCode,double curGroupTotal,double preGroupTotal, public boolean populateSubGroup(String siteCode,String siteDescr,String titleCode,double curGroupTotal,double preGroupTotal,
int printLevel,String acctPrd,String prdFrom,String prdTo,String prevPrd,String prevPrdCodeFrom,String prevPrdCodeTo,String formatCode, int printLevel,String acctPrd,String prdFrom,String prdTo,String prevPrd,String prevPrdCodeFrom,String prevPrdCodeTo,String formatCode,
String reportType,String factor,JSONObject rawDataJson,String dataSourceName,String titleCodeParent,Connection conn,StringBuffer rowBuffer) throws RemoteException, ITMException; String reportType,String factor,JSONObject rawDataJson,String dataSourceName,String titleCodeParent,Connection conn,StringBuffer rowBuffer, String formatValueScale) throws RemoteException, ITMException;
} }
...@@ -32,7 +32,7 @@ public class ProfitNLossSummaryServlet extends HttpServlet ...@@ -32,7 +32,7 @@ public class ProfitNLossSummaryServlet extends HttpServlet
InitialContext context = null; InitialContext context = null;
AppConnectParm appConnectParm = new AppConnectParm(); AppConnectParm appConnectParm = new AppConnectParm();
String dataSourceName = ""; String dataSourceName = "";
String prdfrom = "", acctprd = "",sitecode="",prdto="",formatcode="",reporttype=""; String prdfrom = "", acctprd = "",sitecode="",prdto="",formatcode="",reporttype="", formatValueScale="";
try try
{ {
response.setContentType("application/xml"); response.setContentType("application/xml");
...@@ -44,7 +44,8 @@ public class ProfitNLossSummaryServlet extends HttpServlet ...@@ -44,7 +44,8 @@ public class ProfitNLossSummaryServlet extends HttpServlet
acctprd = request.getParameter("acctprd"); acctprd = request.getParameter("acctprd");
formatcode = request.getParameter("formatcode"); formatcode = request.getParameter("formatcode");
reporttype = request.getParameter("reporttype"); reporttype = request.getParameter("reporttype");
dataSourceName = request.getParameter("dataSourceName"); dataSourceName = request.getParameter("dataSourceName");
formatValueScale = request.getParameter("formatValueScale");
System.out.println("in doPost" ); System.out.println("in doPost" );
System.out.println("days is =" + sitecode ); System.out.println("days is =" + sitecode );
System.out.println("days is =" + prdfrom ); System.out.println("days is =" + prdfrom );
...@@ -55,7 +56,7 @@ public class ProfitNLossSummaryServlet extends HttpServlet ...@@ -55,7 +56,7 @@ public class ProfitNLossSummaryServlet extends HttpServlet
context = new InitialContext(appConnectParm.getProperty()); context = new InitialContext(appConnectParm.getProperty());
profitLossBalSheetRemote = (ProfitNLossSummaryRemote) context.lookup("ibase/ProfitNLossSummary/remote"); profitLossBalSheetRemote = (ProfitNLossSummaryRemote) context.lookup("ibase/ProfitNLossSummary/remote");
JSONObject jsonObjData = (JSONObject)profitLossBalSheetRemote.getProfitBalanceSheetDetails(sitecode,acctprd,formatcode,reporttype,dataSourceName); JSONObject jsonObjData = (JSONObject)profitLossBalSheetRemote.getProfitBalanceSheetDetails(sitecode,acctprd,formatcode,reporttype,dataSourceName,formatValueScale);
OutputStream outputStream = response.getOutputStream(); OutputStream outputStream = response.getOutputStream();
outputStream.write(jsonObjData.toString().getBytes()); outputStream.write(jsonObjData.toString().getBytes());
outputStream.flush(); outputStream.flush();
......
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