Defines the fluent API for configuring TreeListColumn
Definition
Namespace:Kendo.Mvc.UI.Fluent
Assembly:Kendo.Mvc.dll
Type Parameters:
T
Syntax:
public class TreeListColumnBuilder<T> where T : class
Inheritance: objectTreeListColumnBuilder<T>
Inherited Members
Constructors
Initializes a new instance of the TreeListColumnBuilder<T> class.
public TreeListColumnBuilder(TreeListColumn<T> container)
The TreeList column container.
Properties
Gets the container of the TreeList column
protected TreeListColumn<T> Container { get; }
Methods
The configuration of the column commands. If set, the column will display a button for every command. Commands can be custom or built-inThe built-in commands are: edit - Switches the current table row to edit mode. Supports the inline and popup edit modes.; createChild- Adds a new child item to the current table row and switches to edit mode. or destroy - Removes the data item to which the current table row is bound.. Custom commands are supported by specifying the click option.
public TreeListColumnBuilder<T> Command(Action<TreeListColumnCommandFactory<T>> configurator)
The TreeListColumnCommandFactory<T> for the command setting.
Returns:Returns the current instance of TreeListColumnBuilder<T> .
If set to true a draghandle will be rendered and the user could reorder the rows by dragging the row via the drag handle.
public TreeListColumnBuilder<T> Draggable()
Returns the current TreeListColumnBuilder<T> instance.
If set to true a draghandle will be rendered and the user could reorder the rows by dragging the row via the drag handle.
public TreeListColumnBuilder<T> Draggable(bool value)
The value for Draggable
Returns:Returns the current TreeListColumnBuilder<T> instance.
The JavaScript function that is executed when the cell or row is about to be opened for editing. The returned result will determine whether an editor for the column will be created.
public TreeListColumnBuilder<T> Editable(Func<object, object> handler)
The handler code wrapped in a text tag.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The JavaScript function that is executed when the cell or row is about to be opened for editing. The returned result will determine whether an editor for the column will be created.
public TreeListColumnBuilder<T> Editable(string handler)
The name of the JavaScript function that will be evaluated.
Returns:Returns the current TreeListColumnBuilder<T> instance.
Provides a way to specify a custom editing UI for the column. Use the container parameter to create the editing UI.
public TreeListColumnBuilder<T> Editor(string value)
The value that configures the editor.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which the component will use to create the field editor.
public TreeListColumnBuilder<T> EditorTemplateComponentName(string templateName)
Editor template name.
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true, the column value will be HTML-encoded before it is displayed. If set to false, the column value will be displayed as is. By default, the column value is HTML-encoded.
public TreeListColumnBuilder<T> Encoded(bool value)
The value for Encoded
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true, the column will show the icons that are used for expanding and collapsing child rows. By default, the first column of the TreeList is expandable.
public TreeListColumnBuilder<T> Expandable()
Returns the current TreeListColumnBuilder<T> instance.
If set to true, the column will show the icons that are used for expanding and collapsing child rows. By default, the first column of the TreeList is expandable.
public TreeListColumnBuilder<T> Expandable(bool value)
The value for Expandable
Returns:Returns the current TreeListColumnBuilder<T> instance.
The field to which the column is bound. The value of this field is displayed by the column during data binding.
public TreeListColumnBuilder<T> Field(string value)
The value for Field
Returns:Returns the current TreeListColumnBuilder<T> instance.
The field to which the column is bound. The value of this field is displayed by the column during data binding. The field name should be a valid Javascript identifier and should contain no spaces, no special characters, and the first character should be a letter.
public TreeListColumnBuilder<T> Field<TValue>(Expression<Func<T, TValue>> expression)
The expression that specifies the field, based on the bound model.
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true and if filtering is enabled, a filter menu will be displayed for this column. If set to false, the filter menu will not be displayed. By default, a filter menu is displayed for all columns when filtering is enabled through the filterable option. Can be set to a JavaScript object which represents the filter menu configuration.
public TreeListColumnBuilder<T> Filterable(Action<TreeListColumnFilterableSettingsBuilder<T>> configurator)
The configurator for the filterable setting.
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true and if filtering is enabled, a filter menu will be displayed for this column. If set to false, the filter menu will not be displayed. By default, a filter menu is displayed for all columns when filtering is enabled through the filterable option. Can be set to a JavaScript object which represents the filter menu configuration.
public TreeListColumnBuilder<T> Filterable(bool enabled)
Enables or disables the filterable option.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the footer table cell for the column.The following fields can be used in the template: average - The value of the average aggregate (if specified).; count - The value of the count aggregate (if specified).; max - The value of the max aggregate (if specified).; min - The value of the min aggregate (if specified). or sum - The value of the sum aggregate (if specified)..
public TreeListColumnBuilder<T> FooterTemplate(string value)
The value for FooterTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the footer table cell for the column.The following fields can be used in the template: average - The value of the average aggregate (if specified).; count - The value of the count aggregate (if specified).; max - The value of the max aggregate (if specified).; min - The value of the min aggregate (if specified). or sum - The value of the sum aggregate (if specified)..
public TreeListColumnBuilder<T> FooterTemplate<TModel>(TemplateBuilder<TModel> template)
A Template component that configures the footertemplate.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the footer table cell for the column.The following fields can be used in the template: average - The value of the average aggregate (if specified).; count - The value of the count aggregate (if specified).; max - The value of the max aggregate (if specified).; min - The value of the min aggregate (if specified). or sum - The value of the sum aggregate (if specified)..
public TreeListColumnBuilder<T> FooterTemplateHandler(string templateHandler)
The handler that returs the template for FooterTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the footer table cell for the column.The following fields can be used in the template: average - The value of the average aggregate (if specified).; count - The value of the count aggregate (if specified).; max - The value of the max aggregate (if specified).; min - The value of the min aggregate (if specified). or sum - The value of the sum aggregate (if specified)..
public TreeListColumnBuilder<T> FooterTemplateId(string templateId)
The ID of the template element for FooterTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the footer table cell for the column.The following fields can be used in the template: average - The value of the average aggregate (if specified).; count - The value of the count aggregate (if specified).; max - The value of the max aggregate (if specified).; min - The value of the min aggregate (if specified). or sum - The value of the sum aggregate (if specified)..
public TreeListColumnBuilder<T> FooterTemplateView(IHtmlContent templateView)
The view that contains the template for FooterTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The format that is applied to the value before it is displayed. Takes the {0:format} form where format is a standard number format, custom number format, standard date format or a custom date format.
public TreeListColumnBuilder<T> Format(string value)
The value for Format
Returns:Returns the current TreeListColumnBuilder<T> instance.
The HTML attributes of the table header cell (<th>) that is rendered for the column.
public TreeListColumnBuilder<T> HeaderAttributes(IDictionary<string, object> value)
The value for HeaderAttributes
Returns:Returns the current TreeListColumnBuilder<T> instance.
The HTML attributes of the table header cell (<th>) that is rendered for the column.
public TreeListColumnBuilder<T> HeaderAttributes(object value)
The value for HeaderAttributes
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column header content. By default, the value of the title column option is displayed in the column header cell.
public TreeListColumnBuilder<T> HeaderTemplate(string value)
The value for HeaderTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column header content. By default, the value of the title column option is displayed in the column header cell.
public TreeListColumnBuilder<T> HeaderTemplate<TModel>(TemplateBuilder<TModel> template)
A Template component that configures the headertemplate.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column header content. By default, the value of the title column option is displayed in the column header cell.
public TreeListColumnBuilder<T> HeaderTemplateHandler(string templateHandler)
The handler that returs the template for HeaderTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column header content. By default, the value of the title column option is displayed in the column header cell.
public TreeListColumnBuilder<T> HeaderTemplateId(string templateId)
The ID of the template element for HeaderTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column header content. By default, the value of the title column option is displayed in the column header cell.
public TreeListColumnBuilder<T> HeaderTemplateView(IHtmlContent templateView)
The view that contains the template for HeaderTemplate
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will not display the column. By default, all columns are displayed.
public TreeListColumnBuilder<T> Hidden()
Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will not display the column. By default, all columns are displayed.
public TreeListColumnBuilder<T> Hidden(bool value)
The value for Hidden
Returns:Returns the current TreeListColumnBuilder<T> instance.
The HTML attributes of the table cell (<td>) that is rendered for the column.
public TreeListColumnBuilder<T> HtmlAttributes(IDictionary<string, object> value)
The value for HtmlAttributes
Returns:Returns the current TreeListColumnBuilder<T> instance.
The HTML attributes of the table cell (<td>) that is rendered for the column.
public TreeListColumnBuilder<T> HtmlAttributes(object value)
The value for HtmlAttributes
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will select all child rows upon parent row selection when checkbox selection is used.
public TreeListColumnBuilder<T> IncludeChildren()
Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will select all child rows upon parent row selection when checkbox selection is used.
public TreeListColumnBuilder<T> IncludeChildren(bool value)
The value for IncludeChildren
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to false, the column will remain in that side of the TreeList where its own locked configuration placed it.
public TreeListColumnBuilder<T> Lockable(bool value)
The value for Lockable
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will display the column as locked (frozen).
public TreeListColumnBuilder<T> Locked()
Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will display the column as locked (frozen).
public TreeListColumnBuilder<T> Locked(bool value)
The value for Locked
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true, the TreeList will display the column in the column menu. By default, the column menu includes all data-bound columns, that is, the ones with a set field option.
public TreeListColumnBuilder<T> Menu(bool value)
The value for Menu
Returns:Returns the current TreeListColumnBuilder<T> instance.
The pixel screen width below which the column will be hidden. The setting takes precedence over the hidden setting and the two cannot not be used at the same time.
public TreeListColumnBuilder<T> MinScreenWidth(double value)
The value for MinScreenWidth
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true the treelist will render a select column with checkboxes in each cell, thus enabling multi-row selection. The header checkbox allows users to select/deselect all the rows on the current page.
public TreeListColumnBuilder<T> Selectable()
Returns the current TreeListColumnBuilder<T> instance.
If set to true the treelist will render a select column with checkboxes in each cell, thus enabling multi-row selection. The header checkbox allows users to select/deselect all the rows on the current page.
public TreeListColumnBuilder<T> Selectable(bool value)
The value for Selectable
Returns:Returns the current TreeListColumnBuilder<T> instance.
If set to true and sorting is enabled, the user can click the column header and sort the TreeList by the column field. If set to false, sorting will be disabled for this column. By default, all columns are sortable if sorting is enabled though the sortable option.
public TreeListColumnBuilder<T> Sortable(Action<TreeListColumnSortableSettingsBuilder<T>> configurator)
The TreeListColumnSortableSettingsBuilder<T> for the sortable setting.
Returns:Returns the current instance of TreeListColumnBuilder<T> .
If set to true and sorting is enabled, the user can click the column header and sort the TreeList by the column field. If set to false, sorting will be disabled for this column. By default, all columns are sortable if sorting is enabled though the sortable option.
public TreeListColumnBuilder<T> Sortable(bool enabled)
Enables or disables the sortable option.
Returns:Returns the current instance of TreeListColumnSortableSettingsBuilder<T> .
The template which renders the column content. The TreeList renders table rows (<tr>) which represent the data source items. Each table row consists of table cells (<td>) which represent the TreeList columns. By default, the HTML-encoded value of the field is displayed in the column.
public TreeListColumnBuilder<T> Template(string value)
The value for Template
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column content. The TreeList renders table rows (<tr>) which represent the data source items. Each table row consists of table cells (<td>) which represent the TreeList columns. By default, the HTML-encoded value of the field is displayed in the column.
public TreeListColumnBuilder<T> Template<TModel>(TemplateBuilder<TModel> template)
A Template component that configures the template.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column content. The TreeList renders table rows (<tr>) which represent the data source items. Each table row consists of table cells (<td>) which represent the TreeList columns. By default, the HTML-encoded value of the field is displayed in the column.
public TreeListColumnBuilder<T> TemplateHandler(string templateHandler)
The handler that returs the template for Template
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column content. The TreeList renders table rows (<tr>) which represent the data source items. Each table row consists of table cells (<td>) which represent the TreeList columns. By default, the HTML-encoded value of the field is displayed in the column.
public TreeListColumnBuilder<T> TemplateId(string templateId)
The ID of the template element for Template
Returns:Returns the current TreeListColumnBuilder<T> instance.
The template which renders the column content. The TreeList renders table rows (<tr>) which represent the data source items. Each table row consists of table cells (<td>) which represent the TreeList columns. By default, the HTML-encoded value of the field is displayed in the column.
public TreeListColumnBuilder<T> TemplateView(IHtmlContent templateView)
The view that contains the template for Template
Returns:Returns the current TreeListColumnBuilder<T> instance.
The text that is displayed in the column header cell. If not set, the TreeList uses field.
public TreeListColumnBuilder<T> Title(string value)
The value for Title
Returns:Returns the current TreeListColumnBuilder<T> instance.
The width of the column. Numeric values are treated as pixels.
public TreeListColumnBuilder<T> Width(int value)
The value that configures the width.
Returns:Returns the current TreeListColumnBuilder<T> instance.
The width of the column. Numeric values are treated as pixels.
public TreeListColumnBuilder<T> Width(string value)
The value for Width
Returns:Returns the current TreeListColumnBuilder<T> instance.