ProReport - Create a report specification

API Url

Use it to create a new report specification

POST
http://localhost:16010/ProMarkREST/web/ProReport/reports

Permissions: user

Parameter

FieldTypeDescription
requestObject

Main object containing the request data.

  dataObject

Object containg data to be uploaded.

    reportsObject[]
      attributesoptionalObject[]

Report dynamic attributes.

        descriptionoptionalstring

Attribute description

        idstring

Attribute Id

        typeNumber

attribute type

        valuestring

Attribute Value

      definitionObject

Report definition object.

        descriptionoptionalstring

Report specification description.

        namestring

Report specification name.

        pageNameoptionalstring

Report page name.

        pageTextoptionalstring

Report page text.

        reportNameoptionalstring

Report name.

        reportTextoptionalstring

Report text.

        transactionIdoptionalstring

Report transaction Id.

        typeNumber

Report type.

      groupsObject[]

Report groups.

        calculationstring

Group calculation.

        descriptionoptionalstring

Group description.

        displayboolean

true - group is visible, false - group is not cisible.

        idNumber

Group number.

        textIdstring

System text id.

        texttypestring

System text type.

      idstring

The id of the report.

      layoutObject

Report layout object.

        col1string

Col1 label

        col2string

Col2 label

        columnsObject[]

Report column object.

          formatstring

Column format

          formulastring

Column formula

          idNumber

Column id

          textstring

Column header

        displayDetailsBoolean

TRUE=Show detail lines

        footerCalculationstring

footer calculation

        onlyShowCalcString

Comma separated list of columns that will display data only for the group calculation

        onlyShowDetailsString

Comma separated list of columns that will display data only for the details section

        showDateBoolean

TRUE=Show report execution date

        showLogoBoolean

TRUE=Show logo on page header

        showPageNumberBoolean

TRUE=Show page number on footer

        showSignatureSectionBoolean

TRUE=Show section for signature on report footer

      parentIdString

The parent id of the report.

Request example:

{
"request": {
"data": {
"reports": {
"id": "Absence01-01",
"parentId": "Absence01",
"definition": {
"name": "Absence rules on totals 120 days amttest",
"description": "Shows absence where the total days in the period is 120 or more amttest",
"pageName": "Absence rules on totals 120 days amttest",
"pageText": "Shows absence where the total days in the period is 120 or more amt test",
"reportName": "",
"reportText": "",
"transactionId": "",
"type": 0
},
"groups": [
{
"id": 1,
"description": "Current department ID,Current department description",
"textId": "ttAbsIntv.DeptId,ttAbsIntv.DeptDescription",
"textType": "Other",
"calculation": "SUM",
"display": true
},
{
"id": 2,
"description": "Age",
"textId": "AGE",
"textType": "SortEmp",
"calculation": "SUM",
"display": true
}
],
"layout": {
"columns": [
{
"id": 1,
"text": "No. of dayss",
"format": "202",
"formula": "$"
}
],
"onlyShowCalc": "",
"onlyShowDetails": "",
"displayDetails": true,
"showSignatureSection": false,
"showLogo": true,
"showPageNumber": true,
"showPhDate": true,
"col1": "Period start",
"col2": "Period end",
"footerCalculation": "SUM"
},
"attributes": [
{
"id": "DayLimitMethod",
"description": "Specify day count limit check",
"value": "3",
"readOnly": true,
"type": 4,
"options": [
{
"value": 1,
"description": "<"
},
{
"value": 2,
"description": "="
},
{
"value": 3,
"description": ">"
}
]
},
{
"id": "DayLimit",
"description": "Day count limit",
"value": "121",
"readOnly": true,
"type": 2
},
{
"id": "OnlyOpenEndedPer",
"description": "Only open ended period",
"value": "true",
"readOnly": true,
"type": 1
},
{
"id": "InclOffDays",
"description": "Include off-days",
"value": "true",
"readOnly": true,
"type": 1
},
{
"id": "SepAbsIntv",
"description": "Check individual intervals",
"value": "true",
"readOnly": true,
"type": 1
},
{
"id": "ExtAbsIntvBefore",
"description": "Extend interval back in time",
"value": "true",
"readOnly": true,
"type": 1
},
{
"id": "ExtAbsIntvAfter",
"description": "Extend interval forward in time",
"value": "true",
"readOnly": true,
"type": 1
}
]
}
}
}
}

Success 200

FieldTypeDescription
responseObject

Main object containing the response data.

  messageoptionalObject

Object containing response messages.

    codeNumber

Message code.

    textString

Message text.

    typeString

Type of message.

Allowed values:"warning""info"

Error 4xx

FieldTypeDescription
responseObject

Main object containing the response data.

  dataObject

Object containing the requested data (empty).

  errorCodeNumber

Error code.

  errorMessageString

Error description.