{
    "keyColumn": "section_id",
    "wildsearch": "true",
    "detailHeaderColumnPrefix": "Page Sections: ",
    "handleFile": "true",
    "detailHeaderColumns": [
    "title"
    ],
    "breadCrumbColumn": "title",
    "orderBy": {
        "section_id": "DESC"
    },
    "listColumns": [
    "section_id",
    "title",
    "section_alias",       
    "icon",
    "enabled"
    ],
    "showColumns": [
    "title",
    "section_alias",
    "description",
    "icon",
    "enabled",
    "created_by",
    "created_on"
    ],
    "detailColumns": [        
    "section_id",
    "title",
    "section_alias",
    "description",
    "icon",
    "enabled",
    "created_by",
    "created_on"
    ],   
    "columns": {
        "section_id": {
            "name": "ID",
            "editoptions": {
                "type": "hidden"
            }
        },
        "title": {
            "name": "Title",
            "searchable": "true",
            "sortable": "true",
            "editoptions": {
                "type": "textbox",
                "label": "Title",
                "class": "textbox",
                "hint": "Title of the page section",
                "validations": [
                "required"
                ]
            }
        },
        "section_alias": {
            "name": "Alias",
            "searchable": "true",
            "sortable": "true",
            "editoptions": {
                "type": "textbox",
                "label": "Alias",
                "class": "textbox",
                "validations": [
                "required"
                ]
            }
        },
        "description": {
            "name": "Description",              
            "editoptions": {
                "type": "htmlEditor",
                "editorType" : "ckeditor",
                "label": "Description",
                "class": "textarea"
            }
        },
        "icon": {
            "name": "Icon",
            "editoptions": {
                "type": "file",
                "label": "Icon",
                "class": "file",
                "hint": "Upload file for this section"
            },
            "external": "true",
            "externalOptions": {
                "externalTable": "tbl_files",
                "externalColumn": "file_id",
                "externalShowColumn": "file_id"
            }
        },
        "created_by": {
            "name": "Created By"
        },
        "created_on": {
            "name": "Created On"
        },
        "enabled": {
            "name": "Status",
            "searchable": "true",
            "sortable": "true",
            "listoptions": {
                "type": "button",
                "customaction": "Cmshelper::changePageSectionStatus",
                "enumvalues": {
                    "Y": "Enabled",
                    "N": "Disabled"
                },
                "buttonColors": {
                    "Y": "green",
                    "N": "red"
                }
            },
            "editoptions": {
                "type": "select",
                "source": {
                    "Y": "Enabled",
                    "N": "Disabled"
                },
                 "default":"Y",
                "source_type": "array",
                "label": "status",
                "class": "select",
                "enumvalues": {
                    "Y": "Enabled",
                    "N": "Disabled"
                },
                "validations": [
                "required"
                ]
            }
        }
    },
    "customActions": {
        "beforeAddRecord": "Cmshelper::createdInfo",
        "beforeEditRecord": "Cmshelper::updateInfo"
    },
    "relations": {
        "Categories": {
            "name": "Categories",
            "section": "pageCategories",
            "child_table": "cms_category",
            "parent_join_column": "section_id",
            "child_join_column": "section_id"
        }
     },
    "opertations": [
    "add",
    "view",
    "edit",
    "delete"
    ]
}
    