New to Telerik UI for ASP.NET Core? Download free 30-day trial

FilterFieldBuilder

Methods

EditorTemplateHandler(System.Func)

The template which the widget will use to create the field editor.

Parameters

value - System.Func<Object,Object>

The value for EditorTemplate

Example


               @(Html.Kendo().Filter<ProductViewModel>()
                   .Name("filter")
                   .Fields(fields =>
                   {
                        fields.Add(field => field.ProductName)
                              .Label("ProductName")
                              .EditorTemplateHandler(@<text>
                                function editorTemplateHandler(e){
                                    editor template handling code
                                }
                             </text>);
                   })
               )

Operators(System.Action)

The text of the filter operators displayed in the filter.

Parameters

configurator - System.Action<FilterOperatorsSettingsBuilder>

The configurator for the operators setting.

Example


               @(Html.Kendo().Filter<ProductViewModel>()
                   .Name("filter")
                   .Fields(fields =>
                   {
                        fields.Add(product => product.ProductName)
                              .Label("ProductName")
                              .Operators(operators =>
                              {
                                      operators.String(s =>
                                      {
                                           s.Contains("Contains")
                                                   .Startswith("Starts with")
                                                   .Endswith("Ends with")
                                                   .Eq("Equals")
                                                   .Neq("Does not equal")
                                                   .Isnull("Is null")
                                                   .Isnotnull("Is not null")
                                                   .Isnotempty("Is not empty")
                                                   .Isnullorempty("Is null or empty")
                                                   .Isnotnullorempty("Is not null or empty")
                                                   .Contains("Contains")
                                                   .Doesnotcontain("Does not contain");
                                      });
                              });
                   })
               )

DefaultValue(System.Object)

A value which will be initially set as a filter value when an expression item for the specific field is created.

Parameters

value - System.Object

The value for DefaultValue

EditorTemplate(System.String)

The template which the widget will use to create the field editor.

Parameters

value - System.String

The value for EditorTemplate

EditorTemplateId(System.String)

The template which the widget will use to create the field editor.

Parameters

templateId - System.String

The ID of the template element for EditorTemplate

EditorTemplateView(Microsoft.AspNetCore.Html.IHtmlContent)

The template which the widget will use to create the field editor.

Parameters

templateView - Microsoft.AspNetCore.Html.IHtmlContent

The view that contains the template for EditorTemplate

EditorTemplateHandler(System.String)

The template which the widget will use to create the field editor.

Parameters

templateHandler - System.String

The handler that returs the template for EditorTemplate

EditorTemplate(Kendo.Mvc.UI.TemplateBuilder)

The template which the widget will use to create the field editor.

Parameters

template - TemplateBuilder<TModel>

A Template component that configures the editortemplate.

PreviewFormat(System.String)

The format of the value displayed in the preview.

Parameters

value - System.String

The value for PreviewFormat

Label(System.String)

Defines a value which will be visualized instead of the data feild name.

Parameters

value - System.String

The value for Label

In this article
Not finding the help you need?