How can i set a Kendo treeview from a Json string? - kendo-treeview

I have a json string and want to assign it to the Kendo treeview. I do it as follows:
$scope.treeview.setDataSource(JSON.parse(jsonString));
The issue is it only puts the parent nodes and not the child.
In the jsonString there is a ChildServices which are populated , but it does not show on the treeview.
How can i do this ?

Related

How to get the dataItem of edited cell in kendo grid

My problem is how I can get the dataItem(row) where a cell was updated.
The column is a dropdown menu.
It seems dataBind is not functioning well.
I am using kendo grid and angularjs in this project.
Here is a sample demo.
Try using change event of grid dataSource there you can get the current modified dataItem with updated data
change:function(event) {
}
In the above code event will be having the updated dataItem

Kendo UI ComboBox using angularjs takes time to display value on preview

We are working with kendo ComboBox using angular js. We bind value to ComboBox using angularjs scope. On preview event, when we assign value on load time (fetched from database) to ComboBox, it takes time to display value on front side in ComboBox. As we marked on preview time, first it binds data to ComboBox and then display value. Is there any solution to display selected value/text on front side, whether the ComboBox get bound or not?
Yes you can do it by applying value in the modal and setting the text accordingly.
Like Your model is countryId and have text value as countryName and name of the combobox is countryComboBox then you can use it like below:
$scope.countryId = 1 (id of which you want to be displayed at first)
$scope.countryComboBox.value(1)
$scope.countryComboBox.text('INDIA')
it will initially set the text to INDIA.

Filtering data from the extjs grid on the display values

Currently, I'm able to filter the grid using the code
new Ext.ux.grid.GridFilters({local: true,filters:[columns]}) as plugin. But this filters the store. And as the grid contains combo cells it maintains the stored value in store and displays it via the combo renderer.
I just want to know how can this be achieved so that the filter happens on the display values of the combo and not from the store Or can it be modified to filter from grid view?
Thanks in advance

how to show all parents treeview item by passing the child name-WPF Treeview

Design time we have added the treeview items. During run time, we will the take child items name and I have to show the all parents treeview items in WPF.
To a function I will pass the child treeview item, with this I have to show all parents treeview items. Please help to achieve this.

How to Bind dynamic data in textbox when user selects row in a Grid

I am using AngularJS - 1.0.6 version. I have created sample application where I want data to be populated in the textbox when user selects row in a grid. I have a directive which will render textbox and bind data with ng-model property. The model which binds the data with ng-model is dynamic. for e.g. -
input.attr('ng-model', 'model["' + d.id.toLowerCase() + '"]');
I need to use Angular.copy method to copy selected Items data into another model object.
$scope.model = angular.copy($scope.selectedItems);
I have used the same model to bind Textbox and Label. The selected data is shown in Label but not in Textbox. Here is a plunkr link with sample -
http://plnkr.co/edit/948JfxAF8lbyq1xa3Fyu?p=preview
Can anyone help me to find the solution for it?
Thanks in advance!!!
I updated your plunker with a working example. You are going to have to pass in the index of the selected item to your dynamic input control. Plunker
input.attr('ng-model', 'model[0].' + d.id.toLowerCase());

Resources