I'm able to show bubbles if the datasource contains them at the time the map is created, but I want to be able to add them dynamically.
To add markers dynamically I do map.markers.add(marker);
To add non-bubble shapes dynamically I define my shapes layer like this:
{ type: "shape", dataSource: shapes, style: { fill: { opacity: 1 }, stroke: { width: 1, color: "#88f" } } },with shapes defined like this:
var shapes = new kendo.data.DataSource({type: "geojson"});According to this thread the only types of fields you can define in a custom datasource are "string", "number", "boolean" and "date". Unfortunately the bubble layer's location field is looking for a Lat Long, so that makes it so I can't use a kendo datasource object.
Is there a way to make this work?
Is there a way to change slider configurations dynamically at run time? One of my requirements is to have a slider with a max that gets bigger and bigger each time the tick hits the right side. For example,
100, 1000, 10000
I've see a widget.refresh() function on some other Kendo widgets.
In the following documentation page: docs.telerik.com/kendo-ui/framework/datasource/crud
you state: "The destroy action submits the data item(s) that should be deleted, or just its ID(s)."
Please explain how we can choose to send just the ID(s) and not the data-items (models). If it's a config setting, then please tell me where it should be set. If it has to be done manually by me, please give an example.
Hi - I have the following Grid with Images:
@(Html.Kendo().Grid<MvcApplication.Models.Articles>().Name("gridSelectedArticles").DataSource(dataSource => dataSource // Configure the grid data source .Ajax() // Specify that ajax binding is used //.Read(read => read.Action("Articles_Read", "Parts").Data("additionalInfo")) // Set the action method which will return the data in JSON format .ServerOperation(false) .PageSize(5) .Aggregates(a => a.Add(c => c.Price).Sum()) ).AutoBind(false).Columns(columns =>{ columns.Bound(a => a.StockCode).Title("Artikelnummer"); columns.Bound(a => a.ImageUrl).ClientTemplate("<img src='#=ImageUrl#' alt='#=StockCode #' title='#=StockCode #' width='55' />").Title("Bild"); columns.Bound(a => a.StockBalance).Title("Lagerbestand"); columns.Bound(a => a.Price).Title("Preis").Format("{0:C}") .ClientFooterTemplate("Total #= kendo.toString(sum, 'C')#");}).Pageable() // Enable paging.Sortable() // Enable sorting.Selectable(n => n.Mode(GridSelectionMode.Single)).ToolBar(tools => tools.Pdf()).Pdf(pdf => pdf .AllPages() .FileName("Kendo UI Grid Export.pdf") .ProxyURL(Url.Action("Pdf_Export_Save", "Parts")) )//.Events(e => e.DataBound("fDataChanged")))When I export to PDF, the Images are missing in the PDF File.
Images in the Sample here
http://demos.telerik.com/kendo-ui/grid/pdf-export
are exported though. What am I doing wrong?
Thank you.
Hello,
after adapting your TreeView CheckBox sample (http://demos.telerik.com/kendo-ui/treeview/checkboxes),
I'm experiencing some troubles when using the TreeView with CheckBoxes in 'checkChildren' mode.
The problem is that some items seem to be checking their parent nodes after checking them.
The children are checked correctly, but I don't think that checking the PARENTS does make any sense.
I already tried it with a lot of different nodes, this occurs not all the time.
It seems to happen only with the second root node and the first few children of it.
At first I suspected my items for having equivocal IDs, but they seem to be set appropriately.
I also tried to comment the "onCheck" and the "checkedNodeIds" function but this does not affect the behavior in any way either.
I hope you can provide help on this issue,
thanks in advance.
Ronald
Hi!
I know that Kendo Grid supports multiselection filtering for columns. Is it possible to have this in TreeList also? If yes, then how can I configure this?
Hi,
I have kendo UI schedule where events have been set from a data source. when I remove events from the scheduler following error has shown in console.
Uncaught TypeError: Cannot read property '$destroy' of undefined
please find below scheduler configuration
$scope.schedulerTimeLineOptions = { date: new Date(), majorTick: 1440, minorTickCount: 1, editable: { template: $("#editor").html(), confirmation: "Are you sure you want to delete this event?" }, views: [ "timelineWeek", { type: "timelineWeek", selected: true, dateHeaderTemplate: "<span class='k-link k-nav-day'>#=kendo.toString(date, ' dd/M ddd')#</span>" }, ], edit: schedulerDialyCalendarTimeLine_edit, add: schedulerDialyCalendarTimeLine_add, save: schedulerDialyCalendarTimeLine_save, remove: schedulerDialyCalendarTimeLine_remove, timezone: "Etc/UTC", dataBound: function (e) { var view = this.view(); if (view.name.indexOf("timeline") > -1) { view.datesHeader.find("tr:last").prev().hide(); view.timesHeader.find("tr:last").prev().hide(); }; var scheduler = this; view.table.find("td[role=gridcell]").each(function () { var element = $(this); var slot = scheduler.slotByElement(element); if (slot.startDate.getDay() == 0) { element.removeClass("k-nonwork-hour"); element.addClass("scheduler-sunday"); } else if (slot.startDate.getDay() == 6) { element.removeClass("k-nonwork-hour"); element.addClass("scheduler-saturday"); } }); }, eventTemplate: "<div class='k-event-template'>#if (data.image) {# <img src='#= image #'>#}# #= title #</div>", group: { resources: ["Priests"], orientation: "vertical" }, resources: [ { field: "priest", name: "Priests", dataSource: $filter('orderBy')($scope.ActivePriestList, 'OrderIndex'), multiple: true, title: "Priests" }, { field: "color", dataColorField: "color", dataValueField: "color", dataSource: $scope.ActiveLabelList.concat($scope.MedarbeiderenLabelList) } ], navigate: function (e) { $scope.schedulerTimeLine_navigate(e, { Id: newValue, PriestList: $scope.ActivePriestList }); }};Events have been added as below
angular.forEach(resp.WorkPlanElements, function (WorkPlanElement) { angular.forEach(cacheData.get('AllLabels'), function (Label) { if(Label.Id===WorkPlanElement.LabelId){ var WorkPlanElementItem={ Id:WorkPlanElement.Id, image : "", priest: WorkPlanElement.PriestId, start: new Date(DateUtilsService.JSONdateToString_yyyyMMdd(WorkPlanElement.Start)), end: new Date(DateUtilsService.JSONdateToString_yyyyMMdd(WorkPlanElement.End)), title:Label.Name, isAllDay: true, color: "#" + Label.ColorCode.substr( 3, Label.ColorCode.length), colorItem:{ Id:Label.Id, name:Label.Name, hex: "#" + Label.ColorCode.substr( 3, Label.ColorCode.length) }, state:"Planned", duration:DateUtilsService.dateDiff(WorkPlanElement.Start, WorkPlanElement.End), comment:WorkPlanElement.Comment }; WorkPlanElementList.push(WorkPlanElementItem); }; }); });var scheduler = $("#schedulerTimeLine").data("kendoScheduler");var dataSource = new kendo.data.SchedulerDataSource({ data: WorkPlanElementList});if (!angular.isUndefined(scheduler)){ scheduler.setDataSource(dataSource); $scope.CurrentElements = WorkPlanElementList;};
please help...!!!
Thanks
Lilan
I've disabled animation for opening and closing the date picker via animation:false. This unfortunately doesn't stop animations when selecting a month or year. How do I disable or change these animations?