Approval - Count pending approval records
API Url
Use it for loading how many approval entities are pending approval per perspective. A perspective can be Employee/Project etc.
GET
http://localhost:16010/ProMarkREST/web/Approval/counter
Permissions: user
Request headers
| Field | Type | Description |
|---|---|---|
Accept-Languageoptional | String | =en-GB Language use for localization. |
X-Clientoptional | String | =Client type. "Portal""Mobile""Admin" |
X-Roleoptional | Number | ProMark role (1: Employee, 2: User). {12} |
X-WebPart-Idoptional | Number | Unique web-part identifier. |
Success 200
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data. |
| counter | Object[] | Array of counters per perspective. |
| count | Integer | How many records are there to approve. |
| name | String | Name of the perspective. |
messageoptional | Object | Object containing response messages. |
| code | Number | Message code. |
| text | String | Message text. |
| type | String | Type of message. "warning""info" |
Success example:
HTTP/1.1 200 OK{"response": {"data": {"counter": [{"name": "employee","count": 100},{"name": "project","count": 5}]},"errorCode": 0,"errorMessage": ""}}