Completed
Last Updated: 23 Jun 2020 13:41 by ADMIN
Release 2020.R1.SP1

Hi, with the latest version of kendo ui on existing hundred grids when I try to filter for a column I get an error like:

This kind of grid worked perfect on previous versions.

Uncaught TypeError: Cannot read property 'length' of undefined

    at init._eachRenderedMenuItem (kendo.all.js:52792)
    at init._setMenuItemsVisibility (kendo.all.js:52747)
    at init._updateMenuItems (kendo.all.js:52742)
    at init.open (kendo.all.js:52609)
    at init.trigger (kendo.all.js:164)
    at init._triggerEvent (kendo.all.js:51935)
    at kendo.all.js:51154
_eachRenderedMenuItem @ kendo.all.js:52792
_setMenuItemsVisibility @ kendo.all.js:52747
_updateMenuItems @ kendo.all.js:52742
open @ kendo.all.js:52609
trigger @ kendo.all.js:164
_triggerEvent @ kendo.all.js:51935
(anonymous) @ kendo.all.js:51154
setTimeout (async)
(anonymous) @ kendo.all.js:51143
each @ jquery-3.4.1.min.js:2
each @ jquery-3.4.1.min.js:2
open @ kendo.all.js:51140
_mouseenter @ kendo.all.js:51465
i @ jquery-3.4.1.min.js:2
handle @ jquery-3.4.1.min.js:2
dispatch @ jquery-3.4.1.min.js:2
v.handle @ jquery-3.4.1.min.js:2

 

 

@(Html.Kendo().Grid<Contract>()
                  .Name(GridId)
                  .DataSource(dataSource => dataSource
                      .Ajax() // Specify that ajax binding is used
                      .PageSize(80)
                      .Events(events => events.Error("common.gridErrorHandler").RequestStart("waitWindow.show").RequestEnd("waitWindow.hide"))
                      .Model(model => model.Id(al => al.ContractId))
                      .Read(read => read.Action("ContractsRead", "Contracts"))
                  )
                  .Events(events => events.Change("onRowClick").DataBound("common.onDataBound"))
                  .ToolBar(toolbar =>
                  {
                      toolbar.Template(@<text>
                          <div style="display: inline-block;">Select a service to manage Cost per Office</div>
                    </text>);
                        })
                              .Columns(columns =>
                              {
                                  columns.Bound(p => p.ContractId).Width(45).Title("Reference #").Hidden(true);
                                  columns.Bound(p => p.Name).Title("Service").Width(100);
                                  columns.Bound(p => p.ExpirationDate).Width(60).Format(RequestHelper.GetDateTimeFormat(Request));
                                  columns.Bound(p => p.BillingCycle.Name).Width(53);
                                  columns.Bound(p => p.Value).Title("Amount").Width(75).Format("$ {0:n5}").HeaderHtmlAttributes(new { style = "text-align: right;" }).HtmlAttributes(new { style = "text-align: right;font-weight: bold;" });
                              })
                              .NoRecords(PageResources.lblGridNoRecords)
                              .Filterable()
                              .Selectable(s => s.Mode(GridSelectionMode.Single))
                              .Scrollable(s => s.Virtual(true).Height("100%"))
                              .Sortable() // Enable sorting
                              .Resizable(resize => resize.Columns(false))
                              .ColumnMenu(p => p.Columns(false)))

 

 

Thank you,

Ion Petcu

Unplanned
Last Updated: 29 Jan 2020 10:55 by Mohammed

Bug Report

When endless scrolling is implemented, manual DataSource operations using the DataSource APIs(query, page, sort, etc.) do not work as expected.  The endless scrolling settings are causing paging issues.  

Reproduction of the problem

  1. Visit this Kendo UI Dojo.
  2. Scroll to 40.
  3. Click the Reset Filter button.

Current Behavior

The first page is only accessible, and when scrolling down the reads continue to occur.

Expected/desired behavior

The endless scrolling settings should not interfere with manual dataSource operations.

Workarounds

  1. Solution when read is called, the Kendo UI Grid will reset to its original state(dojo). 
        kendo.ui.Pager.fn._refreshClick = function (e) {
            e.preventDefault();
            var grid = $("#grid").getKendoGrid();
            grid.dataSource.options.endless = null;
          	grid._endlessPageSize = 20;
          	grid.dataSource.pageSize(20);
        }
  2. Solution which overrides the data(dojo).
        kendo.ui.Pager.fn._refreshClick = function (e) {
            e.preventDefault();
            var grid = $("#grid").getKendoGrid();
            window.restoreScroll = true;
            window.scolledValue = grid.content[0].scrollTop;
            grid.dataSource._data.empty();
            grid.dataSource._pristineData = [];
            grid.dataSource.read();
        }

