AnsweredAssumed Answered

Why does StartWorkflowWizard restrict nodes to content?

Question asked by jpotts Moderator on Apr 13, 2007
Latest reply on Apr 25, 2007 by gavinc
Folders and their sub-types need to be routeable by advanced workflows. But the StartWorkflowWizard seems to restrict nodes to content and its sub-types (see init method below). Why is this? Shouldn't advanced workflow be able to handle any type of node?

      // add the item the workflow wizard was started on to the list of resources
      String itemToWorkflowId = this.parameters.get("item-to-workflow");
      if (itemToWorkflowId != null && itemToWorkflowId.length() > 0)
      {
         // create the node ref for the item and determine its type
         NodeRef itemToWorkflow = new NodeRef(Repository.getStoreRef(), itemToWorkflowId);
         QName type = this.nodeService.getType(itemToWorkflow);

         if (this.dictionaryService.isSubClass(type, ContentModel.TYPE_CONTENT) ||
             this.dictionaryService.isSubClass(type, ApplicationModel.TYPE_FILELINK))
         {
            this.packageItemsToAdd.add(itemToWorkflow.toString());
         }
      }

Outcomes