Package com.dotmarketing.portlets.workflows.model

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


    BeanUtils.copyProperties(actionClass, row);
    return actionClass;
  }

  private WorkflowActionClassParameter convertActionClassParameter(Map<String, Object> row) throws IllegalAccessException, InvocationTargetException {
    final WorkflowActionClassParameter param = new WorkflowActionClassParameter();
    row.put("actionClassId", row.get("workflow_action_class_id"));
    BeanUtils.copyProperties(param, row);
    return param;
  }
View Full Code Here


  public void saveWorkflowActionClassParameter(WorkflowActionClassParameter param) throws DotDataException, AlreadyExistException {

    boolean isNew = true;
    if (UtilMethods.isSet(param.getId())) {
      try {
        final WorkflowActionClassParameter test = this.findActionClassParameter(param.getId());
        if (test != null) {
          isNew = false;
        }
      } catch (final Exception e) {
        Logger.debug(this.getClass(), e.getMessage(), e);
View Full Code Here

      List<WorkflowActionletParameter> params = actionlet.getParameters();
      Map<String, WorkflowActionClassParameter> enteredParams = wapi.findParamsForActionClass(wac);
      List<WorkflowActionClassParameter> newParams = new ArrayList<WorkflowActionClassParameter>();     
      String userIds = null;
      for (WorkflowActionletParameter expectedParam : params) {       
        WorkflowActionClassParameter enteredParam = enteredParams.get(expectedParam.getKey());
        if (enteredParam == null) {
          enteredParam = new WorkflowActionClassParameter();
        }
        enteredParam.setActionClassId(wac.getId());
        enteredParam.setKey(expectedParam.getKey());
        enteredParam.setValue(request.getParameter("acp-" + expectedParam.getKey()));
        newParams.add(enteredParam);
        userIds = enteredParam.getValue();
        //Validate userIds or emails
        String errors = expectedParam.hasError(userIds);
        if(errors != null){
          writeError(response, errors);
          return;
View Full Code Here

    return "This actionlet allows you to add a comment on the workflow task.";
  }

  public void executeAction(WorkflowProcessor processor,Map<String,WorkflowActionClassParameter>  params) throws WorkflowActionFailureException {
    WorkflowActionClassParameter commentParam =  params.get("comment");
    WorkflowComment comment = new WorkflowComment();
    comment.setPostedBy(processor.getUser().getUserId());
    comment.setComment(commentParam.getValue());
    comment.setWorkflowtaskId(processor.getTask().getId());
    try {
      APILocator.getWorkflowAPI().saveComment(comment);
    } catch (DotDataException e) {
      Logger.error(CommentOnWorkflowActionlet.class,e.getMessage(),e);
View Full Code Here

TOP

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

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.