Environment

  • Kendo UI version: 2020.1.114
Completed
Last Updated: 06 Oct 2020 15:18 by ADMIN
Release 2020.R1.SP1

Bug report

Using server binding does not render the NoRecords message for the Grid

Reproduction of the problem

	@(Html.Kendo().Grid(new List<Product>())    
		.Name("Grid")
		.Columns(columns => {
			columns.Bound(p => p.ProductID).Groupable(false);
			columns.Bound(p => p.ProductName);
			columns.Bound(p => p.UnitPrice);
			columns.Bound(p => p.UnitsInStock);
		})
		.NoRecords("No records found.")
		
		.Pageable()
		.Sortable()
		.Scrollable() 
		.DataSource(d=>d.Server())
		.Filterable()
		.Groupable()
	)

Workarond

A possible workaround is to use local binding by setting the AJAX binding in the DataSource, but keep the initial server binding:

	@(Html.Kendo().Grid(new List<Product>())    
		.Name("Grid")
		.Columns(columns => {
			columns.Bound(p => p.ProductID).Groupable(false);
			columns.Bound(p => p.ProductName);
			columns.Bound(p => p.UnitPrice);
			columns.Bound(p => p.UnitsInStock);
		})
		.NoRecords("No records found.")
		
		.Pageable()
		.Sortable()
		.Scrollable() 
		.DataSource(d=>d.Ajax().ServerOperation(false))
		.Filterable()
		.Groupable()
	)

Environment

  • Kendo UI version: 2017.3.1026
Declined
Last Updated: 04 Feb 2021 17:02 by ADMIN
Created by: Hanh
Comments: 2
Category: Grid
Type: Feature Request
2

I'd like to request to be able to merge cells and column filters with the built-in API for the Kendo UI Grid.

Completed
Last Updated: 13 Jan 2020 09:20 by ADMIN
Release R1 2020
Created by: Ikbum Kim
Comments: 1
Category: Grid
Type: Bug Report
0

When I use lock column, margin is created in the right scroll of the grid. Did you know this problem?
How can I fix this problem? 

 

 

Unplanned
Last Updated: 21 Jan 2020 08:12 by ADMIN

add a grid to a view

open the view with data bound to the grid.

First line of data is not selected.

 

Now i have to program the ondatabound property for a function which belongs to the grid component. Make it configurable for grids which do not need this feature or vice versa.

Completed
Last Updated: 23 Oct 2019 08:34 by ADMIN

Hi,

I'm experiencing a bug with the kendo grid. In my project I have a rather complicated website where a kendo grid is loaded depending an multiple criteria which can be chosen by the user through dropdowns and multiselects. Luckily, I could break it down to a simple test website and the bug still is bugging around ;)

Description: Depending on the criteria chosen, the grid loads different data which reach from zero to thousands of data rows. In my example here, it's either zero or 100 data rows (depending on the dropdown, if there is either "Empty" or "Not empty" selected). The grid loads its data if you press the button ok (by calling the Load action on the server). The result is meant to be limited to paging of 25 rows (no user choice wanted)!

Heres the code for the cshtml site:

<!DOCTYPE html>

<html>
<head>
    <meta name="viewport" content="width=device-width" />
    <title>Index</title>
