Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Page Properties
hiddentrue
idrLANGDONE

Product Version
Report NotePublished - language check outstanding
AssigneeMartin

Resources & Remarks

 

  • (warning) Todo: Check name EnaioEvent for scope.api.events.on()
  • (warning) scope.api.http.put - todo: has to be tested and find a good example

Modification History

NameDateProduct VersionAction
Antje08 FEB 20212.4New page properties macro.


...

If you want a format different from JSON, you have to add a third parameter {responseType: 'arraybuffer' | 'blob' | 'json' | 'text'}.

scope.api.http.get

This function works with a mandatory parameter for the url and a second optional one that controls whether to use the core-api endpoints instead of those of the API-WEB (web-api gateway) which is the primary one for the client.

...

Code Block
languagejs
titleExample for post
linenumberstrue
function httppost() {
   var  objectId1 = scope.data['system:objectId'];

   var inst = {
    "processDefinitionKey":"follow-up", 
    "name":"follow-up",
    "businessKey":objectId1,
    "returnVariables":true,
    "variables": [
       {
         "name":"expiryDateTime",
         "value":"2020-10-24T09:57:00"
       },
       {
        "name":"whatAbout",
        "value":"some reminder"
       }, 
       {
        "name":"documentId",
        "value":objectId1
       }
    ]
 };
    
    scope.api.http.post('/bpm/process/instances', inst).then(
    function(result){
        scope.api.util.notifier.info('A follow-up for the following object is created: ' + objectId1, 'Success');
    },
    function(error){
        scope.api.util.notifier.error('A follow-up for the following object could not be created ' + objectId1, 'Error');
        console.log({error});
    }
)

scope.api.dms

This section describes the read access to object information.

scope.api.dms.getObject()

Loads a DMS object from the backend

ParameterTypeDescription
idstringThe id of the DMS object to be fetched.
versionstringoptional: retrieve a specific version of the DMS object.

...