Web API for Workspace Elements: Difference between revisions

From QPR ProcessAnalyzer Wiki
Jump to navigation Jump to search
(Created page with "API for Workspace Elements (a.k.a. UI element API) is used by the Workspace in the Web UI to * move multiple different types of items to another project * delete multiple diff...")
 
 
(15 intermediate revisions by the same user not shown)
Line 1: Line 1:
API for Workspace Elements (a.k.a. UI element API) is used by the Workspace in the Web UI to
Workspace Elements API (a.k.a. UI elements API) is used by the [[QPR_ProcessAnalyzer_Project_Workspace|Workspace]] to
* move multiple different types of items to another project
* move multiple items of different types to other project
* delete multiple different types of items
* delete items (multiple different types can be deleted at the same time)


==UI Elements API==
==Methods==
<pre>
<pre>
POST /api/uielements/setproject/{projectid}
POST /api/uielements/setproject/{targetProjectId}
Body: (for example)
[
  { "id": 1, "type": null },
  { "id": 2, "type": "View" },
  { "id": 3, "type": "Model" },
  { "id": 4, "type": "Datatable" },
  { "id": 5, "type": "Script" }
]
</pre>
</pre>
Supports also models, and the ''moveLinkedDatatables'' query parameter (see PUT api/models/{id}).
Moves projects (type is ''null''), dashboards (type is ''View''), models (type is ''Model''), datatables (type is ''Datatable'') and scripts (type is ''Script'') to another project. Takes as a body an array of objects to be moved, with ''id'' and ''type'' properties. The method is useful when multiple objects are moved between projects.


<pre>
<pre>
DELETE /qprpa/api/uielements
DELETE /qprpa/api/uielements
</pre>
</pre>
Support also models, and the ''deletePermanently'' query parameter (see DELETE api/models/{id}).
Deletes projects (type is ''null''), dashboards (type is ''View''), models (type is ''Model''), datatables (type is ''Datatable'') and scripts (type is ''Script''). Takes as a body an array of objects, with ''id'' and ''type'' properties. The method is useful when multiple objects are deleted.
 
Support the [[Web_API_for_Models|deletePermanently]] query parameter which is applied when deleting models.
 
[[Category: QPR ProcessAnalyzer]]

Latest revision as of 09:26, 29 April 2022

Workspace Elements API (a.k.a. UI elements API) is used by the Workspace to

  • move multiple items of different types to other project
  • delete items (multiple different types can be deleted at the same time)

Methods

POST /api/uielements/setproject/{targetProjectId}
Body: (for example)
[
  { "id": 1, "type": null },
  { "id": 2, "type": "View" },
  { "id": 3, "type": "Model" },
  { "id": 4, "type": "Datatable" },
  { "id": 5, "type": "Script" }
]

Moves projects (type is null), dashboards (type is View), models (type is Model), datatables (type is Datatable) and scripts (type is Script) to another project. Takes as a body an array of objects to be moved, with id and type properties. The method is useful when multiple objects are moved between projects.

DELETE /qprpa/api/uielements

Deletes projects (type is null), dashboards (type is View), models (type is Model), datatables (type is Datatable) and scripts (type is Script). Takes as a body an array of objects, with id and type properties. The method is useful when multiple objects are deleted.

Support the deletePermanently query parameter which is applied when deleting models.