</head>
<body>
    <div id="content">
        <div>
            @(Html.Kendo().DropDownList()
                            .Name("test_selector")
                            .DataTextField("Display")
                            .DataValueField("Value")
                            .BindTo(new List<DropDownVM>() {
                                            new DropDownVM()                                                                    {
                                                Display = "Empty",
                                                Value = "empty"
                                            },
                                            new DropDownVM()                                                                    {
                                                Display = "Not empty",
                                                Value = "notEmpty"
                                            }
                            })
            )
        </div>
        <div>
            @(Html.Kendo().Grid<MyProject.ViewModels.Test.TestItem>()
                                            .Name("grid_Test")
                                            .Columns(columns =>
                                            {
                                                columns.Bound(x => x.TestId).Title("TestId").Width(75);
                                                columns.Bound(x => x.TestName).Title("TestName").Width(75);
                                            })
                                            .Sortable()
                                            .Pageable()
                                            .DataSource(dataSource => dataSource
                                                .Ajax()
                                                .PageSize(25)
                                                .Read(read => read.Action("Load", "Test").Data("GetSelectorData"))
                                            )
                                            .AutoBind(false) //Do not load Grid data initially
            )
        </div>
        <div>
            @Html.Kendo().Button().Name("Load").Content("Load")
        </div>
    </div>
    <script type="text/javascript">
        $("#Load").on("click", function (e) {
            var grid = $("#grid_Test");
            grid.data("kendoGrid").dataSource.read();
        });

        function GetSelectorData() {
            var selectorData = {
                type: $('#test_selector').data("kendoDropDownList").value()
            }
            return selectorData;
        }
    </script>
</body>
</html>

And the corresponding controller:


public class TestController : BaseController
    {
        public ActionResult Index()
        {
            return View();
        }

        public ActionResult Load([DataSourceRequest] DataSourceRequest request, string type)
        {
            List<TestItem> result = new List<TestItem>();
            if (type == "notEmpty")
            {
                for (int id = 1; id <= 100; id++)
                    result.Add(CreateTestItem(id));
            }

            request.PageSize = 25;
            return Json(result.ToDataSourceResult(request));
        }

        private TestItem CreateTestItem(int id)
        {
            TestItem result = new TestItem()
            {
                TestId = id,
                TestName = "Name" + id
            };
            return result;
        }
    }

Problem: The scenario described above works actually fine as long as the grid gets at least one data row delivered as DataSourceResult (i.e., result.Count > 0 in the Load method of the controller). The request object in the controller's Load method also shows request.PageSize to be configured to 25. Also, if I choose "Empty" from the dropdown and press the Load-button, the request in the controller will show PageSize = 25. But if I switch the selector to "Not empty" afterwards and press Load, the request will show PageSize = 0! This results in the grid not being paged at all and showing all results on a single page (which leads to serious connectivity problems in my productive project as soon as there are several thousands of data rows).

I tried a quick workaround in the Load method of the controller by setting the PageSize manually back to 25 (which is not wanted of course, but would actually work for me at the moment):


public ActionResult Load([DataSourceRequest] DataSourceRequest request, string type)
        {
            List<TestItem> result = new List<TestItem>();
            if (type == "notEmpty")
            {
                for (int id = 1; id <= 100; id++)
                    result.Add(CreateTestItem(id));
            }

            request.PageSize = 25;
            return Json(result.ToDataSourceResult(request));
        }

Unfortunately, this doesn't work either. The paging will be back on again and there will be only 25 data rows loaded in the grid but there is only one single page no matter how many data rows are loaded (see attached screenshot).

Do you know about this? Unfortunately I couldn't find any help for this problem so far.

Greetings!

Completed
Last Updated: 22 Jan 2021 15:39 by ADMIN
Created by: Dave
Comments: 6
Category: Grid
Type: Feature Request
8

Hello, 

 

I think there is a bug with the DataTimeOffset field when used in a Grid. It cannot display correctly and is showing something like /Date(1364927400000)/. I have to retrieve my data from database as DateTimeOffset format and then use a new ViewModel to convert the DateTimeOffset values to DateTime values. This is really annoying.

 

Could you let me know if there is a way a DateTimeOffset field can be supported in the grid? Sometimes you do have to display the time zone info.

 

I hope this can be fixed in a future release.

 

Thanks,

Sam

Completed
Last Updated: 20 Jan 2021 12:07 by ADMIN
When using data attributes on a viewmodel for a grid popup editor:
1. Provide input that causes a validation error message to appear
2. Correct the error with new input, do not blur the final field
3. Click save.
4. Instead of validating the data and submitting, only validation occurs
Completed
Last Updated: 20 Jan 2021 12:27 by ADMIN

When I use a grid, I can enable Filterable and the column shows me when I am filtering it; however if I enable ColumnMenu I have no indication if I am filtering on that column.  We've used a work around to handle this state ourselves, but its ugly and I think this should be part of the core product.

