Task

Task is a complex relationship between a person, some generic method definition and a node (the task is done of shall be done by the person over the node using related Method).

task_list_types

returns list of acceptable task types for the specified node

QUERY_FUNCTION task_list_types(id: INTEGER): LIST OF STRING

Parameter:
id assigning node instance id

task_create

assigns some value(s) to node in context of specified task definition according to input

To call the query logged in user shall be associated with a person granted with editor privileges in target node (EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION task_create(subj: v_task): v_task

Parameter:
subj input for the assignment, see v_task
it is required to set the following values:
  • subject.subject - assigning node instance id
  • subject.assigned - assigning person instance id
  • subject.action - assigned method instance id
some attributes of the input are ignored, like the following:
  • subject.item.instance_id - generated
  • subject.item.cancelled - set to FALSE
  • subject.item.creator - set to logged in user
  • subject.item.last_changed - set to date/time of the call
  • subject.item.last_editor - set to logged in user
  • subject.item.comments - unset
  • subject.item.events - is populated with a creation event

Returns actual attributes of the newly assigned task (see v_task)


task_get

gets data of a task assignment specified by its instance id

To call the query logged in user shall be associated with a person granted with reader privileges over the target node (READER_TYPE, EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION task_get(id: INTEGER): v_task

Parameter:
id id of the assigned task instance

Returns actual data of the required assigned task (see v_task)


task_list

lists data of assignments specified by list of their instance id-s. Normally source of the the list is v_node returned by node_get

To call the query logged in user shall be associated with a person granted with reader privileges in target node (READER_TYPE, EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION task_list(ids: LIST OF INTEGER): LIST OF v_task

Parameter:
ids list of interesting task instance id-s

Returns list of actual data of the required tasks (see v_task)


task_select

task search is not implemented in current realize
QUERY_FUNCTION task_select(
      node,
      person,
      method,
      approval,
      creator           : INTEGER;
      to_start_less,
      to_start_greater,
      to_finish_less,
      to_finish_greater,
      approval_type,
      method_type,
      task_type         : STRING)  :  LIST OF v_task
Parameters:
node (optional) instance id of parent node
person (optional) instance id of simdm person who introduced the assignments
method (optional) instance id of method definition assigned to the task
approval (optional) instance id of approval assigned to the task
creator (optional) instance id of person who introduced the task
...

Returns list of found assigned properties (see v_task)


task_update

updates data of task. The assignment is specified by its instance id

To call the query logged in user shall be associated with a person granted with editor privileges in target node (EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION task_update(subject: v_task): v_task

Parameter:
subject updated data of the assignment to be updated in model (see v_task)
Target instance specified by subject.item.instance_id

The following attributes are ignored:

  • subject.approvals - read only list
  • subject.subject - is leaved in parent node
  • subject.item.introduced - is leaved as before
  • subject.item.creator - is leaved as before
  • subject.item.last_changed - set to current date/time
  • subject.item.last_editor - set to calling user
  • subject.item.comments - is leaved as before
  • subject.item.event - is added with update event

Returns actual data of the updated task (see v_task)


task_delete

removes assignment specified by its instance id from the current state of pbs

To call the query logged in user shall be associated with a person granted with editor privileges in target node (EDITOR_TYPE, ADMIN_TYPE for the person or group where the person is registered)

QUERY_FUNCTION task_delete(id: INTEGER): BOOLEAN

Parameter:
id instance id of the assignment to be removed

Returns TRUE

Back to Home page