      {
    "keyColumn": "menu_item_id",
    "wildsearch": "true",
    "handleFile": "true",
    "reference": {
        "referenceTable": "cms_menus",
        "referenceColumn": "menus_id",
        "referenceTableForiegnKey": "menus_id"
    },
    "detailHeaderColumnPrefix": "Menu Item: ",
    "detailHeaderColumns": [
        "title"
    ],
    "orderBy": {
        "menu_item_id": "DESC"
    },   
    "listColumns": [     
 "menu_item_id", 
        "title",      
        "menu_parent_id",
        "menu_item_alias",  
        "reference_type",
        "reference_id",
        "target_type",      
        "target_url",
        "icon",
        "display_order",
        "enabled"
    ],
    "showColumns": [
        "menu_item_id",
        "title",  
        "menu_parent_id",
        "menus_id",   
        "menu_item_alias",  
        "reference_type",
        "reference_id",
        "target_type",      
        "target_url",
        "icon",
        "display_order",
        "enabled"
    ],
    "detailColumns": [
        "menu_item_id",
        "menus_id",   
        "menu_parent_id",
        "title",   
        "menu_item_alias",  
        "reference_type",
        "reference_id",      
        "target_type",      
        "target_url",
        "icon",
        "display_order",
        "enabled"
    ],
    "columns": {
        "menu_item_id": {
            "name": "ID",
            "editoptions": {
                    "type": "hidden"
                }         
        },
 "menus_id": {
            "name": "Menu",    
             "sortable": "true",
            "searchable": "true",
            "external": "true",
            "externalOptions": {
                  "externalTable": "cms_menus",
                  "externalColumn": "menus_id",
                  "externalShowColumn": "title"
                  },
                  "editoptions": {
                        "type": "hidden"
                    }
        },
   "menu_parent_id": {
            "name": "Parent",    
             "sortable": "true",
            "searchable": "true",
            "editoptions": {
                  "type": "select",
                  "source": "Cmshelper::getAllMenuItems",
                  "source_type": "function",
                  "label": "Parent",
                  "class": "select"
              },
            "external": "true",
            "externalOptions": {
                "externalTable": "cms_menu_items",
                "externalColumn": "menu_item_id",
                "externalShowColumn": "title"
            }
   },
    "reference_type": {
        "name": "Association Type",
        "searchable": "true",
        "sortable": "true", 
        "editoptions": {
            "type": "select",
            "source": {
                "Section": "Section",
                "Category": "Category",
                "Content": "Content"
            },
            "source_type": "array",
            "label": "Association Type",
            "class": "select",
            "enumvalues": {
                "Section": "Section",
                "Category": "Category",
                "Content": "Content"
            },
           "validations": [
                "required"
            ]
        }
    },
    "reference_id": {
        "name": "Associated Item Id",
        "searchable": "true",
        "sortable": "true",
        "editoptions": {
            "type": "textbox",
            "label": "Associated Item Id",
            "class": "textbox",
            "validations": [
                "required"
            ]
        }
    },
    "title": {
        "name": "Title",
        "searchable": "true",
        "sortable": "true",
        "editoptions": {
            "type": "textbox",
            "label": "Title",
            "class": "textbox",
            "hint": "Title of the menu item",
            "validations": [
                "required"
            ]
            }
        },
        "menu_item_alias": {
            "name": "Alias",
            "searchable": "true",
            "sortable": "true",
            "editoptions": {
                "type": "textbox",
                "label": "Alias",
                "class": "textbox",
                "hint": "Alias of the menu item",
                "validations": [
                    "required"
                ]
                }
            },
    "target_type": {
        "name": "Target Type",
        "searchable": "true",
        "sortable": "true",
        "editoptions": {
            "type": "select",
            "source": {
                "_self": "_self",
                "_blank": "_blank",
                "_top": "_top"
                
            },
            "source_type": "array",
            "label": "Target Type",
            "class": "select",
            "enumvalues": {
                 "new": "new",
                "_blank": "_blank"
            }
        }
    },
    "target_url": {
        "name": "Target Url",
        "searchable": "true",
        "sortable": "true",
        "editoptions": {
            "type": "textbox",
            "label": "Target Url",
            "class": "textbox",
            "hint": "Target Url of the item",
            "validations": [
                "required"
            ]
            }
    },
     "icon": {
        "name": "Icon",
        "editoptions": {
            "type": "file",
            "label": "Icon",
            "class": "file",
            "hint": "Upload file for this menu item"
        },
        "external": "true",
        "externalOptions": {
            "externalTable": "tbl_files",
            "externalColumn": "file_id",
            "externalShowColumn": "file_id"
        }
    },
   "display_order": {
        "name": "Display Order",
        "searchable": "true",
        "sortable": "true",
        "editoptions": {
            "type": "textbox",
            "label": "Display Order",
            "class": "textbox",
            "hint": "Display Order of the item",
            "validations": [
                "required"
            ]
        }
    },
     "enabled": {
            "name": "Status",
            "searchable": "true",
            "sortable": "true",
            "listoptions": {
                "type": "button",
                "customaction": "Cmshelper::changeMenuItemStatus",
                "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"
            ]
            }
        }
    },
    "opertations": [
        "add",
        "view",
        "edit",
        "delete"
    ]
}