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.
The first page is only accessible, and when scrolling down the reads continue to occur.
The endless scrolling settings should not interfere with manual dataSource operations.
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);
}
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();
}
Support for NullDisplayText property of the DisplayFormat metadata attribute.
I use getOptions() and setOptions() to persist the state of the ajax bound grid that I have.
My toolbar is not a server one, it is this:
.ToolBar(toolbar =>toolbar.Create().HtmlAttributes(new { @class ="k-primary"}))
When I call the setOptions() method, it removes the Add button from the grid header.
It would be great if we could use the built in column filtering on columns containing arrays.
Or at the very least have a workaround (which I have not been able to find on the site).
I understand that the current implementation relies on the data being flat, but support for the following situation would be great:
- Grid cell is bound to an array and a template is used to display character delimited data (ie. One, two, three, four).
- Column filtering will display multi select options for the data.
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.
Currently, the autoFitColumn() method shouldn't be used to resize all columns in a large grid, as noted here: https://docs.telerik.com/kendo-ui/api/javascript/ui/grid/methods/autofitcolumn
Could this performance be improved by deferring the width calculation? So a 10 column grid could be completely autoFit with 1 calculation instead of 10.
Could an .AutoFit(true) method be added to the GridColumnBuilder's Fluent Api?
This would allow me to build columns such as:
.Columns(column => column.Bound(model => model.Value).AutoFit())
This should defer the autofit calculations so that they can be run once for all auto-fitted columns, rather than re-calculating for every column.
In other words, this should NOT simply call autoFitColumn() as it is currently implemented.
Implement stacking columns on smaller screens, e.g., https://docs.telerik.com/devtools/aspnet-ajax/knowledge-base/grid-stack-responsive-columns-on-small-screens
Implement an option to control the columns width in scenarios that involve resizing the browser window.
Currently, if you specify the width of all the columns, on resizing the browser window the columns automatically resize proportionally. A column property MaxWidth would be nice to have, since it would prevent columns from resizing beyond a specified width value.
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.
Aligning numeric values in grids is common place and best practise. Kendo Grid does not provide any neat functionality for this, especially in MVC where the model is strongly typed. Where a MVC grid is bound to a model, the Razor Wrapper would work better if it right aligned columns if for example type int (or other numeric types which are better to be right aligned). Where this needs not to be the case a data annotation would suit.
eg.
public class MyModel
{
[AlignRight(false)]
public int ProductID {get; set;}
public int Age {get; set; } // aligned right by default in Kendo Grid because of int type
}
In the above case ProductID would be left aligned, and Age would be right (which could be the default for all integer types)
With this functionality the razor implementation could also provide an align property to override align functionality. An AutoAlign property could provide this functionalityto auto detect from model or not (and also allow this functionality as being off to provide backwards compatibility)
@(Html.Kendo().Grid<MyModel>()
.Name("grid")
.AutoAlign(false)
.Columns(columns =>
{
columns.Bound(c => c.ProductID).AlignRight(false)
columns.Bound(c => c.Age).AlignRight(True)
})
A recent update has revealed some strange behaviour in some (not all) grids. In the attached screenshot, the javascript for the two buttons is on display inside the toolbar. If I move them out of the toolbar, the script no longer displays.
As a workaround, I have added this to CSS:
script {
display: none !important;
}
In the Kendo UI for jQuery Grid, fields that are not editable are displayed as text (no input elements) in the Grid's popup editor. The MVC Grid displays all fields that are present in the view model it is bound to in its popup editor.
Implement an option to configure the editable fields, so that the behavior of the MVC Grid matches that of its Kendo UI counterpart.