DropDownTreeCheckboxesBuilder
Methods
Enabled(System.Boolean)
Enable/disable rendering of checkboxes in the dropdowntree.
Parameters
enabled - System.Boolean
Whether checkboxes should be rendered.
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .Enabled(true)
                        )
            )
             CheckChildren(System.Boolean)
Enable/disable checking of child checkboxes in the dropdowntree.
Parameters
checkChildren - System.Boolean
Whether checking of parent checkboxes should check child checkboxes.
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .CheckChildren(true)
                        )
            )
             Template(System.String)
Client-side template to be used for rendering the items in the dropdowntree.
Parameters
template - System.String
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .Template("#= data #")
                        )
            )
             TemplateId(System.String)
Id of the element that holds the client-side template to be used for rendering the items in the dropdowntree.
Parameters
templateId - System.String
The ID of the template element for CheckBox Template
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .TemplateId("widgetTemplateId")
                        )
            )
             TemplateView(System.Web.Mvc.MvcHtmlString)
Id of the element that holds the client-side template to be used for rendering the items in the dropdowntree.
Parameters
templateView - System.Web.Mvc.MvcHtmlString
The view that contains CheckBox Template
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .TemplateView(Html.Partial("Template"))
                        )
            )
             TemplateHandler(System.String)
Specifies a JavaScript function name. The value returned by thе function will бе used to render the item checkboxes in the dropdowntree.
Parameters
value - System.String
The name of the JavaScript function that will handle the template evaluation.
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .TemplateHandler("checkboxTemplateHandler")
                        )
            )
             Template(Kendo.Mvc.UI.Fluent.TemplateBuilder)
Defines the template, which renders the checkboxes.
Parameters
template - TemplateBuilder<TModel>
A Template component that configures checkboxes template.
Example
 
             @(Html.Kendo().DropDownTree()
                  .Name("dropDownTree")
                  .Checkboxes(checkboxes => checkboxes
                        .Name("checkedFiles")
                        .CheckChildren(true)
                        .Template(Html.Kendo().Template().AddHtml("<input type='checkbox' name='checkedFiles[${data.item.id}]' value='true' />"))
                   )
             )
             Name(System.String)
The name attribute of the checkbox fields. This will correlate to the name of the action method parameter that the nodes are posted to.
Parameters
name - System.String
The string that will be used in the name attribute.
Example
 
             @( Html.Kendo().DropDownTree()
                        .Name("DropDownTree")
                        .Checkboxes(config => config
                            .Name("checkedNodes")
                        )
            )