kendo-grid

Set/Modify Title in kendo mvc grid?

一曲冷凌霜 提交于 2019-12-11 05:15:46
问题 I'm trying to get hold of column bound info . so that i can add few settings(Width,Title etc) to Kendo grid where columns are created on fly . Code: @(Html.Kendo().Grid<dynamic>().Name("Grid").AutoBind(false) //model is dynamic .Columns(columns => { for (int index = 0; index < Model.mycolumns.Count; index++) { var item = Model.mycolumns.ElementAt(index); columns.Bound(item.Value, item.Key).Title("Test").Filterable(false); // Title setting ignored } }); when i set filterable false or Title to

Drag and drop between two kendo grids

纵饮孤独 提交于 2019-12-11 05:07:01
问题 Drag and drop between two grids Problem with saving <div id="gridexample1" style="width:800px"> <div id="grid1"></div> <div id="gridexample2" style="width:800px"> <div id="grid2"></div> $(document).ready(function () { var dataSource1 = new kendo.data.DataSource({ data: [ { "ID": 1, "Name": "Roosetty" }, { "ID": 2, "Name": "timcook" }, { "ID": 3, "Name": "Sam" }, ], pageSize: 5 }); var dataSource2 = new kendo.data.DataSource({ data: [ { "ID": 4, "Name": "steve" }, { "ID": 5, "Name": "mark" },

Kendo UI Grid not populating after call to read

↘锁芯ラ 提交于 2019-12-11 04:24:58
问题 OK I have another and I'm sure I'm missing something simple again. Populating the Kendo Grid with a json result set. The load is triggered by a selection from a kendo dropdownlist control. I can see the data is returned from my webapi and converted to the json result. But the data is not displayed in the grid. What I'm missing doing wrong? Here is how grids view is added: <div id="messageGridArea"> @Html.Partial("Messages") </div> Here is dropdownlist definition: @(Html.Kendo().DropDownList()

Kendo grid is showing json data instead of the actual grid

让人想犯罪 __ 提交于 2019-12-11 04:23:43
问题 I'm trying to launch a Kendo grid in a Kendo popup Window but instead of the grid showing, I'm getting the json data. This is the code from my controller: [HttpGet] public ActionResult Read([DataSourceRequest]DataSourceRequest request, int id) { var model = Service.FindOne("Cashflows", x => x.Id == id); var cashflows = new List<flows>(); foreach (var cf in model.CashFlows) { var flow = new flows { Id = cf.Id, AssetId = cf.Id, MortgageValue = cf.MortgageValue, Year = cf.Year }; cashflows.Add

Kendo Grid - Filter Row as kendoDropDown

喜欢而已 提交于 2019-12-11 04:14:59
问题 After posting question as answer here, I correct this by creating new question. I'm trying to create row filter in kendo grid to appear as DropDown of possible values in that column. So far, closest I got is Pluc's example in linked question. Still it doesn't work as intended. In columns of kendoGrid I defined a field like this: { field: "Herkunft", title: "Herkunft", width: "120px", type: "string", filterable: { cell: { showOperators: false, template: herkunftDropDownEditor } } } This is

Excel export with caption before exported data

我只是一个虾纸丫 提交于 2019-12-11 03:40:46
问题 I was wondering if it's possible to include text above the exported data in an Excel file using Kendo UI? For example, I wish to include a description of the data above the actual data exported: Data selected using dates between 1 Jan 2011 to 1 Sep 2011 回答1: You could attach a handler to the excelExport event of the Grid and manually prepend the row to the exported workbook. The approach won't work if the exported file is filterable. excelExport: function(e) { e.workbook.sheets[0].rows

Kendo UI grid - grouped Header Columns

混江龙づ霸主 提交于 2019-12-11 03:32:52
问题 This is not related to the grouping function where you can drag things to the header and it groups the grid. I am trying to present grid columns in categories for organization in a large grid showing complex financial data for my project. I have created a very very simplified mockup of what I am trying to accomplish in google docs at this link https://docs.google.com/spreadsheets/d/11BZGrV5IE2zvh3Ya38jgCN1lgOqMFXegdwAOmv-bLZg/edit?usp=sharing The solution would need top play nice with column

DropDownList in kendo grid control (by ClientTemplate)

為{幸葍}努か 提交于 2019-12-11 03:28:44
问题 I need to make behavor for ClientTemplate like we have for EditorTemplateName. So I want to make something like this: Template: @( Html.Kendo().DropDownListFor(m => m) .BindTo((SelectList)ViewData["ExamResults"]) .Template("#:Value# #:Text#") .DataTextField("Text") .DataValueField("Value") .Events(e => e .Change("examResultOnDropDownChange") .Open("examResultOnOpen")) ) And adding column into grid: .EditorTemplateName("ExamResultGridForeignKey") but I want to: .ClientTemplate(

Custom Sorting in KendoUI grid/datasource

强颜欢笑 提交于 2019-12-11 03:09:03
问题 I have grouped data in dataSource as: var dataSource = new kendo.data.DataSource({ transport: { read: { url: " ", } }, //and some other parameters specified // group by the "category" field group: { field: "category", aggregates: [ { field: "price", aggregate: "max" }, { field: "price", aggregate: "min" } ] } }); Now i want to sort the group according to field other than the field specified here. How this could be achieved? Or how can i disable or override the default sorting behavior of "dir

Is there a way to add a placeholder to a text field in KendoUI Grid?

我怕爱的太早我们不能终老 提交于 2019-12-11 03:07:42
问题 I tried the following to add the placeholder attribute to the input field using the following code, dataSource: { ... schema: { data: "storeEmployeeData", total: "storeEmployeeDataCount", model: { id: "ID", fields: { Id: { type: "number", editable: false, nullable: true }, FirstName: { type: "string", nullable: true, editable: true, validation: { required: false } }, MiddleName: { type: "string", nullable: true, editable: true, validation: { required: false } }, LastName: { type: "string",