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

TreeViewItemModel - Enabled property

3 Answers 89 Views
TreeView
This is a migrated thread and some comments may be shown as answers.
Damian
Top achievements
Rank 1
Damian asked on 03 Jul 2014, 01:13 PM
Hello,
I have simple treeview:

@(Html.Kendo().TreeView().Name("qwerty").BindTo(new List<TreeViewItemModel>()
                             {
                                 new TreeViewItemModel
                                 {
                                     Id ="1",Text = "Test", Enabled = false, Checked = true
                                 }
                             
                             })
                            .Checkboxes(config => config.CheckChildren(true)))

but it seems that Enabled property doesn't work, node is still enabled.
Is there any option to disable node using MVC wrapper?

3 Answers, 1 is accepted

Sort by
0
Daniel
Telerik team
answered on 07 Jul 2014, 08:50 AM
Hello Damian,

I tried to reproduce the problem with the Enabled property but to no avail. Could you check the attached project and let me know if the property is working as expected on your side or if I am missing something?


Regards,
Daniel
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
0
Damian
Top achievements
Rank 1
answered on 10 Jul 2014, 12:09 PM
Hi Daniel, 

very sorry my bad, it works well in this scenario but not  with a template :

@(Html.Kendo().TreeView().Name("qwerty").BindTo(new List<TreeViewItemModel>()
                             {
                                 new TreeViewItemModel
                                 {
                                     Id ="1",Text = "Test", Enabled = false, Checked = true
                                 }
                             
                             })
                            .Checkboxes(config => config.CheckChildren(true)) .Template("<i class='fa fa-cube'></i>  #: item.text # "))
0
Daniel
Telerik team
answered on 14 Jul 2014, 07:54 AM
Hello again,

Thank you for clarifying. I reproduced the problem with the Enabled property in this case and it seems that the property is not serialized. We will fix this for the next official release which is expected later this week. I also updated your Telerik points for the bug report.

Regards,
Daniel
Telerik
 
Join us on our journey to create the world's most complete HTML 5 UI Framework - download Kendo UI now!
 
Tags
TreeView
Asked by
Damian
Top achievements
Rank 1
Answers by
Daniel
Telerik team
Damian
Top achievements
Rank 1
Share this question
or