Platform Explorer / Nuxeo Platform 9.1

Operation Blob.AttachOnDocument

Attach File

Description

Attach the input file to the document given as a parameter. If the xpath points to a blob list then the blob is appended to the list, otherwise the xpath should point to a blob property. If the save parameter is set the document modification will be automatically saved. Return the blob.
Operation id Blob.AttachOnDocument
AliasesBlob.Attach
Category Files
Label Attach File
Requires
Since

Parameters

Name Description Type Required Default value
document document yes  
save boolean no true 
xpath string no file:content 

Signature

Inputs blob, bloblist
Outputs blob, bloblist

Implementation information

Implementation class org.nuxeo.ecm.automation.core.operations.blob.AttachBlob
Contributing component org.nuxeo.ecm.core.automation.coreContrib

JSON definition

{
  "id" : "Blob.AttachOnDocument",
  "aliases" : [ "Blob.Attach" ],
  "label" : "Attach File",
  "category" : "Files",
  "requires" : null,
  "description" : "Attach the input file to the document given as a parameter. If the xpath points to a blob list then the blob is appended to the list, otherwise the xpath should point to a blob property. If the save parameter is set the document modification will be automatically saved. Return the blob.",
  "url" : "Blob.AttachOnDocument",
  "signature" : [ "blob", "blob", "bloblist", "bloblist" ],
  "params" : [ {
    "name" : "document",
    "description" : "",
    "type" : "document",
    "required" : true,
    "widget" : null,
    "order" : 0,
    "values" : [ ]
  }, {
    "name" : "save",
    "description" : "",
    "type" : "boolean",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ "true" ]
  }, {
    "name" : "xpath",
    "description" : "",
    "type" : "string",
    "required" : false,
    "widget" : null,
    "order" : 0,
    "values" : [ "file:content" ]
  } ],
  "widgets" : [ {
    "name" : "xpath",
    "type" : "codearea",
    "labels" : {
      "any" : "XPath"
    },
    "translated" : true,
    "handlingLabels" : false,
    "fields" : [ {
      "fieldName" : "xpath",
      "propertyName" : "xpath"
    } ],
    "properties" : {
      "any" : {
        "height" : "100%",
        "language" : "xpath",
        "width" : "100%"
      }
    }
  } ]
}