kendo-ui

Kendo UI Grid posting back already Inserted Rows again

拈花ヽ惹草 提交于 2019-12-02 01:21:07
I am running into problem, where when an Insert is completed successfully and if i continue to insert another row, in the next insert it is also sending the row that was inserted successfully earlier, so it goes like this. On the First insert that row is posted back to webAPI and inserted successfully. On Next Insert Two rows are sent one of them was from first step. On third Insert it send previous two rows as well as third row and so on. What could be the cause of this ? This is the Code in problem. $(document).ready(function () { try { var degreeYearsArray = new Array(); function

Kendo calendar selected date event

我是研究僧i 提交于 2019-12-02 01:10:47
Hi I've a kendo calendar and a text box in my page. When I select any date on the calendar, I wanted to show that value in my textbox. (like datetime picker). Any way to get it? Here is my sample code <div id="calendar"></div> <input type="text" name="txtdate" id="txtdate"/> <script> $(document).ready(function() { // create Calendar from div HTML element $("#calendar").kendoCalendar(); }); var cal = $("#calendar").data("kendoCalendar"); cal.bind("change", function () { // Here I wanted to bind the selected value to my text box (txtdate). }); </script> var textVal = $(this).value(); $('#txtdate

Javascript: cancel or let an event continue?

允我心安 提交于 2019-12-01 23:08:52
My scenario deals with Kendo UI, but I think it probably applies to JavaScript generally, hence the JavaScript tag. I have a Kendo scheduler with the edit event option set to functionA. In functionA, I create a Kendo window (basically a modal) that asks the user a question; in one case the edit event should continue and bubble up as if the modal had never been there, in the other, it should prevent default and return. The problem is that the modal is non-blocking, so the confirm modal comes up, but the event logic continues and bubbles to the editor's built-in edit event. How can I capture and

Radio Button doesn't reflect Model's value

耗尽温柔 提交于 2019-12-01 22:16:59
I have a kendo Grid for a class, and for that class I've built an editor template to produce a radio button for one of the fields. This radio button doesn't reflect propertie's value and is always false , although I've checked the value, by printing it on the form, and I'm sure it's true . If I set a default value for that field, the radio button will reflect that value, regardless of the real value of the field. I should note that I'm using a client template to display a text for that field, and it works fine. This is the Grid: @(Html.Kendo().Grid<Class>() .Name("Grid") .Columns(columns => {

Kendo UI Grid - How to Bind to Child Properties

情到浓时终转凉″ 提交于 2019-12-01 20:52:17
How to bind a column/field to a child property of the json result in the model settings of the Kendo grid (in javascript)? For example, I want the grid to contain columns: FName, LName, Street and Address. Basically I want to flatten the hierarchical structure returned by the web service. Kendo Settings fields: { FName: { type: "string" }, LName: { type: "string" }, // How to map to child properties below? Street: { field: "Address.Street" }, // this is wrong City: { field: "Address.City" } // this is wrong } JSON { "FName": "William", "LName ": "Shakespeare", "Address": { "Address": "123

Kendo UI Grid - How to Bind to Child Properties

懵懂的女人 提交于 2019-12-01 20:46:30
问题 How to bind a column/field to a child property of the json result in the model settings of the Kendo grid (in javascript)? For example, I want the grid to contain columns: FName, LName, Street and Address. Basically I want to flatten the hierarchical structure returned by the web service. Kendo Settings fields: { FName: { type: "string" }, LName: { type: "string" }, // How to map to child properties below? Street: { field: "Address.Street" }, // this is wrong City: { field: "Address.City" } /

Kendo UI Grid Serial number column

孤街浪徒 提交于 2019-12-01 18:44:35
问题 I am trying to put the first column of the Kendo grid as the serial index, which is not affected by sorting of the row records. Is there any way I can achieve this? Thank You 回答1: You can implement this using a template column. Here is a live demo showing how to do that: http://jsbin.com/olutin/10/edit 回答2: Script Section <script> var rowNumber = 0; function resetRowNumber(e) { rowNumber = 0; } function renderNumber(data) { return ++rowNumber; } function renderRecordNumber(data) { var page =

Kendo UI Grid Serial number column

喜欢而已 提交于 2019-12-01 17:47:12
I am trying to put the first column of the Kendo grid as the serial index, which is not affected by sorting of the row records. Is there any way I can achieve this? Thank You You can implement this using a template column. Here is a live demo showing how to do that: http://jsbin.com/olutin/10/edit Razim Khan Script Section <script> var rowNumber = 0; function resetRowNumber(e) { rowNumber = 0; } function renderNumber(data) { return ++rowNumber; } function renderRecordNumber(data) { var page = parseInt($("#Role").data("kendoGrid").dataSource.page()) - 1; var pagesize = $("#Role").data(

is there a way to collapse all the panels of Kendo Panelbar, on an action?

情到浓时终转凉″ 提交于 2019-12-01 17:41:48
问题 I am working on an app where i am adding panelbars (multiselection) using JSP Wrapper (which means no ID to each of the panels), and inside those have the grids. The grids are storing data specific to the selected person, who are displayed as list items(images) on the top of the page. What I want to do is that when user changes the selection of person, from the current selected to another, collapse all the panels of the kendo panelbar. This would help in reloading the data of the new person,

is there a way to collapse all the panels of Kendo Panelbar, on an action?

你说的曾经没有我的故事 提交于 2019-12-01 17:28:32
I am working on an app where i am adding panelbars (multiselection) using JSP Wrapper (which means no ID to each of the panels), and inside those have the grids. The grids are storing data specific to the selected person, who are displayed as list items(images) on the top of the page. What I want to do is that when user changes the selection of person, from the current selected to another, collapse all the panels of the kendo panelbar. This would help in reloading the data of the new person, because when the user will select/expand the panel to see the data, i would catch the event and reload