This is a migrated thread and some comments may be shown as answers.

Edit popup not working when call grid.setOptions

4 Answers 313 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Jose
Top achievements
Rank 1
Jose asked on 28 May 2018, 09:43 AM

Hi Team,

I am using column menu in grid toolbar and storing column state on local-storage. Whenever page reload I am getting the grid options from local storage using below code.

var grid = $("#myGrid").data("kendoGrid");
var options = localStorage.getItem("kendo-grid-myGrid");
if (options) {
    grid.setOptions(JSON.parse(options));
}

I am using row editable as popup with template. In this template I am using some kendo drodpdown and a custom window scroll.

Once the setOptions called drop drown source and window scroll is not working. Any help on this.

 

Thanks in Advance

Jose

4 Answers, 1 is accepted

Sort by
0
Stefan
Telerik team
answered on 29 May 2018, 06:17 AM
Hello, Jose,

Thank you for the details.

A similar issue can occur if the DropDown and the Window scroll as set with functions. If this is the case, please have in mind that the functions references are lost and they have to be added again:

https://docs.telerik.com/kendo-ui/api/javascript/ui/grid/methods/setoptions#setOptions

If this is not the cause of the issue, please provide an example and I will gladly investigate what may be causing it.

Regards,
Stefan
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Jose
Top achievements
Rank 1
answered on 29 May 2018, 01:01 PM

Hi Stefan,

Thanks for the reply. Apart from window scroll I am using few controls of Kendo like dropdownlist and datepicker in my edit template like below. Once I took options from localStorage these controls not working.

<select kendo-drop-down-list class="form-control" k-value-primitive=true k-data-text-field="'text" k-data-value-field="'value'" k-data-source="myDataSource" k-ng-model="dataItem.myDropVal"></select>

<input type="text" kendo-date-picker class="form-control" data-bind="value: current_date">

Thanks,
Jose

0
Accepted
Stefan
Telerik team
answered on 30 May 2018, 06:21 AM
Hello, Jose,

I can assume that this is the same issue as described in the following forum post.

Please check if the suggested answer will be useful in this case:

https://www.telerik.com/forums/custom-angular-column-editor-stops-working-after-calling-setoptions

Regards,
Stefan
Progress Telerik
Try our brand new, jQuery-free Angular components built from ground-up which deliver the business app essential building blocks - a grid component, data visualization (charts) and form elements.
0
Jose
Top achievements
Rank 1
answered on 30 May 2018, 09:22 AM
Thank you so much Stefan. It resolve my issue.

Thanks & Regards,
Jose
Tags
Grid
Asked by
Jose
Top achievements
Rank 1
Answers by
Stefan
Telerik team
Jose
Top achievements
Rank 1
Share this question
or