Package com.centraview.marketing.marketingfacade

Examples of com.centraview.marketing.marketingfacade.MarketingFacade


      // We will collect the to Information from all the Attendees associated to the Event.
      if (type != null && type.equals("EVENT")){
        String eventID = (String) request.getParameter("eventid");
        if(eventID != null && !eventID.equals("")){
          MarketingFacadeHome cfh = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
          MarketingFacade remote = (MarketingFacade)cfh.create();
          remote.setDataSource(dataSource);
          int eventId = Integer.parseInt(eventID);
          String toList = remote.getEventAttendeesForMail(eventId, individualID);
          emailForm.set("to", toList);
          emailForm.set("subject", "EVENT");
        }// end of if(eventID != null && !eventID.equals(""))
      }// end of if (type != null && type.equals("EVENT"))
View Full Code Here


      HashMap hm = new HashMap();
      hm.put("eventid", eventID);
      hm.put("individualid", rowId);

      MarketingFacadeHome aa = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
      MarketingFacade remote = (MarketingFacade)aa.create();
      remote.setDataSource(dataSource);
      iCount = remote.deleteEventRegister(hm);

      request.setAttribute("TYPEOFOPERATION", "EDIT");
      request.setAttribute("FromAttendee", "NO");
      request.setAttribute("eventid", eventID);
    }
