kendo-grid

Kendo UI Grid returns JSON to browser (using MVC)

為{幸葍}努か 提交于 2019-12-02 11:36:46
I've recently purchased a Kendo subscription, I'm having trouble getting an AJAX bound grid to operate as expected, hoping someone here can help. I have followed the Kendo docs tutorial @ http://docs.kendoui.com/getting-started/using-kendo-with/aspnet-mvc/helpers/grid/ajax-binding and could get the AJAX binding working nicely. I've tried to now implement it into an existing MVC solution, and whenever I click the New or Edit command button, I get a string of JSON returned to the browser . Similiar to issue ( JSON data to KENDO UI Grid ASP.NET MVC 4 ) But the answer in that problem didn't work

Custom sort function kendo grid

余生颓废 提交于 2019-12-02 10:23:37
Can anyone please let me know how can we write our own function in javascript for sorting in kendo grid. And do we need to write two functions for asc and desc? Any help.. greatly appreciated! You can do it and you don't have to write two different function for ascending and descending since the only thing that you need to do is providing a compare function for the column field that you need a special algorithm. Example: Lets assume that we want to sort a grid by name (a string ) and this is our data: data : [ { id : 1, name : "john" }, { id : 2, name : "jane" }, { id : 3, name : "Jane" }, {

How to filter whole datasource on a kendo grid with virtualized remote data

倾然丶 夕夏残阳落幕 提交于 2019-12-02 10:08:31
问题 At work, we are having performances issues with a kendo grid that has a lot of row. We are thinking about using virtualization of remote data as a solution like you can see on the link below. https://demos.telerik.com/kendo-ui/grid/virtualization-remote-data The problem we have with that solution is that we allow filters on a lots of our columns and only the rows that are defined in the pagesize of the grid are displayed. In the link below, you can easily see what I mean by that. I added the

Kendo UI Window overlay opacity

有些话、适合烂在心里 提交于 2019-12-02 09:13:10
How can I set overlay opacity with CSS. I tried .k-overlay { opacity:0.9; } but it wont work. Can anyone help me? here I provide a simple demo .k-widget would be a too broad selection. You can set the opacity for that very window once the window will be shown: <script> function onOpen() { setTimeout(function(){ $("#dialog").parent().css("opacity", 0.2); }, 10); } $("#dialog").kendoWindow({ modal: true, open: onOpen }); </script> You could try .k-overlay { opacity:0.9 !important; } instead. That will override the setting which kendo applies directly to the overlay. 来源: https://stackoverflow.com

Gray out a row in kendo grid based on column value

十年热恋 提交于 2019-12-02 09:00:35
I have a Kendo Grid whose values get populated based on a post call. I need to gray out an entire row if one of the column has a value "REGISTERED". Is there a way we can achieve this? Add a handler function for the onDataBound event . In the onDataBound event handler, add jQuery that grey out column, something like this: function onDataBound(event) { // ... // Assumes your Kendo grid DOM element, or other appropriate element enclosing your disabled rows, is in the "el" variable el.find( ":contains('REGISTERED')" ).addClass("disabled"); } <style> .disabled { color: #999; } /* Or however you

kendo ui Editable color input field on grid

耗尽温柔 提交于 2019-12-02 08:18:05
As you can see in the code below, i have a grid with editable cells. At the column named "szin" i tired to implement a kendo colorpicker and it works just fine. My problem is, that the colors are only displayed when you try to edit one of the cell. Can i make it permanently displayed somehow? I dont care if the bg-color of the cell change or the dropdown box visible all the time or with any other methods. Here's my code: <!DOCTYPE html> <html> <head> <link href="../styles/kendo.metro.min.css" rel="stylesheet"> <link href="../styles/kendo.common.min.css" rel="stylesheet"> <script src="../js

Kendo UI Grid Editors Based on the Column Values of the Grid

十年热恋 提交于 2019-12-02 08:12:05
问题 I found this article in the Kendo UI documentation and it's almost identical to my issue that I'm stuck with. Once I open in Dojo I edit some lines of code, especially I change to editable:"inline" mode and make a dropdown list for type column. But it seem the code not working as I expected. Any idea why Editor column not react after I change the value type from the dropdown list. It worked if I Update first, then Edit back the grid. Here I provide a Demo due to related situation Appreciate

Kendo Grid: how to update data source from code when the row changes

試著忘記壹切 提交于 2019-12-02 07:23:12
this follows on from a few of my previous posts, regarding updating the kendo grid datasource. The last thing I want to do is have this occur when the user goes to a new row (thanks to @Lars so far for much impressive help) I am doing this by detecting a row change ( happen to be doing this in a directive), and calling back into the grids controller where I call the sych function on the data source... vm.rowChangedCallback = function () { console.log("calling vm.gridData.sync"); // Calling this exits edit mode and we go back to cell (0, 0) :-( vm.gridData.sync(); } Full example here . For

Kendo grid cancel causing deletion of row

爷,独闯天下 提交于 2019-12-02 07:17:10
问题 I am using kendo grid and the grid.And on a particular situation i am adding data to the datasource of the grid using grid.dataSource.add() method.The following is the configuration of my grid. var itemcodedataSource = new kendo.data.DataSource({ dataType: "json", transport: { read: function(o){ o.success([]); }, create: function(o) { var item = o.data; //assign a unique ID and return the record item.id = len; o.success(item); len++; }, destroy: function(o) { o.success(); }, update: function

Kendo Grid: how to get the selected item from a Combobox cell template when using with Angular

送分小仙女□ 提交于 2019-12-02 06:05:17
I have a Kendo grid which I am using within Angular, and have a field with a combo box, that has the editor set to the following function... function comboCellTemplate(container, options) { var input = $('<input name="' + options.field + '" />') input.appendTo(container) var combobox = input.kendoComboBox({ autoBind: true, filter: "contains", placeholder: "select...", suggest: true, dataTextField: "description", dataValueField: "code", dataSource: data, }); And data is a list of simple json objects... [ {code: 'code1', description: 'desc1'} {code: 'code2', description: 'desc2'} [ Each field in