ProRoster - Edit a plan
API Url
Use it for changing a plan.
http://localhost:16010/ProMarkREST/rest/ProRoster/plans
Permissions: user
Query parameters
| Field | Type | Description |
|---|---|---|
| force | Boolean | True = Will ignore the warning. False = In case you haven't put yourself in the user restrictions or if you are not an admin, the routine ends with an error. If there aren't any user restrictions, you will not get an error. |
Parameter
| Field | Type | Description |
|---|---|---|
| request | Object | Main object containing the request data. |
| data | Object | Object containg data to be uploaded. |
| plans | Object[] | |
approvalGroupsoptional | Object[] | Object array of approval group details. |
| id | String | Id of the approval group. |
departmentsoptional | Object[] | Object array of department details. |
| id | String | Id of the department. |
| description | String | Description of the plan. |
endDateoptional | Date | End date of the plan. Optional if plan never expires. |
groupsoptional | Object[] | Object array of group details. |
| id | String | Id of the group. |
| id | Number | The plan unique identifier. |
| neverExpires | Boolean | Boolean if the plan is endless or not. |
planIdoptional | String | Plan ID (needs to be unique also). |
| startDate | Date | Start date of the plan. |
usersoptional | Object[] | Object array of user rights details. |
| accesMode | Number | 0 = user has read-only rights, 1 = user has read-write rights. |
| id | String | Id of the user. |
| isAdmin | Boolean | True = the user is Plan administrator. |
| version | Number | Version number of the plan. |
Request example:
{"request": {"data": {"plans": [{"id": 11234555,"planId": "UUT","description": "SAP-HR-Department 15 Pan","startDate": "2015-10-01","endDate": "2018-07-27","neverExpires": true,"departments": [{"id": "BAYPROJ"}],"groups": [{"id": "2"}],"approvalGroups": [{"id": "01"}],"users": [{"id": "AAM","isAdmin": true,"accessMode": 1}]}},}}
Success 200
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
messageoptional | Object | Object containing response messages. |
| code | Number | Message code. |
| text | String | Message text. |
| type | String | Type of message. "warning""info" |
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. |