Package com.centraview.common

Examples of com.centraview.common.DDNameValue


    for (int i = 0; i != level; i++)
      sb.append("-");
    sb.append(catVO.getTitle());
    level++;
   
    finalList.add(new DDNameValue(catVO.getCatid(), sb.toString()));
   
    Iterator iter = catList.iterator();
    while (iter.hasNext()) {
      CategoryVO tmp = (CategoryVO)iter.next();
      if (tmp.getParent() == catVO.getCatid())
View Full Code Here


    {
      strId = stid.nextToken();
      strName = stName.nextToken();
      if (!strId.equals("")){
        int id = Integer.parseInt(strId);
        literaturenamevec.add(new DDNameValue(id,strName));
      }
    }
      }

      literatureform.setLiteraturenamevec(literaturenamevec);
View Full Code Here

      int i = 0;
      while (iter.hasNext()) {
        CvFileVO fileVO = (CvFileVO)iter.next();
        int fileID = fileVO.getFileId();
        String fileName = fileVO.getTitle();
        attachmentMap.add(new DDNameValue(fileID+"#"+fileName,fileName));
      }

      if (saveOrigBodyAsAttachment) {
        CvFolderVO attachmentFolderVO = (CvFolderVO)remote.getAttachmentFolder(individualID);
        int attachmentFolderID = attachmentFolderVO.getFolderId();
        int newFileID = -1;

        // somehow create a file using CvFileFacade, and get a CvFileVO from that.
        CvFileVO fileVO = new CvFileVO();
        SimpleDateFormat df = new SimpleDateFormat("MMMM_dd_yyyy_hh_mm_ss_S");
        String prependDate = df.format(new Date());
        fileVO.setName("OriginalMessage_#" + messageID.intValue() + "_" + prependDate + ".html");
        fileVO.setTitle("OriginalMessage_#" + messageID.intValue());
        fileVO.setDescription("");
        fileVO.setFileSize(0.0f);   // float
        fileVO.setVersion("1.0");
        fileVO.setStatus("PUBLISHED");
        fileVO.setVisibility(CvFileVO.FV_PRIVATE);
        fileVO.setPhysical(CvFileVO.FP_PHYSICAL);
        fileVO.setPhysicalFolder(attachmentFolderID);
        fileVO.setAuthorId(individualID);
        fileVO.setIsTemporary(CvFileVO.FIT_YES);

        ByteArrayInputStream inputStream = new ByteArrayInputStream(originalBody.getBytes());

        try {
          CvFileFacade fileFacade = new CvFileFacade();
          newFileID = fileFacade.addFile(individualID, attachmentFolderID, fileVO, inputStream, dataSource);
        }catch(CvFileException cfe){
          // I guess do nothing
        }

        if (newFileID > 0) {
          // Add the CvFileVO to attachmentList, and the following line for the attachmentMap
          fileVO.setFileId(newFileID);

          String FileName= "OriginalMessage_" + messageID.intValue();
          attachmentMap.add(new DDNameValue(newFileID+"#"+FileName,FileName));
        }
      }   // end if (saveOrigBodyAsAttachment)

      if (! attachmentMap.isEmpty()) {
        emailForm.set("attachmentList", attachmentMap);
View Full Code Here

      SupportFacadeHome supportFacade = (SupportFacadeHome)CVUtility.getHomeObject("com.centraview.support.supportfacade.SupportFacadeHome","SupportFacade");
      SupportFacade remote =(SupportFacade)supportFacade.create();
      ArrayList flatList = (ArrayList)remote.getAllCategory(userId);
      ArrayList categoryList = new ArrayList();
     
      categoryList.add(new DDNameValue(1, "Knowledgebase"));
      Iterator iter = flatList.iterator();
      while (iter.hasNext()) {
        CategoryVO catVO = (CategoryVO)iter.next();
        if (catVO.getParent() == 1)
          KBUtil.processCategory(flatList, catVO, categoryList, 0);
View Full Code Here

          int indexOfHash = fileKeyName.indexOf("#");
          if (indexOfHash != -1) {
            int lenString = fileKeyName.length();
            String fileID = fileKeyName.substring(0, indexOfHash);
            String fileName = fileKeyName.substring(indexOfHash + 1, lenString);
            attachments.add(new DDNameValue(fileID + "#" + fileName, fileName));
            attachmentFileIDs.add(new Integer(fileID));
          }
        }
      }// end of while (attachIter.hasNext())
    }// end of if (tempAttachmentMap != null && tempAttachmentMap.size() > 0)
View Full Code Here

  public Vector getStatusVec()
  {
    Vector vec =  new Vector();
   
    vec.add(new DDNameValue(1,"Available"));
    vec.add(new DDNameValue(2,"BackOrdered"));
    vec.add(new DDNameValue(3,"Not Available"));
   
    statusVec = vec;
   
    return this.statusVec;
  }
View Full Code Here

      request.setAttribute("actionName", "");
      activityForm.setActivityType(activityType + "");

      // set user as default attendee
      DDNameValue setUserAttendee = new DDNameValue("" + individualID + "#" + userName, userName);
      Vector att_required = new Vector();
      att_required.add(setUserAttendee);

      String[] attRequiredArray = new String[1];
      attRequiredArray[0] = "" + individualID + "#" + userName;
View Full Code Here

      SupportFacade remote =(SupportFacade)supportFacade.create();
     
      ArrayList flatList = (ArrayList)remote.getAllCategory(userId);
      ArrayList categoryList = new ArrayList();
     
      categoryList.add(new DDNameValue(1, "Knowledgebase"));
      Iterator iter = flatList.iterator();
      while (iter.hasNext()) {
        CategoryVO catVO = (CategoryVO)iter.next();
        if (catVO.getParent() == 1)
          KBUtil.processCategory(flatList, catVO, categoryList, 0);
View Full Code Here

        // Get all categories and recurively process them for there parent/child
        // relationships.
        ArrayList flatList = remote.getAllCategory(individualID);
        ArrayList categoryList = new ArrayList();

        categoryList.add(new DDNameValue(1, "Knowledgebase"));
        Iterator iter = flatList.iterator();
        while (iter.hasNext()) {
          CategoryVO catVO = (CategoryVO)iter.next();
          if (catVO.getParent() == 1)
            KBUtil.processCategory(flatList, catVO, categoryList, 0);
View Full Code Here

        form =  new PromotionDetailListForm();
        request.setAttribute("promotionlistform", new PromotionDetailListForm());
      }
      request.setAttribute("ItemLines",itemLines);
      ArrayList colStatus = new ArrayList();
            colStatus.add(new DDNameValue("YES","Active"));
            colStatus.add(new DDNameValue("NO","Inactive"));
            request.setAttribute("colStatus", colStatus);

            // forward to jsp page
      FORWARD_final = FORWARD_Promotion;
      if (request.getParameter("Forward") != null && request.getParameter("Forward").equals("Listing"))
View Full Code Here

TOP

Related Classes of com.centraview.common.DDNameValue

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.