Telerik Forums
Kendo UI for jQuery Forum
4 answers
488 views

Hi,

What is the most efficient way to update the map layer datasource? For this map I use a url I'd like updated (because a get parameter changes).

I read this: http://d585tldpucybw.cloudfront.net/forums/change-marker-layer%27s-data-source

But it's outdated, currently there is no more _initDataSource() and the setDataSource() did find its way to the layer object but I can't get it to work:

don't find an example for it.

 also, I tried:

var layer = $("#selectionMap").data("kendoMap").layers[0];
layer.dataSource.transport ={read:$scope.baseUrl+"/MapStatistics"+"?countryvar="+$scope.ui.subSelections.countryVar};
layer.reset();

 Also tried this:

layer.setDataSource({type: "geojson",transport: {read:$scope.baseUrl+"/MapStatistics"+"?countryvar="+$scope.ui.subSelections.countryVar}})

 

Error: this.dataSource.unbind is not a function

So my question: Is there an efficient way to do this so the map is reloaded on layer url update?

thanks,

Arno
       

 

Alex Hajigeorgieva
Telerik team
 answered on 04 Jul 2018
8 answers
373 views

GroupFooterTemplate works during load, but after removing the age from header and readding, the grid crashes.

Any suggestions?

 

Example in following link.

https://dojo.telerik.com/EhIkExel/2

Alex Hajigeorgieva
Telerik team
 answered on 03 Jul 2018
1 answer
264 views
Is there a way to add subtitles/closed-captioning to the player?
Georgi
Telerik team
 answered on 03 Jul 2018
1 answer
63 views

If I have a video in only two formats (ogg and webm), can I add both as sources and have the media player automatically detect which one to use?  Or do I need to do the necessary browser checks before adding the source to the player?

Georgi
Telerik team
 answered on 03 Jul 2018
3 answers
890 views

Hello All

I was going through the example below and I would like to know how I could enable filtering on the grid that was initialized from a HTML table.

https://demos.telerik.com/kendo-ui/grid/filter-row

In my case the data source for the grid is not odata. I would like to enable filtering for the below example:

https://demos.telerik.com/kendo-ui/grid/from-table

Any pointers would be appreciated!

Thanks.

Vijhay Devarajan.

 

 

Eyup
Telerik team
 answered on 03 Jul 2018
1 answer
254 views

Hello
I am trying to save PivotGrid state for future load.But I have a problen: The expand property of row items is not changed at run time. Test here https://dojo.telerik.com/@Mzand/obIkEdAY : When the user expands an item at runtime the expand property of the returned row by dataSource.rows() is the same as what it was at initialization. Isn't it data-binded? Is there a way to get the value?

 


Preslav
Telerik team
 answered on 03 Jul 2018
2 answers
191 views

It is easy to add style to grid column cells with https://docs.telerik.com/kendo-ui/api/javascript/ui/grid/configuration/columns.attributes

How can I style the groupFooterTemplate?

Example here:

https://dojo.telerik.com/oYoVOjAq/3

Viktor Tachev
Telerik team
 answered on 03 Jul 2018
3 answers
1.4K+ views

Hiya,

I was trying to hide the expand/collapse column and use the row click to expand/collapse the row detail instead. I was able to implement each individually but when I combine them the row click is no longer working.

I use the following to hide the expand/collapse column in the DataBound event:

$(".k-hierarchy-cell").remove();
$(".k-hierarchy-col").remove();

And something like the following to implement the row click to expand the row detail:

element.on('click','tr',function(){
   $(element).data().kendoGrid.expandRow($(this));
})

Did I miss anything?

 

Cheers,

Byang

 

Preslav
Telerik team
 answered on 03 Jul 2018
2 answers
354 views
Hi
Is there a way in which we could show both the month and year on the section where the date is shown which is also movable on skipping the date range

My current scheduler looks something like this
Ivan Danchev
Telerik team
 answered on 03 Jul 2018
3 answers
555 views

Hi all,

I'm currently trying to implement an MVC grid which contains a multi select editor template.  In the DB it's stored as a comma separated list of strings, but I wish to display it as a multi select (to help the user input data) so i changed my viewmodel property to a list of a custom model.  I've attempted this myself, but it doesn't appear to be posting to my controller action. If i add items, they appear to add to the datasource but dont post to the controller (come through as "nothing"), however, if i add 3 items, then remove one using the X

My bound column

columns.Bound(Function(cond) cond.Value).EditorTemplateName("MyTemplate_Value")

 

My customer object

Public Class TheValue
    Public Property MyValueID As String
    Public Property MyValue As String
End Class

My Editor Template

@Html.Kendo().MultiSelectFor(Function(m) m).DataTextField("MyValue").DataValueField("MyValueID").Events(Sub(ev) ev.DataBound("MultiSelect_DataBound"))
 
 
    <style>
        #Value-list {
            display: none !important;
        }
    </style>

 

My javascript

var currentId = 1;
 
function MultiSelect_DataBound(e) {
    $('.k-multiselect .k-input').unbind('keyup');
    $('.k-multiselect .k-input').on('keyup', onClickEnter);
}

function onClickEnter(e) {
    if (e.keyCode === 13) {
        var widget = $('#Value').getKendoMultiSelect();
        var dataSource = widget.dataSource;
        var input = $('.k-multiselect .k-input');
        var value = input.val().trim();
        if (!value || value.length === 0) {
            return;
        }
        var newItem = {
            MyValueID: currentId++,
            MyValue: value
        };

        dataSource.add(newItem);
        var newValue = newItem.MyValueID;
        widget.value(widget.value().concat([newValue]));
    }
}

 

 

 

Any help would be appreciated!

Georgi
Telerik team
 answered on 03 Jul 2018
Narrow your results
Selected tags
Tags
+? more
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Rob
Top achievements
Rank 3
Iron
Iron
Iron
Atul
Top achievements
Rank 1
Iron
Iron
Iron
Alexander
Top achievements
Rank 1
Veteran
Iron
Serkan
Top achievements
Rank 1
Iron
Shawn
Top achievements
Rank 1
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?