Approval - get holiday transfer registrations
API Url
Used for loading holiday transfer registrations for approval.
http://localhost:16010/ProMarkREST/rest/Approval/holiday-transfers
Permissions: user
Query parameters
| Field | Type | Description |
|---|---|---|
approvalGroupoptional | String | Approval Group ID. If not defined all valid approval groups are taken by default. |
approvalStatusoptional | Number | Approval status to filter data (1: Untreated, 2: Approved, 3: Rejected). In not defined then untreated transactions are returned. 1-3 |
fieldsoptional | String | List of fields to be returned in the collection. Used for limiting amount of data.(Not implemented yet) |
fromoptional | Date | From requested date |
tooptional | Date | To requested date |
Success 200
| Field | Type | Description |
|---|---|---|
| response | Object | Main object containing the response data. |
| data | Object | Object containing the requested data. |
| registrations | Object[] | Collection of holiday transfer registrations |
| approvalStatus | Number | Approval status |
avatarURIoptional | String | URI used for loading employee avatar |
| empId | String | Employee id |
| empName | String | Employee name |
| empNo | String | Employee Number |
| fromAccount | String | From Account identifier |
| fromAccountName | String | From Account name |
| fromFromat | String | From account unit format ("HH:MM", "HH.CC", ".1", ".2" and so on). |
| fromType | Number | Accounts unit type. Possible values 1: hours, 2: days. |
| fromValue | Number | Transferred from value |
| id | String | Transfer registrations identifier (used for internal purpose only) |
| initials | String | Employee initials |
rejectedTextoptional | String | Rejection Text if transaction is rejected |
rejectionCodeoptional | String | Rejection code if transaction is rejected |
| requestedTime | Date | Holiday transfer requested time as ISO-8601 |
| sortEmpNo | String | Employee Number used for sorting |
toAccountoptional | String | Transferred to Account id |
| toAccountName | String | Transferred to Account name |
| toFormat | String | To account unit format ("HH:MM", "HH.CC", ".1", ".2" and so on). |
| toType | Number | Accounts unit type. Possible values 1: hours, 2: days. |
| toValue | Number | Transferred to value |
treatedbyoptional | String | Approved/rejected by user id if approved/rejected |
treatedTimeoptional | Date | Approved/rejected time as date-time ISO-8601 if approved/rejected |
| type | String | Holiday Type |
| year | Number | Holding year |
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": {"registrations": [{"empNo": "HLC4","sortEmpNo": "!!!!!!HLC4","empName": "Henrik Lykke4","initials": "HLC","year": 2018,"fromAccount": "A001","fromAccountName": "Holidays","fromValue": 345600,"fromType": 2,"fromFormat": ".2","toAccountName": "Transfer to next year","toValue": 345600,"toType": 2,"toFormat": ".2","approvalStatus": 1,"requestedTime": "2018-04-26T11:09:14.000","id": "0x0000000000309281"},{"empNo": "HLC4","sortEmpNo": "!!!!!!HLC4","empName": "Henrik Lykke4","initials": "HLC","year": 2018,"fromAccount": "A001","fromAccountName": "Holidays","fromValue": 345600,"fromType": 2,"fromFormat": ".2","toAccount": "S0200","toAccountName": "Hours bank total","toValue": 108000,"toType": 1,"toFormat": "HH:MM","approvalStatus": 1,"requestedTime": "2018-04-26T11:12:39.000","id": "0x0000000000309285"}]},"errorCode": 0,"errorMessage": ""}}