kendo-ui

Tooltip Template Formating in Kendo-UI

久未见 提交于 2019-11-28 10:53:57
问题 I have the following code, and initially my data consists only x and y values, however, once I added another value which is k but it stopped working. I am planning to display k value as an additional information into tooltip. Does anybody has any idea? function createChart() { $("#chart") .kendoChart({ xAxis: {}, yAxis: {}, seriesDefaults: {type: "scatterLine" }, series: [{data: stats}], tooltip:{visible:true,template: "#= myTooltip(value) # "} }); } function myTooltip(value) { return Math

How to disable past dates without hiding them in Kendo date picker?

匆匆过客 提交于 2019-11-28 08:33:25
问题 If I set min value for the date picker, it does not display dates less than min date when it's opened. My requirement is that dates less than min date should be shown in the date picker, but they should be disabled. 回答1: You can make it with CSS styles and using custom content in Kendo datepicker. HTML: <input id="datepicker" style="width:150px;" /> CSS: .disabledDay { display: block; overflow: hidden; min-height: 22px; line-height: 22px; padding: 0 .45em 0 .1em; cursor:default; opacity: 0.5;

How to change the value of a kendo bound html input

独自空忆成欢 提交于 2019-11-28 07:22:43
问题 I have a kendoui grid with a custom popup for editing. In this popup I have an input which is bound to a value of the grid: <input type="text" class="k-input k-textbox" id="test" data-bind="value:SearchFilter"> This works fine. Click edit in the grid, change the value in the textbox and the value propagates to the grid. But now I want to change the value of the textbox in javascript.. So I now have this: $('#test').val("testvalue"); This indeed changes the value of the textbox, but upon save

Kendo ui datasource refresh?

谁说我不能喝 提交于 2019-11-28 07:00:39
问题 I have used kendo grids and charts fine and refreshed them with the following example code: $("#Product").data("kendoGrid").dataSource.read(); However, I have used the datasource just to provide some basic data in a different view, like in this example where it does not use the grid http://demos.kendoui.com/web/datasource/index.html Is there a way to refresh this datasource in the same kind of way as the above code does for the grids and charts? Thanks, Matt 回答1: It seems to be that only the

Issues with KendoUI and jQuery 1.9.0

本小妞迷上赌 提交于 2019-11-28 06:55:53
问题 Running into an issue with KendoUi and the latest version of jQuery ... I have simple ASP.NET MVC project with a single view that renders as follows: <!DOCTYPE html> <html> <head> <meta charset="utf-8" /> <meta name="viewport" content="width=device-width" /> <title>Index</title> <link href="/Content/site.css" rel="stylesheet"/> <script src="/Scripts/modernizr-2.5.3.js"></script> </head> <body> <h2>Index</h2> <script src="/Scripts/jquery-1.9.0.js"></script> <script src="http://cdn.kendostatic

Kendo UI Grid Conditional editing

 ̄綄美尐妖づ 提交于 2019-11-28 06:44:44
问题 I would like to disable DiscountPercentageMRC/NRC/Usage columns for certain CatalogProductId's. Please find below javascript for the grid. Any help would be greatly appreciated. <h2>Kendo Grid bound to ASP.NET MVC action methods</h2> @* The DIV where the Kendo grid will be initialized *@ <div id="grid"></div> <script> $(document).ready(function () { $("#grid").kendoGrid({ columns: [ { field: "CompanyId"}, { field: "CompanyName" }, { field: "DiscountPercentageMRC" }, { field: "CatalogProductId

Remember expanded detail grids on refresh in Kendo-UI

删除回忆录丶 提交于 2019-11-28 06:09:39
问题 I have a scenario with grid within grid implemented using the detailInit method. Here when user makes edit, i do some calculations that will change the data in the both parent and child. and then to refresh data, i will call the datasource.read to render data. this works and the data is displayed, however any detail grid which are expanded will be collapsed, is there any way i can prevent this from happening. 回答1: To answer this and another question: "I figured out how to set the data in the

How to bind Kendo Grid with System.Data.DataTable at runtime

谁都会走 提交于 2019-11-28 05:08:40
问题 I need to open a Kendo Grid in popup on Button Click. On button click server returns DataTable which has dynamics column (i.e. 1 to n no. of columns).On button click i get DataTable using jQuery ajax call. But I am unable to bind that data. How to resolve this issue 回答1: Try like this, Script <script type="text/javascript"> $(function () { schmebind(); }); function schmebind() { var schemaModel = {}; var type; var IsEditable = false; var dateColumnArray = []; $.each(JaiminField, function

Adding bindeable checkbox column to grid

醉酒当歌 提交于 2019-11-28 04:44:15
Have this column in a Kendo grid that currently display a MySQL Boolean value so we have either 1 or 0. Made this demo to play on... This in an autosync and inline:true grid. I would like this column to be of type "Checkbox" but, for some weird reasons, i just cannot find a demo or an example on the web that displays "enabled" checkbox that changes 1 to 0 when unchecked and Vice-Versa. There are some previous considerations: When you click in a cell for editing you are switching it to edit mode and then is when editor function get executed. If you are not in edition mode despite of the HTML

Kendo grid date column not formatting

≯℡__Kan透↙ 提交于 2019-11-28 04:03:23
I have a KendoGrid like below and when I run the application, I'm not getting the expected format for date column. $("#empGrid").kendoGrid({ dataSource: { data: empModel.Value, pageSize: 10 }, columns: [ { field: "Name", width: 90, title: "Name" }, { field: "DOJ", width: 90, title: "DOJ", type: "date", format:"{0:MM-dd-yyyy}" } ] }); When I run this, I'm getting " 2013-07-02T00:00:00Z " in DOJ column. Why it is not formatting? Any idea? I found this piece of information and got it to work correctly. The data given to me was in string format so I needed to parse the string using kendo.parseDate