Telerik Forums
Kendo UI for jQuery Forum
4 answers
468 views
I created an application using the Teleirk MVC wrapper for Kendo UI grid with a SignalR datasouce.

An update of the grid was transmitted and reflected on all clients running the application perfectly (with client side filtering, sorting, paging). The datasource I was using was rather large (which caused some performance issues with the filtering, sorting, paging operations). So I then re-configured my grid to use server filtering, sorting, paging which did fixed my performance issue and drastically improved the usability of the application. 

After I reconfigured to move those actions server-side I noticed a change I was making was not being reflected on all the client machines. I then switched back and forth between client-side and server-side filtering, sorting, and paging to verify that that change was the cause of my issue to be sure.

Has anyone experiences this before themselves? And can you provide me with steps/advice on how to fix this?

Thank you
Dan
Top achievements
Rank 1
 answered on 10 Nov 2014
1 answer
130 views
Hi,

I've got a short question regarding MVVM, ListView and Pager:

The template contains a ListView and a Pager, both initialized via data attributes:

<div id="thumbnail-list" data-role="kendo.ui.ListView" data-bind="source:thumbs" data-template="template-thumbnails" data-source="{ 'pageSize': 52}"></div>
<
div id="pager" class="k-pager-wrap" data-role="pager" data-bind="source:thumbs, events: { change: onChange }" data-source="{ 'pageSize': 52}"></div>

Now I want to change the "buttonCount", but not quite sure how to do this. I've looked at how it works via JS initialization, but does it also work with data-attributes?

Trying to set it after initialization like this does not work:
var pager = $("#pager").data("kendoPager");
if(pager != null){  
  pager.options.buttonCount = 3;    
  pager.refresh();
}

Thanks in advance,
Patrick
Patrick
Top achievements
Rank 1
 answered on 10 Nov 2014
1 answer
238 views
I have a TreeView with 4 levels of nodes. Here is my scenario

1) Expand the tree tree along one path all the way down to the leaf nodes.
2) Now I need to go back to the second level node and remove all child branches so that the next time I expand this node the data is reread from the database.

Currently if I just collapse the second level node the data will remain on the client and not be refreshed from the database.

How can I do this? There seems to be multiple ways to prune / destroy / remove / detach a branch of nodes and I am unsure which will force a reread from the database.

Or is there a way to instruct the treeview to always reread from the database when a node is expanded?

Thanks

Stevebn
Alex Gyoshev
Telerik team
 answered on 10 Nov 2014
1 answer
1.2K+ views
I have an Grid using paging and Ajax. I want to add a button, which when clicked causes the grid to be filtered. I added the code below:

$(function () {
    var grid = $("#grid").data("kendoGrid");
    var dataSource = grid.dataSource;
 
    var button = $("#myButton");
    button$("#myButton").click(function (e) {
        dataSource.filter(
            {
                "field": "Name",
                "operator": "eq",
                "value": "Bob Hoskins"
            });
    });
})

This causes the grid to make two calls to my Ajax resource. In the first call, the correct filter is passed and the grid briefly shows the correct filtering in the browser. Then a second call happens without my filter and the grid goes back to having no filters applied to it.
Daniel
Telerik team
 answered on 10 Nov 2014