@(Html.Kendo().Grid<ShipmentGrid>()
  .Name("grid")
  .AutoBind(false)
  .Columns(columns =>
  {
  columns.Template(@<text></text>).Width(50).Title("PDFs").ClientTemplate($"<a href='javascript:" + jsPage + $".openDocumentWindow(#=AccountId#, #=OrderNumber#, #=OrderLineId#, #=OrderLineNumber#)'><img src={Url.Content("~/Content/images/pdficon_small.png")} /></a>");
  columns.Bound(m => m.CustomerName).Width(200).Title("Customer").HeaderTemplate("Customer <span style='float:center' class='k-icon k-i-filter'></span>").Filterable(f => f.Multi(true).Search(true)).Sortable(true);
  columns.Bound(m => m.PurchaseOrderNumber).Width(100).Title("PO").HeaderTemplate("PO <span style='float:center' class='k-icon k-i-filter'></span>").Filterable(f => f.Multi(true).Search(true)).Sortable(true);
  })
  .HtmlAttributes(new { style = "font-size:0.85em;" })
  .Filterable()
  .ColumnMenu()
  .Reorderable(reorder => reorder.Columns(true))
  .Resizable(r => r.Columns(true))
  .Scrollable(s => s.Height(340))
  .Pageable(pageable => pageable
  .Refresh(true).ButtonCount(10)
  .PageSizes(new [] { 25, 250, 2500 })
)
  .Sortable(sortable => sortable
  .SortMode(GridSortMode.SingleColumn)
)
  .ClientDetailTemplateId("itemdetail")
  .DataSource(dataSource => dataSource
  .Ajax()
  .Read(read => read.Url("/api/shipments").Data(jsPage + ".getParameters"))
  .PageSize(2500)
  .ServerOperation(false)
  .Events(events => events
  .Error(jsPage + ".GridService.onError")
  .RequestStart(jsPage + ".GridService.onRequestStart")
  .RequestEnd(jsPage + ".GridService.onRequestEnd")
)
)
  .NoRecords()
  .Events(events => events.DataBound(jsPage + ".onDataBound"))
)

Declined
Last Updated: 05 Aug 2019 14:38 by ADMIN
Created by: Christian
Comments: 1
Category: Grid
Type: Feature Request
1

It would be nice, if you can create a build-in property or function to create icon-only buttons/commands in a grid.

Actually it requires some workaround to realize this.

 

This Example create an edit button with the k-button-icontext class, but i want only an k-button-icon button. The destroy button gets the button name as default text.

@(Html.Kendo().Grid<WidgetDashboard.Models.Widget.WidgetData>()
    .Name("adminWidgetGrid")
    .Columns(columns =>
    {
        columns.Bound(p => p.Name).Width(150);
        columns.Bound(p => p.Active).Width(75);
        columns.Command(command => { command.Edit().Text(" "); command.Destroy().Text(""); }).Width(300);
    })
    //.ToolBar(toolbar => toolbar.Create())
    .Editable(editable => editable.Mode(GridEditMode.InLine))
    .Pageable(p => p.Refresh(true))
    .Sortable()
    .Scrollable()
    .Resizable(r => r.Columns(true))
    .HtmlAttributes(new { style = "height:450px; width: 100%" })
    .DataSource(dataSource => dataSource
        .Ajax()
        .PageSize(20)
        //.Events(events => events.Error("error_handler"))
        .Model(model => model.Id(p => p.ID))
        .Create(update => update.Action("Admin_Create", "Dashboard", new { id = Model.DashboardId }))
        .Read(read => read.Action("Admin_Read", "Dashboard", new { id = Model.DashboardId }))
        .Update(update => update.Action("Admin_Update", "Dashboard", new { id = Model.DashboardId }))
        .Destroy(update => update.Action("Admin_Destroy", "Dashboard", new { id = Model.DashboardId }))
    )
)

 

Alternative it would be ok if the correct css class is given when an empty string is specified.

 

Thank you

Christian

Unplanned
Last Updated: 16 Jul 2019 14:48 by ADMIN
Created by: Tech
Comments: 1
Category: Grid
Type: Feature Request
0
At the moment, it requires converting NodaTime objects into System.DateTime ones in order to be correctly handled by the control. This is suboptimal from both performance and maintainability perspectives.
Declined
Last Updated: 14 Jun 2019 14:07 by ADMIN
Created by: Ray
Comments: 1
Category: Grid
Type: Feature Request
0

 

To whom it may concern,

     

       I’m one of your subscribed customers. And I’m writing to seek help in order to realize a filter display I want KendoGrid to show.

 

The following screenshot is the date filter display that KendoGrid has:

Can it be changed to the similar way as the following picture shows?

 

