{
    "keyColumn": "id",
    "wildsearch": "true",
    "detailHeaderColumnPrefix": "Documents: ",
    "handleFile": "true",
    "detailHeaderColumns": [
        "project_id"
    ],
    "breadCrumbColumn": "project_id",
    "orderBy": {
        "id": "DESC"
    },
    "listColumns": [
        "id",
        "project_document_name",
        "project_id",
        "file_id"
    ],
    "showColumns": [
        "id",
        "project_document_name",
        "project_id",
        "file_id"
    ],
    "detailColumns": [
        "id",
        "project_document_name",
        "project_id",
        "file_id"
    ],
    "columns": {
        "id": {
            "name": "ID",
            "editoptions": {
                "type": "hidden"
            }
        },
        "project_document_name": {
            "name": "Document",
            "searchable": "true",
            "sortable": "true",
            "editoptions": {
                "type": "textbox",
                "label": "Name",
                "class": "textbox",
                "hint": "Name of the document",
                "validations": [
                    "required"
                ]
            }
        },
        "file_id": {
            "name": "uploaded document",
            "external": "true",
            "externalOptions": {
                "externalTable": "tbl_files",
                "externalColumn": "file_id",
                "externalShowColumn": "file_id"
            },
            "editoptions": {
                "type": "file",
                "label": "Upload document",
                "class": "file",
                "width": 100,
                "height": 100
            }
        },
        "project_id": {
            "name": "Project",
            "searchable": "true",
            "sortable": "true",
            "external": "true",
            "externalOptions": {
                "externalTable": "tbl_projects",
                "externalColumn": "project_id",
                "externalShowColumn": "project_title"
            }
        }
    },
    "reference": {
        "referenceTable": "tbl_projects",
        "referenceColumn": "project_id",
        "referenceTableForiegnKey": "project_id"
    },
    "customActions": {
        "afterAddRecord": "Cmshelper::updateProjectId"
    },
    "opertations": [
        "add",
        "view",
        "delete"
    ],
    "operationLabel": {
        "addLabel": "Add Document",
        "viewTitle": "View Document Details",
        "deleteTitle": "Delete Document"
    }
}