1 answer
89 views
Hi, 
this option (it works fine on Grid) cannot work with TreeList.
columns : [
 { field: "name", title : "{{ 'test: ' }} "
]

I think because title property it's not compiled with Angular.

Is it possibile to have in TreeList the same behavior of Grid?

Thanks
Alex Gyoshev
Telerik team
 answered on 10 Nov 2014
1 answer
115 views
Hi,
I'm trying the new TreeList control (Q3 Beta) with AngularJs, but I TreeList toolbar doesn'ìt work as expected because its content is not compiled.

To reproduce the error:
1. Open in Telerik Dojo the TreeList / AngularJS example
2. Add a toolbar options like below
toolbar: "<p>Toolbar content is not compiled... 1 + 1 = {{ 1 + 1 }}.</p>",
3. Run Dojo

With TreeList control toolbar content is not compiled... so you will see 1 + 1 = {{ 1 + 1 }}​ instead 1 +1 = 2

With Grid control all works fine, so if you create the same example opening Grid / AngularJS example you will see 1 + 1 = 2

Do you plan to fix this bug before the official Q3 release?

Thanks in advance



Alex Gyoshev
Telerik team
 answered on 10 Nov 2014
3 answers
138 views
Hi Team,

We are using kendo grid(version Q2 2014) with angularjs(version 1.3 - used for my current project).
Kendo grid is rendering the data properly but we are having issues in fetching the selected table row index and its associated data using k-on-change event.

So, we wanted to know whether Kendo grid is compatible with angularjs(version 1.3) as current version of kendo grid supports only angularjs version 1.2.21 ?

If yes, is there any provision to capture the event for the selected row index data in kendoui grid using angularjs(version 1.3) ??
If no,when are you planning to release the kendo-angular.js based on angular.js version 1.3 ??

If this is the problem already known by you, what are all other kendo controls that are incompatible with angularjs 1.3 ?

Regards,
Siva
Kiril Nikolov
Telerik team
 answered on 10 Nov 2014
4 answers
249 views
We need to show 2 check-boxes per tree node, and trying to do this with a custom template and mvvm databind - but I cant get it to to work

I took the sample here  (in this case just trying to get one checkbox to work in my template to prove theory)
http://demos.telerik.com/kendo-ui/treeview/mvvm

and amended so that the html decl had instead a template defined using data-template="treeview-template", and added a 'chk' field to the test data 
      
The template looks like (and i added item.chk display to the end for my sanity)
<script id="treeview-template" type="text/kendo-ui-template">
    #= item.name # <input type='checkbox' data-bind='checked: chk'></input> #: item.chk #
</script>
Note in above i also tried databind='checked: item.chk' 

i am sure its something obvious...  any helpers appreciated

See this dojo for the example
http://dojo.telerik.com/@cobcob/IRUx/2

Thanks

Chris


Alex Gyoshev
Telerik team
 answered on 10 Nov 2014
1 answer
92 views
I've set the culture of the datetimepicker to "nl-NL", but when I open the datepicker popup everything looks correct except for the 'today' date in the bottom of the popup. This one is still set to "en-US". I've set the kendo culture in the document onload and I've added the culture file to my project. Is there anything I've forgot to set, or could this be a bug in the datetimepicker? 
Georgi Krustev
Telerik team
 answered on 10 Nov 2014
1 answer
220 views
Hello,

   I have one function that return hierarchical dataset.
   This dataset is set as datasource for Autocomplete control, which uses just parent portion of data. 
   Goal:  do not make another request to server for data, after selection of item in Autocomplete   _copy_ selected dataitem (with children) from autocomplete dataset to    treeview - i.e make it treview's dataset.  It is Ok also to copy into treeview not just selected item  but entire set returned for Autocomplete after search.
So far no luck...
   
   Code:


   @(Html.Kendo().AutoComplete()
                      .Name("findvendor")
                      .DataTextField("company_name")
                      .Filter("contains")
                      .Placeholder("Find Vendor...")
                      .MinLength(3)
                      .DataSource(source => {
                                  source.Read(read =>{read.Action("search_vendors", "content")
                                                          .Data("function () {return {text: $('#findvendor').val() };}");}
                                                           )
                                             
                          .ServerFiltering(true);})
                      .Events(e=> e.Select("content_addvendor_vendor_found"))      
                      .Deferred() 
                )



Treeview (which suppose to be filled with Autocomplete selected item Parent and its children):


 @(Html.Kendo().TreeView().Deferred() 
                            .Events(ev => ev.Select("content_addvendor_chosen"))
                            .HtmlAttributes(new { @style = "color:black;overflow: hidden;"})
                            .Name("contactstree")
                            .BindTo(new List<ca.Models.pcm_vendor>(),(Kendo.Mvc.UI.Fluent.NavigationBindingFactory<TreeViewItem> mappings) =>
                            {
                                mappings.For<ca.Models.pcm_vendor>(bound => bound.ItemDataBound((node, vendor) =>
                                {

                                    node.Text = vendor.abbreviation  + ':' + vendor.company_name;
                                    node.Id = vendor.abbreviation;
                                    node.SpriteCssClasses = "cus-sort-quantity"; 
                                     
                                })
                                .Children(e => e.contacts));
                                mappings.For<ca.Models.pcm_vendor_contact>(binding => binding.ItemDataBound((item, contact) =>
                                {
                                    item.Text = contact.name;
                                    item.Id = '+'+contact.initials;
                                    item.SpriteCssClasses = "cus-page-white-tux"; 
                                    
                                }));
                            })
                        )


(since I use deferred load, this script placed at the top of the page)
<script>

    function content_addvendor_vendor_found(e)
    {

        var new_ds = new kendo.data.HierarchicalDataSource({ data:$("#findvendor").data("kendoAutoComplete").dataSource.data())});
        new_ds.read();
        $("#contactstree").data("kendoTreeView").setDataSource(new_ds);
        //$("#contactstree").kendoTreeView({ dataSource: new_ds }).data("kendoTreeView");
        
    }

    function content_addvendor_chosen(e) {

        alert('Node selected');
        
    }

    