View Full Code Here

    try
    {
    HttpSession session = request.getSession(true);
    com.centraview.common.UserObject userobjectd = (com.centraview.common.UserObject)session.getAttribute("userobject");
    int individualID = userobjectd.getIndividualID();
    MarketingFacade remote = home.create();
    remote.setDataSource(dataSource);
    Vector literaturelist = remote.getAllLiterature();
    String searchStr = request.getParameter("searchTextBox");
    if (searchStr != null && !searchStr.equals("")){
      if (literaturelist != null){
        int size = literaturelist.size();
        int i = 0;
View Full Code Here

    HttpSession session = request.getSession(true);

    try
    {
      MarketingFacadeHome aa = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
      MarketingFacade remote = (MarketingFacade)aa.create();
      remote.setDataSource(dataSource);
      String rowStringId = null;
      String existingListName = null;
      boolean addToList = false;

      if (request.getParameter("listId") != null)
      {
        rowStringId = request.getParameter("listId");
      }else if (request.getAttribute("listId") != null){
        rowStringId = (String)request.getAttribute("listId");
      }   // end if (request.getAttribute("listId") !=null)

      try
      {
        Integer.parseInt(rowStringId);
        addToList = true;
      }catch(Exception ignored){
        //ignored
      }

      Collection marketList = remote.getAllList();
      Collection marketingList = new ArrayList();
      marketingList.add(new DDNameValue("-1", "New Marketing List"));

      Iterator iterator = marketList.iterator();
View Full Code Here

    String dataSource = Settings.getInstance().getSiteInfo(CVUtility.getHostName(super.getServlet().getServletContext())).getDataSource();
  MarketingFacadeHome aa = (MarketingFacadeHome) CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");   
  try
    {

      MarketingFacade remote = (MarketingFacade) aa.create();
      remote.setDataSource(dataSource);
      ListVO listVO = new ListVO();
      listVO.setTitle((String)dynaform.get("listname").toString());
      listVO.setDescription((String)dynaform.get("listdescription").toString());
      if(dynaform.get("listid") != null)
      {
    int listID = Integer.parseInt((String) dynaform.get("listid").toString());
    listVO.setListID(listID);
      }
      remote.updateList(individualID, listVO);
    }
    catch (Exception e)
    {
      logger.error("[Exception] UpdateListHandler.Execute Handler ", e);
    }
View Full Code Here

      int individualId = ((UserObject)session.getAttribute("userobject")).getIndividualID();

      LiteratureForm literatureform = new LiteratureForm();

      MarketingFacadeHome home = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
      MarketingFacade remote = (MarketingFacade)home.create();
      remote.setDataSource(dataSource);
      LiteratureDetails literatureDetails = remote.getLiteratureDetails(activityid,individualId);
      literatureform.setAssignedtoid("" + literatureDetails.getAssignedtoid());
      literatureform.setDeliverymethodid("" + literatureDetails.getDeliveryid());
      literatureform.setEntityid("" + literatureDetails.getEntityid());
      literatureform.setIndividualid("" + literatureDetails.getIndividualid());
      literatureform.setStatusid("" + literatureDetails.getStatusid());
      literatureform.setDetail(literatureDetails.getDetail());
      literatureform.setLiteraturename(literatureDetails.getLiteratureName());
      literatureform.setLiteratureid(literatureDetails.getLiteratureId());
      literatureform.setTitle(literatureDetails.getTitle());
      literatureform.setAssignedtoname(literatureDetails.getAssignedtoname());
      literatureform.setIndividualname(literatureDetails.getIndividualname());
      literatureform.setEntityname(literatureDetails.getEntityname());
      Vector literaturenamevec = new Vector();
      String strLiteratureid = (String)literatureDetails.getLiteratureId();
      String strLiteraturename = (String)literatureDetails.getLiteratureName();
      String strnames = "";

      if (strLiteratureid != null && !strLiteratureid.equals(""))
      {
    StringTokenizer stid = new StringTokenizer(strLiteratureid,",");
    StringTokenizer stName = new StringTokenizer(strLiteraturename,",");
    String strId = "";
    String strName = "";
    while(stid.hasMoreTokens())
    {
      strId = stid.nextToken();
      strName = stName.nextToken();
      if (!strId.equals("")){
        int id = Integer.parseInt(strId);
        literaturenamevec.add(new DDNameValue(id,strName));
      }
    }
      }

      literatureform.setLiteraturenamevec(literaturenamevec);
      literatureform.setNames(strnames);

      if (literatureDetails.getDuebydate() != null)
      {
        Timestamp date = (Timestamp)literatureDetails.getDuebydate();

        String strMonth = "" + (date.getMonth() + 1);
        String strDay = "" + date.getDate();
        String strYear = "" + (date.getYear() + 1900);
        String strHours = "" + date.getHours();
        String strMins = "" + date.getMinutes();
        int hhmm[] = new int[2];
        hhmm[0] = Integer.parseInt(strHours.trim());
        hhmm[1] = Integer.parseInt(strMins.trim());
        String strTime = CVUtility.convertTime24HrsFormatToStr(hhmm);
        literatureform.setDuebymonth(strMonth);
        literatureform.setDuebyday(strDay);
        literatureform.setDuebyyear(strYear);
        literatureform.setDuebytime(strTime);
        literatureform.setSelduebytime(strTime);
      }

      Vector deliverymethodlist = remote.getAllDeliveryMethod();
      request.setAttribute("deliverymethodlist", deliverymethodlist);

      Vector activitystatuslist = remote.getAllActivityStatus();
      request.setAttribute("activitystatuslist", activitystatuslist);

      form = (ActionForm)literatureform;

      // set request
View Full Code Here

  {
    String dataSource = Settings.getInstance().getSiteInfo(CVUtility.getHostName(super.getServlet().getServletContext())).getDataSource();
    MarketingFacadeHome marketingFacadeHome = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome","MarketingFacade");
    try
    {
      MarketingFacade remote =( MarketingFacade )marketingFacadeHome.create();
         remote.setDataSource(dataSource);
      int eventid = Integer.parseInt(request.getParameter("eventid").toString());
      remote.deleteEvent(eventid);
    }
    catch(Exception e)
    {
      resultPage = "failure";
      logger.error("[Exception] DeleteEventHandler.Execute Handler ", e);
View Full Code Here

      HashMap literatureHashMap = null;
      // to identify multiple opened window
      String newWindowId = "1";

      MarketingFacadeHome home = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
      MarketingFacade remote = home.create();
      remote.setDataSource(dataSource);
      Vector deliverymethodlist = remote.getAllDeliveryMethod();
      request.setAttribute("deliverymethodlist", deliverymethodlist);

      Vector activitystatuslist = remote.getAllActivityStatus();
      request.setAttribute("activitystatuslist", activitystatuslist);

      // set request
      request.setAttribute(MarketingConstantKeys.CURRENTTAB, MarketingConstantKeys.DETAIL);
      request.setAttribute(MarketingConstantKeys.TYPEOFOPERATION, MarketingConstantKeys.ADD);
View Full Code Here

        // the int representation for use in the code below
        eventID = formEventID.intValue();
      }

      MarketingFacadeHome home = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
      MarketingFacade remote = home.create();
      remote.setDataSource(dataSource);

      EventDetails eventDetails = (EventDetails)remote.getCustomerEventDetails(eventID);
      boolean isRegistered = remote.hasUserAcceptedEvent(eventID, individualID);

      if (eventDetails == null) {
        // if eventDetails is null, then we have to show the
        // user an error. Tell them we couldn't get Event details
        // from the database, and quit
View Full Code Here

        // the int representation for use in the code below
        eventID = formEventID.intValue();
      }
     
      MarketingFacadeHome home = (MarketingFacadeHome)CVUtility.getHomeObject("com.centraview.marketing.marketingfacade.MarketingFacadeHome", "MarketingFacade");
      MarketingFacade remote = home.create();
      remote.setDataSource(dataSource);

      Boolean registerAction = (Boolean)eventForm.get("registerAction");
     
      HashMap mapEvent = new HashMap();
     
      if (registerAction.booleanValue() == true) {
        boolean accepted = remote.hasUserAcceptedEvent(eventID, individualID);

        if (! accepted) {
          mapEvent.put("eventid", String.valueOf(eventID));
          mapEvent.put("individualid", String.valueOf(individualID));
          mapEvent.put("accepted", "YES");
        }
      }else{
        mapEvent.put("eventid", String.valueOf(eventID));
        mapEvent.put("individualid", String.valueOf(individualID));
        mapEvent.put("accepted", "NO");
      }
     
      int registrationID = remote.registerAttendee(mapEvent);
     
    }catch(Exception e){
      System.out.println("[Exception][CV ViewEventHandler] Exception thrown in execute(): " + e);
    }
    return(mapping.findForward(forward));
View Full Code Here

TOP

Related Classes of com.centraview.marketing.marketingfacade.MarketingFacade

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.