It is also acceptable if the filter can provide 3 different options to easily choose from for users:

  1. Before a certain date that the user can choose from a calendar just like the picture above
  2. After a certain date
  3. Between two dates
  4. In a certain date 

Thanks.

 

Best Regards,

BLACK STREAM

If KendoGrid can not realize the above requirements, can you please provide an alternative plan?
Completed
Last Updated: 19 Jan 2023 13:12 by ADMIN
Created by: Manu
Comments: 1
Category: Grid
Type: Bug Report
1

Hello,

since I updated Telerik UI for ASP.net MVC from version 2019.1.220 to 2019.2.514, the paging part of the grid doesn't display as expected in IE11 with compatibility with IE9  (<meta http-equiv="x-ua-compatible" content="IE=9">)

If I remove the compatibility with IE9, it's ok, but I need it to support older computer.  

version 2019.1.220: 

version 2019.2.514:

 

 Is there a solution to display it correctly?

Thank you very much and best regards.

 

Emmanuel Tharin

Declined
Last Updated: 04 Feb 2021 16:59 by ADMIN

When the page first loads, everything looks okay...

 

But if I show a hidden column...

 

Here's what happens...

The newly shown column is circled in blue. The problem, as you can see, is that the position of the column circled in red should actually be swapped with the column to the left of it. And column #2 (ordering from left to right in the picture, starting from #1) now has an incorrect parent header ("Average") - it should be "Total". And column #4 (the one circled in red), "Constrained", should have a parent header of "Average" (that gray one in column #2).

 

And just FYI, if I show another column (which should also be under "Session Time [minutes]")...

 

...then here's what we get...

(Newly shown column circled in blue.)

 

But, you can see that the data columns are placed correctly. Just not the headers.

Unplanned
Last Updated: 16 Dec 2019 09:16 by ADMIN

We are using the Kendo UI for different components like Grid in our APS.Net MVC application. Currently we are experiencing an issue while exporting the Kendo grid to Excel from mobile (both android and ios). It shows the following warning message. The same works when exporting from a PC without any issue. Could you please help to resolve the issue.

Completed
Last Updated: 17 Jan 2024 12:53 by ADMIN
Release 2024 Q1
Created by: Prashanth
Comments: 0
Category: Grid
Type: Bug Report
1

The issue is present only when a field in the model has been updated. When an invalid value is attempted to be saved, the validation is triggered. Upon pressing the Esc key, the dirty indicator should not be shown.

The expected behavior would be to not show the dirty indicator at all as the value has been returned to the initial one. Furthermore, the indicator is not positioned in the left top corner but immediately above the value.

Steps to replicate:

1. Change the value of any field.

2. Navigate to a field which has validation.

3. Set an invalid value in order to trigger the validation, respectively show a validation message.

4. Press Esc to undo the change.

5. The dirty indicator is shown and mispositioned.

Dojo sample:

https://dojo.telerik.com/iHoRaWIg

Short video demonstration:

https://screencast-o-matic.com/watch/cqhbjKTeK2

Completed
Last Updated: 20 Jan 2021 12:18 by ADMIN
Created by: Vinay
Comments: 1
Category: Grid
Type: Feature Request
0

Hi Viktor,

 

We are looking for functionality of Context Menu on Columns of Kendo MVC grid.

We want various column selection on grid header.

Please help us to get this feature.

Regards

Supriya

 

 

Declined
Last Updated: 12 Apr 2019 12:48 by ADMIN
Created by: David
Comments: 1
Category: Grid
Type: Feature Request
0

Unless I am missing it somehow, I do not think the Grid control ( I was specifically using the MVC Grid control) does not support

 

1. A search feature that searches all rows and columns for the supplied text.  I know you can use the filter at the top of each column to search just that column but looking for ability to search the entire dataset.

 2.  Ability to set the column widths as a percentage of the total space available.  It looks to me like it only allows a specific px setting.

 

These would be good adds.  If either of these are currently possible and I missed it somehow, would appreciate response regarding how to achieve this.

 

Thanks,

David. 

Declined
Last Updated: 14 Feb 2019 07:58 by ADMIN
Created by: Luke
Comments: 1
Category: Grid
Type: Feature Request
0
Are there plans to implement sorting functions into specific columns in a grid for kendo MVC grids? This feature would be very helpful, and seems to already exist in non-MVC versions of kendo grids ("compare" functions).