</script>


Thank you!!!













Kiril Nikolov
Telerik team
 answered on 10 Nov 2014
Narrow your results
Selected tags
Tags
Grid
General Discussions
Charts
Data Source
Scheduler
DropDownList
TreeView
MVVM
Editor
Window
DatePicker
Spreadsheet
Upload
ListView (Mobile)
ComboBox
TabStrip
MultiSelect
AutoComplete
ListView
Menu
Templates
Gantt
Validation
TreeList
Diagram
NumericTextBox
Splitter
PanelBar
Application
Map
Drag and Drop
ToolTip
Calendar
PivotGrid
ScrollView (Mobile)
Toolbar
TabStrip (Mobile)
Slider
Button (Mobile)
Filter
SPA
Drawing API
Drawer (Mobile)
Globalization
LinearGauge
Sortable
ModalView
Hierarchical Data Source
Button
FileManager
MaskedTextBox
View
Form
NavBar
Notification
Switch (Mobile)
SplitView
ListBox
DropDownTree
PDFViewer
Sparkline
ActionSheet
TileLayout
PopOver (Mobile)
TreeMap
ButtonGroup
ColorPicker
Pager
Styling
Chat
MultiColumnComboBox
Dialog
DateRangePicker
Checkbox
Timeline
Drawer
DateInput
ProgressBar
MediaPlayer
ImageEditor
TextBox
OrgChart
Accessibility
Effects
PivotGridV2
Licensing
ScrollView
Switch
TextArea
BulletChart
QRCode
ResponsivePanel
Wizard
CheckBoxGroup
Localization
Barcode
Breadcrumb
Collapsible
MultiViewCalendar
Touch
RadioButton
Stepper
Card
ExpansionPanel
Rating
RadioGroup
Badge
Captcha
Heatmap
AppBar
Loader
Security
TaskBoard
Popover
DockManager
TimePicker
FloatingActionButton
CircularGauge
ColorGradient
ColorPalette
DropDownButton
TimeDurationPicker
ToggleButton
BottomNavigation
Ripple
SkeletonContainer
Avatar
Circular ProgressBar
FlatColorPicker
SplitButton
Signature
Chip
ChipList
VS Code Extension
AIPrompt
PropertyGrid
Sankey
Chart Wizard
OTP Input
SpeechToTextButton
InlineAIPrompt
StockChart
ContextMenu
DateTimePicker
RadialGauge
ArcGauge
AICodingAssistant
SmartPasteButton
PromptBox
SegmentedControl
+? more
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Top users last month
Chester
Top achievements
Rank 1
Iron
Simon
Top achievements
Rank 1
Iron
Douglas
Top achievements
Rank 2
Iron
Iron
SUNIL
Top achievements
Rank 3
Iron
Iron
Iron
Marco
Top achievements
Rank 3
Iron
Iron
Iron
Want to show your ninja superpower to fellow developers?
Want to show your ninja superpower to fellow developers?