Tasks option

Build 1501 on 14/Nov/2017  This topic last edited on: 29/Oct/2012, at 16:11

Tasks option outputs in the XML a description of all the scheduled tasks (workflow execution and publishing) that are pending for the object.

For example, if the 'video' object with id 41314 has both a scheduled publish and a workflow execution pending, executing ../do.ashx?cmd=objsnav&ids=41314&options=tasks&max=6 produces:

  <video id="obj41314"  . . .>

    . . . 

    <nav:tasks handle="1">

      <nav:task 

        id="914" userId="4" priority="0" type="Publish" objectId="1595" 

        profile="" numRetries="0" cmd="rids:41274;aids:41314;">

        <user idref="obj4">

          <nav:refObject idref="obj4">

            <user id="obj4" name="Administrator" . . .  />

          </nav:refObject>

        </user>

        <object idref="obj1595">

          <nav:refObject idref="obj1595">

            <pubDest id="obj1595" name="Default" path="/Default" . . .  />

          </nav:refObject>

        </object>

      </nav:task>

      <nav:task 

        id="912" userId="4" time="2011-11-01T20:55:00.000Z" priority="0" type="ObjsWF" objectId="5783" 

        profile="" numRetries="0" ids="41314 41274">

        <pars>

          <add key="pinco" value="pallino" xmlns="" />

        </pars>

        <user idref="obj4">

          <nav:refObject idref="obj4">

            <user id="obj4" name="Administrator" . . .  />

          </nav:refObject>

        </user>

        <object idref="obj5783">

          <nav:refObject idref="obj5783">

            <config nav:objectType="config" id="obj5783" name="wf_CreateVideoPreview" />

          </nav:refObject>

        </object>

      </nav:task>

    </nav:tasks>

    . . . 

  </video>

The tasks are listed in increasing order of scheduled time, with those with no scheduled time (i.e. to be executed immediately) first, and the tasks more in the future last.

Note how the user the complete XML of the user that scheduled the task and of the object associated with the task are expended within each task ('user' and 'object' element respectively). For publishing commands the associated object is the publishing destination, for workflow execution is the global configuration object containing the workflow.

See also

TaskLog option