Package com.dotmarketing.portlets.workflows.model

Examples of com.dotmarketing.portlets.workflows.model.WorkflowHistory


    taskComment.setPostedBy(user.getUserId());
    HibernateUtil.saveOrUpdate(taskComment);
    relAPI.addRelationship(task.getInode(), taskComment.getInode(), "child");

    //Save the work flow history
    WorkflowHistory hist = new WorkflowHistory ();
    hist.setChangeDescription("Task Creation");
    hist.setCreationDate(new Date ());
    hist.setMadeBy(user.getUserId());
    HibernateUtil.saveOrUpdate(hist);
    relAPI.addRelationship(task.getInode(), hist.getInode(), "child");

    //WorkflowEmailUtil.sendWorkflowChangeEmails (task, "New user content has been submitted", "New Task", null);


  }
View Full Code Here


    taskComment.setPostedBy(user.getUserId());
    taskComment.setWorkflowtaskId(task.getId());
    APILocator.getWorkflowAPI().saveComment(taskComment);

    //Save the work flow history
    WorkflowHistory hist = new WorkflowHistory ();
    hist.setChangeDescription("Task Creation");
    hist.setCreationDate(new Date ());
    hist.setMadeBy(user.getUserId());
    hist.setWorkflowtaskId(task.getId());
    APILocator.getWorkflowAPI().saveWorkflowHistory(hist);
   
    //WorkflowEmailUtil.sendWorkflowChangeEmails (task, "New user content has been submitted", "New Task", null);       

View Full Code Here

              newComment.setWorkflowtaskId(newTask.getId());
              APILocator.getWorkflowAPI().saveComment(newComment);
          }

          for(WorkflowHistory history : APILocator.getWorkflowAPI().findWorkflowHistory(task)) {
              WorkflowHistory newHistory=new WorkflowHistory();
              BeanUtils.copyProperties(history, newHistory);
              newHistory.setId(null);
              newHistory.setWorkflowtaskId(newTask.getId());
              APILocator.getWorkflowAPI().saveWorkflowHistory(newHistory);
          }

          List<IFileAsset> files = APILocator.getWorkflowAPI().findWorkflowTaskFiles(task);
          files.addAll(APILocator.getWorkflowAPI().findWorkflowTaskFilesAsContent(task, APILocator.getUserAPI().getSystemUser()));
View Full Code Here

    return step;
  }

   private WorkflowHistory convertHistory(Map<String, Object> row) throws IllegalAccessException, InvocationTargetException {
      final WorkflowHistory scheme = new WorkflowHistory();
      row.put("actionId", row.get("workflow_action_id"));

      BeanUtils.copyProperties(scheme, row);

      return scheme;
View Full Code Here

    WorkflowTask webAsset = (WorkflowTask) wfAPI.findTaskById(req.getParameter("inode"));
    req.setAttribute(webkey, webAsset);
  }

  private void _logWorkflowTaskHistory (WorkflowTask task, User user, String history) throws DotDataException {
    WorkflowHistory hist = new WorkflowHistory ();
    hist.setChangeDescription(history);
    hist.setCreationDate(new Date ());
    hist.setMadeBy(user.getUserId());
      hist.setWorkflowtaskId(task.getId());
    wfAPI.saveWorkflowHistory(hist);
  }
View Full Code Here

      }
    }
    List<WorkflowHistory> histories = processor.getHistory();
   
    // add this approval to the history
    WorkflowHistory h = new WorkflowHistory();
    h.setActionId(processor.getAction().getId());
    h.setMadeBy(processor.getUser().getUserId());
    if(histories == null){
      histories = new ArrayList<WorkflowHistory>();
      histories.add(h);
    }else histories.add(h);
   
View Full Code Here

    wfac.saveWorkflowTask(task);
  }

  public void saveWorkflowTask(WorkflowTask task, WorkflowProcessor processor) throws DotDataException {
    saveWorkflowTask(task);
    WorkflowHistory history = new WorkflowHistory();
    history.setWorkflowtaskId(task.getId());
    history.setActionId(processor.getAction().getId());
    history.setCreationDate(new Date());
    history.setMadeBy(processor.getUser().getUserId());
    history.setStepId(processor.getNextStep().getId());

    String comment = (UtilMethods.isSet(processor.getWorkflowMessage()))? processor.getWorkflowMessage() : "";
    String nextAssignName = (UtilMethods.isSet(processor.getNextAssign()))? processor.getNextAssign().getName() : "";


    try {
      history.setChangeDescription(
          LanguageUtil.format(processor.getUser().getLocale(), "workflow.history.description", new String[]{
            processor.getUser().getFullName(),
            processor.getAction().getName(),
            processor.getNextStep().getName(),
            nextAssignName,
View Full Code Here

TOP

Related Classes of com.dotmarketing.portlets.workflows.model.WorkflowHistory

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.