Approval - Get pending registrations count.

API Url

Used to get approval pending transaction count for each category (Project, ProTime, ProJob, Expense and mileage, custom1 etc). It counts max upto 10 records for each of category.

GET
http://localhost:16010/ProMarkREST/rest/Approval/pending-registrations-count

Permissions: user

Query parameters

FieldTypeDescription
approvalGroupoptionalString

Approval group Id. (If empty check for all approval groups)

fromoptionalDate

Start date (registration date) - not used for counting

tooptionalDate

End date (registration date) - not used for counting

Success 200

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data.

    countsObject[]

Collection of transation type and its pending registration count.

      countString

approval pending registrations count for each transaction type (max 10 for each).

      nameString

Registration type name (system text).

      typeString

Registration type (Custom1,ProJect,ProTime,Expense,SelfService,RejectedHigherLevel). Depends on modules installed.

  messageoptionalObject

Object containing response messages.

    codeNumber

Message code.

    textString

Message text.

    typeString

Type of message.

Allowed values:"warning""info"

Success example:

HTTP/1.1 200 OK
{
"response": {
"data": {
"counts": [
{
"type": "ProJect",
"name": "ProJect",
"count": "10+"
},
{
"type": "ProTime",
"name": "ProTime",
"count": "2"
},
{
"type": "ProJob",
"name": "ProJob",
"count": "9"
},
{
"type": "Expense",
"name": "Expense",
"count": ""
},
{
"type": "RejectedHigherLevel",
"name": "RejectedHigherLevel",
"count": "3"
},
{
"type": "Custom1",
"name": "Custom 1",
"count": "10+"
}
]
},
"errorCode": 0,
"errorMessage": ""
}
}