I am using the Kendo Drop Down List with Angular. Actually i want to select current items, which means i will choose one item from partial page, it will redirect to some other page, in that page i have to select that item dynamically.
HTML Code:
<select id="controltype" kendo-drop-down-list k-options="controlDatas">/select>
Angular Code:
$scope.objectModification=function(objectData) {
$scope.objectDataFields = objectData;
var objectViewPartialElement = angular.element("objectViewPartial");
objectViewPartialElement.html("");
$compile(objectViewPartialElement)($scope);
$http({
url : './resources/staticPages/object-modification.html',
method : "GET"
}).success(function(data, status) {
$scope.data = data;
jQuery("objectViewPartial").html($compile($scope.data)($scope));
}).error(function(data, status) {
console.log("some error occured partial page");
});
// This code i am using for that selection
$("#controltype").data("kendoDropDownList").select(function(dataItem) {
return dataItem.objectId === objectDataFields.objectId;
$("#controltype").data("kendoDropDownList").refresh();
});
};