This is a migrated thread and some comments may be shown as answers.

[Solved] Ajax TreeView does not work with Ajax Grid Editing

3 Answers 39 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Sergey Steshenko
Top achievements
Rank 1
Sergey Steshenko asked on 30 Jun 2010, 02:51 PM
Hello.

In this example I have reproduced a non-working situation from my project.
If from the grid to delete the editing button the tree begin to work.
And, the example with editing works in version 2010.1.309, but does not work in all following versions up to 2010.1.518.

    <div style="float: left; width: 300px; height: 400px;"> 
        <%= Html.Hidden("tvItem", ViewData["tvItem"]) %> 
        <%= Html.Telerik().TreeView() 
                .Name("tvAjaxSelect") 
                .BindTo(Model, (item, mitem) => 
                { 
                    item.Text = mitem.ItemName; 
                    item.Value = mitem.ItemId.ToString(); 
                    item.LoadOnDemand = mitem.isChildren; 
                    item.Selected = mitem.ItemId == (int)ViewData["tvItem"]; 
                }) 
                                             
                .DataBinding(dataBinding => dataBinding 
                        .Ajax().Select("AjaxTreeView", "Home") 
                ) 
                .ClientEvents(e => e 
                    .OnSelect("tvNodeSelect") 
                )               
        %> 
         
    </div> 
    <div style="margin: 0 0 0 310px;"> 
        <%= Html.Telerik().Grid<grItemModel>() 
                .Name("Grid") 
                .DataKeys(dataKeys => dataKeys.Add(c => c.ItemId)) 
                .Columns(columns => 
                { 
                    columns.Bound(o => o.ParentId).Width(100); 
                    columns.Bound(o => o.ItemId).Width(100); 
                    columns.Bound(o => o.ItemName); 
                    columns.Command(commands => 
                    { 
                        commands.Edit(); 
                    }).Width(190).Title(" "); 
                }) 
                .DataBinding(dataBinding => dataBinding.Ajax() 
                    .Select("AjaxGrid", "Home", new { parentId = ViewData["tvItem"] }) 
                    .Update("UpdateGrid", "Home") 
                ) 
                .Selectable() 
                .Pageable() 
        %> 
    </div> 


Thanks.
Serg Steshenko

3 Answers, 1 is accepted

Sort by
0
Georgi Krustev
Telerik team
answered on 30 Jun 2010, 03:54 PM
Hello Sergey Steshenko,

The most probable reason for this erroneous behavior is that jQuery.1.4.2 delegate method is overridden by jquery.validate.js delegate method. Thus the components (like TreeView) will not work properly. Check this online thread devoted on the same matter. The proper version of the jquery.validate.js can be download from same thread.

Sincerely yours,
Georgi Krustev
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
Sergey Steshenko
Top achievements
Rank 1
answered on 30 Jun 2010, 04:08 PM
Hello, Georgi Krustev.

Thanks for a prompt reply. I read this thread. Therefore I have created a test example, having taken the last version telerik mvc from indicated thread. Unfortunately the error remained.

Sergey Steshenko.

P.S. I can not attach *.zip with my test example.


0
Sergey Steshenko
Top achievements
Rank 1
answered on 30 Jun 2010, 04:15 PM
Sorry. Many thanks. With this version jquery.validate.min.js all works. But with that which in 2010.1.518 did not work. Once again many thanks.
Tags
TreeView
Asked by
Sergey Steshenko
Top achievements
Rank 1
Answers by
Georgi Krustev
Telerik team
Sergey Steshenko
Top achievements
Rank 1
Share this question
or