Grid column filter operators showing No Data Found

2 posts, 0 answers
  1. Will
    Will avatar
    5 posts
    Member since:
    Apr 2008

    Posted 30 Mar Link to this post

    Grid column filter operator list shows No Data Found when I have a column with a ClientTemplate

    columns.Bound(roomIndex => roomIndex.RoomBuilding)
                .Title("Building")
                .EditorTemplateName("BuildingSelect")
                .ClientTemplate("#=RoomBuilding.BuildingName#")

     

    I attempted to fix the problem by adding an operator (below) but my list of filter operators is still empty and I don't understand why the above code doesn't work.

            columns.Bound(roomIndex => roomIndex.RoomBuilding)
                .Title("Building")
                .EditorTemplateName("BuildingSelect")
                .ClientTemplate("#=RoomBuilding.BuildingName#")
                .Filterable(filter => filter
                    .Extra(false)
                    .UI("buildingFilter")
                    .Operators(operators => operators
                        .ForString(str => str.Clear().IsEqualTo("Is equal to"))
                ));

     

    <script type="text/javascript">
        function buildingFilter(element) {
            element.kendoDropDownList({
                dataSource: {
                    transport: {
                        read: "@Url.Action("GetSelectList", "Buildings")"
                    },
                },
                dataTextField: "BuildingName",
                dataValueField: "BuildingId",
                optionLabel: "--Select Value--"
            });
        }
    </script>

     

     

  2. Stefan
    Admin
    Stefan avatar
    1025 posts

    Posted 03 Apr Link to this post

    Hello Will,

    This is not a known issue and I was not able to reproduce it on my end.

    Additionally, please advise why both the ClientTemplate and the EditorTemplateName are used together in the application?

    Also, please have in mind that the built-in filter does not support filtering complex objects, which I can assume is RoomBuilding.

    Could you please send us a runnable example demonstrating the issue, so I can investigate it and provide a suggestion best suited for it.

    Regards,
    Stefan
    Telerik by Progress
    Try our brand new, jQuery-free Angular 2 components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
Back to Top