{
    "keyColumn": "content_id",
    "wildsearch": "true",
    "detailHeaderColumnPrefix": "Content: ",
    "reference": {
        "referenceTable": " cms_category",
        "referenceColumn": "category_id",
        "referenceTableForiegnKey": "category_id"
    },
   "handleFile": "true",
    "detailHeaderColumns": [
        "title"
    ],
    "breadCrumbColumn": "title",
    "orderBy": {
        "content_id": "DESC"
    },
    "listColumns": [
        "content_id",
        "title",       
        "content_alias",
        "summary",        
        "content_type",
        "icon",
        "enabled"       
    ],
    "showColumns": [
        "content_id",
        "section_id",
        "category_id",
        "title",
        "content_alias",
        "summary",
        "description",
        "content_type",
        "icon",
        "enabled",
        "created_by",
        "created_on",
        "last_updated_by"
    ],
    "detailColumns": [        
        "content_id",
        "section_id",
        "category_id",
        "title",
        "content_alias",
        "summary",
        "description",
        "content_type",
        "icon",
        "enabled",
        "created_by",
        "created_on",
        "last_updated_by"
    ],     
 
    "columns": {
         "content_id": {
                "name": "ID",
                "editoptions": {
                    "type": "hidden"
                }
            },
            "category_id": {
                "name": "Category",
                "external": "true",   
                "searchable": "true",
                "sortable": "true",          
                "editoptions": {
                        "type": "hidden"
                    },
                "externalOptions": {
                    "externalTable": "cms_category",
                    "externalColumn": "category_id",
                    "externalShowColumn": "title"
                    }
            },
            "section_id": {
                "name": "Section",
                "searchable": "true",
                "sortable": "true",
                "external": "true",
                "externalOptions": {
                    "externalTable": "cms_page_sections",
                    "externalColumn": "section_id",
                    "externalShowColumn": "title"
                    },
                "editoptions": {
                    "type": "hidden"
                }
            },    
            "created_by": {
                "name": "Created"                
            },    
            "created_on": {
                "name": "Created Time"
            },    
            "last_updated_by": {
                "name": "Last Updated By"
            },    
            "content_type": {
                "name": "Content Type",
                "searchable": "true",
                "sortable": "true",
                "editoptions": {
                    "type": "select",
                    "default":"Text",
                    "source": {
                        "Image": "Image",
                        "Text": "Text",
                        "Both": "Both"
                    },
                    "source_type": "array",
                    "label": "Content Type",
                    "class": "select",
                    "enumvalues": {
                        "Image": "Image",
                        "Text": "Text",
                        "Both": "Both"
                    },
                   "validations": [
                        "required"
                    ]
                }
            },
            "title": {
            "name": "Title",
            "searchable": "true",
            "sortable": "true",
            "editoptions": {
                "type": "textbox",
                "label": "Title",
                "class": "textbox",
                "hint": "Title of the page content",
                "validations": [
                    "required"
                ]
                }
            },
            "content_alias": {
                "name": "Alias",
                "searchable": "true",
                "sortable": "true",
                "editoptions": {
                    "type": "textbox",
                    "label": "Alias",
                    "class": "textbox",
                    "validations": [
                        "required"
                    ]
                }
            },
            "summary": {
                "name": "Summary",
                "searchable": "true",
                "sortable": "true",
                "editoptions": {
                    "type": "textarea",
                    "label": "Summary",
                    "class": "textarea",
                    "hint": "Short Summary for the content"
                }
            },
            "description": {
                "name": "Description",
                "searchable": "true",
                "sortable": "true",
                "editoptions": {
                    "type": "htmlEditor",
                    "label": "Description",
                    "class": "textarea",
                    "hint": "Description for the content"
                }
            },
            "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"
            }
            },           
            "enabled": {
                "name": "Status",
                "searchable": "true",
                "sortable": "true",
                "listoptions": {
                    "type": "button",
                    "customaction": "Cmshelper::changeContentStatus",
                    "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": {
        "afterAddRecord":"Cmshelper::updateContentSection",
        "afterEditRecord":"Cmshelper::updateContentSection",
        "beforeAddRecord": "Cmshelper::createdInfo",
        "beforeEditRecord": "Cmshelper::updateInfo"
    },
        "opertations": [
            "add",
            "view",
            "edit",
            "delete"
        ]
    }
 
        