ProSchedule - Get the total hours of the employees of a plan.
API Url
Used for getting the total hours for the employees of a plan.
http://localhost:16010/ProMarkREST/rest/ProRoster/plans/{id}/total-hours
Permissions: user
Path parameters
| Field | Type | Description |
|---|---|---|
| id | Number | The plan id. |
Query parameters
| Field | Type | Description |
|---|---|---|
empIdsoptional | String | List of employee ids separated by comma. Used to return the data only for certain employees. If list contains employees that are not in the plan, they are ignored. |
fromoptional | Date | The start date of the period inside a plan ( If not provided default is start of the current week). |
groupByoptional | String | date = calculate total hours grouped by date |
tooptional | Date | The end date of the period inside a plan ( If not provided default is end of the current week). |
Success 200
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data. |
| totalHours | Object[] | |
| empId | String | The Id of the employee in plan. |
| totalHours | Number | The total hours of the employee in the period received as query parameters. |
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": {"totalHours": [{"empId": "1314","totalHours": 135000},{"empId": "1313","totalHours": 135000},{"empId": "1316","totalHours": 135000}]},"errorCode": 0,"errorMessage": ""}
Error 4xx
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data (empty). |
| errorCode | Number | Error code. |
| errorMessage | String | Error description. |