Package com.centraview.support.supportfacade

Examples of com.centraview.support.supportfacade.SupportFacade


      remoteTicket.setDataSource(dataSource);
     
      TicketVO tVO = remoteTicket.getTicketBasicRelations(individualID, ticketID);
     
      SupportFacadeHome supFacade = (SupportFacadeHome)CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome", "SupportFacade");
      SupportFacade remote = supFacade.create();
      remote.setDataSource(dataSource);
     
      CvFileHome fileHome = (CvFileHome)CVUtility.getHomeObject("com.centraview.file.CvFileHome", "CvFile");
      CvFile remoteFile = fileHome.create();
      remoteFile.setDataSource(dataSource);
     
      FileList fileList = null;
     
      if (tVO.getId() != 0) {
        fileList = remoteFile.getAllTicketFiles(individualID, tVO.getId());
      }
     
      ThreadList threadList = remote.getThreadList(individualID, tVO.getId());
      threadList = setLinksfunction(threadList);
      Vector timeSlipColumns = new Vector();

      timeSlipColumns.addElement("Description");
      timeSlipColumns.addElement("CreatedBy");
View Full Code Here


      TicketVO ticketVO = new TicketVO();
      TicketForm ticketForm = (TicketForm)form;

      SupportFacadeHome supportFacade = (SupportFacadeHome)CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome", "SupportFacade");
      SupportFacade remote = (SupportFacade)supportFacade.create();
      remote.setDataSource(dataSource);

      if (ticketForm.getSubject() != null) {
        ticketVO.setTitle(ticketForm.getSubject());
      }
     
      if (ticketForm.getDetail() != null) {
        ticketVO.setDetail(ticketForm.getDetail());
      }

      if (ticketForm.getPriority() != null) {
        ticketVO.setPriorityId(Integer.parseInt(ticketForm.getPriority()));
      }else{
        ticketVO.setPriorityId(Integer.parseInt(request.getParameter("priority")));
      }
     
      if (ticketForm.getStatus() != null) {
        ticketVO.setStatusId(Integer.parseInt(ticketForm.getStatus()));
      }

      if ((ticketForm.getManagerid() != null) && (!ticketForm.getManagerid().equals(""))) {
        ticketVO.setManagerId(Integer.parseInt(ticketForm.getManagerid()));
      }
     
      if ((ticketForm.getAssignedtoid() != null) && (!ticketForm.getAssignedtoid().equals(""))) {
        ticketVO.setAssignedToId(Integer.parseInt(ticketForm.getAssignedtoid()));
      }

      if ((ticketForm.getEntityid() != null) && (!ticketForm.getEntityid().equals(""))) {
        ticketVO.setRefEntityId(Integer.parseInt(ticketForm.getEntityid()));
      }

      if ((ticketForm.getContactid() != null) && (!ticketForm.getContactid().equals(""))) {
        ticketVO.setRefIndividualId(Integer.parseInt(ticketForm.getContactid()));
      }

      ticketVO.setCreatedBy(individualId);
      ticketVO.setCustomField(getCustomFieldVO(request, response));
      ticketVO.setId(Integer.parseInt(ticketForm.getId()));
      remote.updateTicket(individualId, ticketVO);

      String closeornew = (String)request.getParameter("closeornew");
      String saveandclose = null;
      String saveandnew = null;
      if (closeornew.equals("close")) {
View Full Code Here

    try {
      HttpSession session = request.getSession();
      int individualId = ((UserObject)session.getAttribute("userobject")).getIndividualID();

      SupportFacadeHome sfh = (SupportFacadeHome)CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome", "SupportFacade");
      SupportFacade remote = (SupportFacade)sfh.create();
      remote.setDataSource(dataSource);

      TicketVO tVO = remote.getTicketBasicRelations(individualId, Integer.parseInt(request.getParameter("ticketId").toString()));

      TicketForm ticketForm = (TicketForm)form;

      if (tVO != null) {
        if (ticketForm != null) {
View Full Code Here

      CategoryVO categoryVO = new CategoryVO();
      CategoryForm catForm = (CategoryForm) form;

      SupportFacadeHome supportFacade = (SupportFacadeHome) CVUtility
        .getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome", "SupportFacade");
      SupportFacade remote = (SupportFacade) supportFacade.create();
      remote.setDataSource(dataSource);

      KnowledgebaseList displaylist = (KnowledgebaseList) session.getAttribute("displaylist");
      int catid = displaylist.getCurrentCategoryID();
      remote.deleteCategory(individualID, catid);

      FORWARD_final = FORWARD_category;
    }
    catch (Exception e)
    {
View Full Code Here

      int individualID = userObject.getIndividualID();
      String ticketStatus = request.getParameter("closeorreopen");
      int ticketID = Integer.parseInt(request.getParameter("ticketID"));
      SupportFacadeHome supFacadeHome = (SupportFacadeHome) CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome",
          "SupportFacade");
      SupportFacade supFacadeRemote = supFacadeHome.create();
      supFacadeRemote.setDataSource(dataSource);
      if (ticketStatus.equals(TicketConstantKeys.TK_OCSTATUS_CLOSE)) {
        supFacadeRemote.closeTicket(individualID, ticketID);
        request.setAttribute("OCStatus", TicketConstantKeys.TK_OCSTATUS_CLOSE);
      } else if (ticketStatus.equals(TicketConstantKeys.TK_OCSTATUS_OPEN)) {
        supFacadeRemote.reopenTicket(individualID, ticketID);
        request.setAttribute("OCStatus", TicketConstantKeys.TK_OCSTATUS_OPEN);
      }
      request.setAttribute("ticketID", new Integer(ticketID));
      request.setAttribute("refreshWindow", "true");
      FORWARD_final = ".view.support.ticket_detail";
View Full Code Here

      CategoryForm catForm = (CategoryForm) form;

      SupportFacadeHome supportFacade = (SupportFacadeHome) CVUtility
        .getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome",
          "SupportFacade");
      SupportFacade remote = (SupportFacade) supportFacade.create();
      remote.setDataSource(dataSource);

      String closeornew = (String) request.getParameter("closeornew");
      String saveandclose = null;
      String saveandnew = null;

      if (closeornew.equals("close"))
      {
        saveandclose = "saveandclose";
      }
      else if (closeornew.equals("new"))
      {
        saveandnew = "saveandnew";
      }

      if (saveandclose != null)
      {
        request.setAttribute("closeWindow", "true");
      }
      request.setAttribute("refreshWindow", "true");

      if (catForm.getCategoryname() != null)
      {
        categoryVO.setTitle(catForm.getCategoryname());
      }

      if (catForm.getParentcategory() != null)
      {
        categoryVO.setParent(Integer.parseInt(catForm.getParentcategory()));
      }
      categoryVO.setCreatedBy(individualID);
      categoryVO.setOwner(individualID);
      remote.insertCategory(individualID, categoryVO);

      FORWARD_final = FORWARD_editsavefile;
    }
    catch (Exception e)
    {
View Full Code Here

      }

      String categoryId = Integer.toString(catid);
      request.setAttribute("rowId", categoryId);

      SupportFacade remote = (SupportFacade) supportFacade.create();
      remote.setDataSource(dataSource);
      CategoryVO catVO = remote.getCategory(individualID, catid);

      if (catVO == null)
        throw new Exception("Bad category");
      catForm.setCategoryname(catVO.getTitle());
      catForm.setParentcatid(catVO.getParent());
     
      // Format created time
      Timestamp timeStamp = catVO.getCreatedOn();
      if (timeStamp != null){
        Date d = new Date(timeStamp.getTime());
        DateFormat df = new SimpleDateFormat("MMM dd, yyyy hh:mm:ss a");
        catForm.setCreated(df.format(d));
      }
     
      // Format modified time
      timeStamp = catVO.getModifiedOn();
      if (timeStamp != null){
        Date d = new Date(timeStamp.getTime());
        DateFormat df = new SimpleDateFormat("MMM dd, yyyy hh:mm:ss a");
        catForm.setModified(df.format(d));
      }
     
      catForm.setOwner(catVO.getOwnerVO().getFirstName() + " "
        + catVO.getOwnerVO().getLastName());
      catForm.setOwnerid(new Integer(catVO.getCreatedBy()).toString());
      catForm.setStatus(catVO.getStatus());
      catForm.setPublishToCustomerView(catVO.getPublishToCustomerView());
      request.setAttribute("catform", catForm);

      String closeornew = (String) request.getParameter("closeornew");

      if (closeornew != null)
      {
        if (closeornew.equals("new"))
        {
          catForm.setCategoryname("");
        }
      }

      ArrayList flatList = (ArrayList)remote.getAllCategory(individualID);
      ArrayList categoryList = new ArrayList();
      categoryList.add(new DDNameValue(1, "Knowledgebase"));
      Iterator iter = flatList.iterator();
      while (iter.hasNext()) {
        CategoryVO cVO = (CategoryVO)iter.next();
View Full Code Here

      TicketVO ticketVO = new TicketVO();
      TicketForm ticketForm = (TicketForm) form;

      SupportFacadeHome supportFacade = (SupportFacadeHome) CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome",
          "SupportFacade");
      SupportFacade remote = supportFacade.create();
      remote.setDataSource(dataSource);

      if (ticketForm.getSubject() != null) {
        ticketVO.setTitle(ticketForm.getSubject());
      }

      if (ticketForm.getDetail() != null) {
        ticketVO.setDetail(ticketForm.getDetail());
      }

      if (ticketForm.getPriority() != null) {
        ticketVO.setPriorityId(Integer.parseInt(ticketForm.getPriority()));
      }

      if (ticketForm.getStatus() != null) {
        ticketVO.setStatusId(Integer.parseInt(ticketForm.getStatus()));
      }

      if ((ticketForm.getManagerid() != null) && (!ticketForm.getManagerid().equals(""))) {
        ticketVO.setManagerId(Integer.parseInt(ticketForm.getManagerid()));
      }

      if ((ticketForm.getAssignedtoid() != null) && (!ticketForm.getAssignedtoid().equals(""))) {
        ticketVO.setAssignedToId(Integer.parseInt(ticketForm.getAssignedtoid()));
      }

      if ((ticketForm.getEntityid() != null) && (!ticketForm.getEntityid().equals(""))) {
        ticketVO.setRefEntityId(Integer.parseInt(ticketForm.getEntityid()));
      }

      if ((ticketForm.getContactid() != null) && (!ticketForm.getContactid().equals(""))) {
        ticketVO.setRefIndividualId(Integer.parseInt(ticketForm.getContactid()));
      }

      ticketVO.setCreatedBy(individualID);
      ticketVO.setCustomField(getCustomFieldVO(request, response));

      int ticketID = remote.addTicket(individualID, ticketVO);

      if (ticketID != 0) {
        int statusID = ticketVO.getStatusId();
        if (statusID == 2) {
          remote.closeTicket(individualID, ticketID);
          request.setAttribute("OCStatus", TicketConstantKeys.TK_OCSTATUS_CLOSE);
        }
      }

      request.setAttribute("rowId", ticketID + "");
View Full Code Here

      tVO.setPriorityId(Integer.parseInt((dynaForm.get("priority")).toString()));
      tVO.setCreatedBy(individualID);
      tVO.setOwner(individualID);
     
      SupportFacadeHome sfh = (SupportFacadeHome)CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome", "SupportFacade");
      SupportFacade remote = (SupportFacade) sfh.create();
      remote.setDataSource(dataSource);
     
      remote.addThread(individualID, tVO);
     
      String closeornew = (String) request.getParameter("closeornew");
      String saveandclose = null;
      String saveandnew = null;
     
View Full Code Here

      t.setDataSource(dataSource);

      TicketVO tVO = t.getTicketBasicRelations(individualId, ticketId);

      SupportFacadeHome supFacade = (SupportFacadeHome)CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome", "SupportFacade");
      SupportFacade remote = supFacade.create();
      remote.setDataSource(dataSource);

      CvFileHome fileHome = (CvFileHome)CVUtility.getHomeObject("com.centraview.file.CvFileHome", "CvFile");
      CvFile cvFile = fileHome.create();
      cvFile.setDataSource(dataSource);
      FileList fileList = null;
     
      if (tVO.getId() != 0) {
        fileList = cvFile.getAllTicketFiles(individualId, tVO.getId());
        fileList = setLinksFunction(fileList);
      }

      ThreadList threadList = remote.getThreadList(individualId, tVO.getId());
      threadList = setLinksfunction(threadList);

      ListGenerator lg1 = ListGenerator.getListGenerator(dataSource);
      HashMap hmDispLists = lg1.getDisplayLists();
View Full Code Here

TOP

Related Classes of com.centraview.support.supportfacade.SupportFacade

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.