Could you please tell us what problem do you have? And please post
user questions to user mailing list - this list is about developing
Struts itself


Regards
-- 
Ɓukasz
+ 48 606 323 122 http://www.lenart.org.pl/

2015-07-14 22:26 GMT+02:00 Anil Kilari <kilarian...@gmail.com>:
> Hi
>
>
> I have a problem in calling EJB methods in struts 1.3 . Could you please
> help me out from this blocker ?
>
>  public ActionForward performAction(ActionMapping mapping,
>                                         ActionForm form,
>                                         HttpServletRequest request,
>                                         HttpServletResponse response)
>
>     {
>       //if method = create
>         ActionForward forwardTo = null;
>         ActionMessages errors = null;
>         InternalUser user = super.getUser(request.getSession());
>
> String method = request.getParameter("method");
> if (method != null && method.equals("create")) {
> DatabaseVO dbVO = new DatabaseVO("isis");//need to be changed to use
> database name from ISIS form parameter passed in.
> CreateFundArrayForm createForm = (CreateFundArrayForm)form;
> String pricingClass=createForm.getPricingClass();
> String fundArrayName=createForm.getFundArrayName();
> ArrayList provCompany=createForm.getProvCompany();
> String effectiveDate=createForm.getEffectiveDate();
> Date effDate=convertToSQLDate(effectiveDate);
> Long retValue=null;
>  FundArrayDelegate fundArrayDelegate = new FundArrayDelegate();
> createForm.setAllFundArrayProvCompanies(FundArrayDelegate.getAllFundArrayProvCompanies(user
> , dbVO) );
>  FundArrayVO fundArrayVO = new FundArrayVO(dbVO);
> fundArrayVO.setPricingClass(pricingClass);
> fundArrayVO.setName(fundArrayName);
> //fundArrayVO.setProvCompany(provCompany);
> fundArrayVO.setEffdate(effDate);
> logger.debug("========================================"+pricingClass + ":"+
> fundArrayName + ":" + provCompany + ":" +
> effDate+"========================================");
> logger.info("SessionId: " + request.getSession().getId() + " PricingClass "
> + pricingClass+
>         " Product PVCO: " + provCompany + " FundArrayName: " +
> fundArrayName+
>         " Effective Date: " + effectiveDate);
>
> try {
> retValue=FundArrayDelegate.createFundArray(user, fundArrayVO);
> System.out.println("Return value is " +retValue);
> } catch (ValidationException e) {
> // TODO Auto-generated catch block
>  System.out.println("========Exception in returning the value======");
> e.printStackTrace();
>  }
> } else if (method != null && method.equals("update")) {
>  } else if (method != null && method.equals("detail")) {
> forwardTo = mapping.findForward("detail");
> }
>       forwardTo = mapping.findForward("success");
>        return forwardTo;
>     }

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@struts.apache.org
For additional commands, e-mail: dev-h...@struts.apache.org

Reply via email to