Skip to content

Example Template Definition and Resulting Document

The following example template:

{
    "documentId": "e1dd9940-ba26-11e8-9aef-99f092bfb6a5",
    "systemHeader": {
        "templateId": "54d96f610bc006eb84369a8b",
        "systemType": "template",
        "createdWith": "54d96f610bc006eb84369a8b",
        "keyIds": [],
        "summaryName":"TEST TEMPLATE",
        "serverUpdatedDate": "2018-09-17T03:08:52.719Z",
        "serverCreatedDate": "2018-09-17T03:08:52.719Z",
        "versionId": "018b2ff0-ba27-11e8-ad0c-7b1e920f059f",
        "excludeGeneralSearch": false,
        "currentVersion": true,
        "createdDate": "2018-09-17T03:08:52.719Z",
        "createdBy": "5435d78388968497030106d0"
    },
    "summaryNameRule":"TEST DOCUMENT",
    "summaryDescriptionRule":"TEST DOCUMENT DESCRIPTION",
    "components": [
             {
            "componentName": "sc-date-time",
            "label": "Date Submitted",
            "name": "dateSubmitted"
        },
        {
            "componentName": "sc-text-box",
            "label": "Reproducibility",
            "name": "reproducibility"
        },
                {
            "componentName": "sc-drop-down",
            "label": "Severity",
            "name": "issueSeverity",
            "dropDownList": [
                "Trivial",
                "Minor",
                "Major",
                "Critical"
            ]
        }
    ]
}

Creates :

Example: Form with datepicker selected by the user:               alt text

Example: Form with dropdown selected by the user:               alt text

And when the user saves the document the resulting data recorded is:

{
    "documentId": "112cdbc0-ba2c-11e8-b241-7568144d4841",
    "systemHeader": {
        "templateId": "e1dd9940-ba26-11e8-9aef-99f092bfb6a5",
        "systemType": "document",
        "createdWith": "e1dd9940-ba26-11e8-9aef-99f092bfb6a5",
        "keyIds": [],
        "serverUpdatedDate": "2018-09-17T03:45:19.690Z",
        "serverCreatedDate": "2018-09-17T03:45:19.690Z",
        "versionId": "19147aa0-ba2c-11e8-ad0c-7b1e920f059f",
        "excludeGeneralSearch": false,
        "currentVersion": true,
        "createdDate": "2018-09-17T03:45:19.690Z",
        "createdBy": "5435d78388968497030106d0"
    },
    "dateSubmitted": "2018-09-17T03:45:11.974Z",
    "reproducibility": "Always",
    "issueSeverity": "Trivial"
}

When the user opens the above document:               alt text