kendo-ui

Kendo UI DropDownList on change to trigger event

﹥>﹥吖頭↗ 提交于 2019-12-10 19:48:47
问题 I'm using Kendo UI for the first time and am having some difficulty triggering a function on my Kendo dropdownlist change. My goal here is to show different search fields depending on the user's drop down selection. I have tried this a few different ways, and nothing seems to work. Does anyone have a simple jQuery snippet that would get the text of the Kendo UI dropdown? My code is as follows: <script> $(document).ready(function () { var a = $("div#searchbox span.k-input").text(); console.log

Adding a Dropdown inside Kendo Grid

邮差的信 提交于 2019-12-10 19:28:15
问题 I'm trying to add a DropDown inside kendo grid but it displays a TextBox @(Html.Kendo().Grid((IEnumerable<Doc.Web.Models.Vendor.DocumentsDetails>)Model.documents_lst) .Name("grid").Scrollable() .Columns(columns => { columns.Bound(o => o.DocumentRevisionID).Visible(false); columns.Bound(o => o.Documentnumber).Title("Document #").Width(150); columns.Bound(o => o.Revision).Title("Revision").Width(80); columns.Bound(o => o.RevisionDate).Format("{0:dd/MM/yyyy}").Title("Rev Date").Width(85);

Apply kendo dropdownlist style only on angular select

耗尽温柔 提交于 2019-12-10 19:17:16
问题 I have a select which is being populated using angular binding. <select class='clsBucket' id='optBuckets' ng-options='opt as opt.name for opt in buckets' ng-model='bucketSelected' ng-change='changeBucket()'> Now i want to apply the Kendo dropdownlist style on this select , but i don't want to populate the options using kendo datasource etc and continue to do that using angular. If i use $('#optBuckets').kendoDropDownList() then i get the requiired style applied but the binding data is lost.

Column lines are not in sync in a Kendo grid

拈花ヽ惹草 提交于 2019-12-10 18:36:18
问题 I have a Kendo grid with too many columns. Initially I chose to hide some columns, but later I decided to display all the columns with a horizontal scrollbar. I did this by assigning a width to each column. When I did so, the lines between each column are not in sync with the header lines. I mean, the lines in the data part of the grid, are moved slightly to the left with respect to the header lines. To clarify, when I give the width for each column in pixels the above problem persists. But,

Kendo UI DatePicker - getting the previous value

自闭症网瘾萝莉.ら 提交于 2019-12-10 18:30:48
问题 I'm attempting to do a confirmation when a user changes a date using the date picker. Is it possible to get the previous value from the object model or will I need to roll my own? 回答1: There is not (afaik) but you can implement it pretty easily as this: var datePicker = $("#date").kendoDatePicker({ change: function (e) { var prev = $(this).data("previous"); var ok = confirm("Previous value:" + prev + ". Do you want to change?"); if (ok) { $(this).data("previous", this.value()); } else {

MVC - How to ModelBind a list an objects with this unusual post data format?

最后都变了- 提交于 2019-12-10 18:16:50
问题 Normally when you ModelBind a list of objects with MVC, the action looks like so: public ActionResult Hello(List<DocumentViewModel> viewModels) { And the Post data looks something like: [0].Id 1 [0].Name Bob [1].Id 2 [1].Name Jane But, how could I get the following post data to work? 0[Id] 1 0[Name] Bob 1[Id] 2 1[Name] Jane The Post data is being provided by Kendo UI, so I don't imagine I have much flexibility to change it. Update Thanks Petur for the answer. To expand on his answer, this

ie9 Error: 'Blob' is undefined

点点圈 提交于 2019-12-10 18:16:24
问题 this http://jsfiddle.net/bCRm3/17/ (Kendo grid export to csv) works fine in firefox, chrome and IE11 in ie9 im getting blob = new Blob([csv], { type: 'text/csv;charset=utf-8' }); //Blob.js saveAs(blob, fileName); //FileSaver.js 'Blob' is undefined show, line 141 character 17 is there a way around this for ie9? (im not sure if this works on ie10) 回答1: Check Blob object browser compatibility: Browser compatibility Chrome Firefox (Gecko) Internet Explorer Opera Safari (WebKit) 20 13.0 (13.0) 10

How to set multiline column in kendo ui grid

一曲冷凌霜 提交于 2019-12-10 17:54:53
问题 I need to set a column of a kendo ui grid to multiline. Right now the specific column has to much data in it, so its shortened by ... Is there a possibility to make that column multiline? 回答1: You can set multi-line column in kendo ui grid by using following code snippet. <style> .breakWord20 { word-break: break-all !important; word-wrap: break-word !important; vertical-align: top; } .k-grid-header .k-header { overflow: visible !important; white-space: normal !important; } </style> ...... ...

Kendo Grid: How display List<string> in one cell?

荒凉一梦 提交于 2019-12-10 17:42:51
问题 I tried to iterate through the list and display all elements into a cell in a column but I've having trouble getting it to work. Here is what I have so far. In Grid definition: columns.Bound(x => x.locationList).Title("Locations Included").ClientTemplate("#= iterate(x.locationList) #"); where x.locationList is a List<string> in the object passed in. In <script> : function iterate(object) { var html = "<ul>"; for (var x = 0; x < object.length; x++) { html += "<li>"; html += object[x]; html +=

KendoNumericTextBox percentage formatting

馋奶兔 提交于 2019-12-10 17:42:28
问题 I want to achieve the following: a percentage value (represented in model e.g. by "0.7" for 70%) should be edited in a Kendo NumericTextBox. Normal behavior for "P" formats of the NumericTextBox is that when you edit the value it shows "0.7" and when viewing the value it shows "70%". Now in our scenario we want to show "70" when editing the value (instead of "0.7"). I found that this behavior is not supported by the Kendo NumericTextBox. Of course, I could use custom formatting, e.g. "format: