Image Icons and label text not showing on sidebar navigation with treeview

I am new here in syncfusion i followed what was supposed i am expecting the result was the same but it seems i cant get it correctly please
send me working samples fro me to review thanks.
Attached herewith is the Zip file to the project solution i created ..

Attachment: WebApplication_a383c383.rar

1 Reply

SP Sowmiya Padmanaban Syncfusion Team March 16, 2020 01:14 PM UTC

Hi Jonathan,  
 
Greetings from Syncfusion support. 
 
We have checked your attached sample. We found that the reported issue occurs due to the data source for TreeView component is not properly mapped in your application.  
 
Refer the TreeView datasource in HomeController.cs file. 
 
    public IActionResult Index() 
        { 
            List<Parentitem> parentitem = new List<Parentitem>(); 
            List<childItems> childitem = new List<childItems>(); 
 
            parentitem.Add(new Parentitem 
            { 
                nodeId = "01", 
                nodeText = "Installation", 
                iconCss = "icon-microchip icon", 
 
 
            }); 
            parentitem.Add(new Parentitem 
            { 
                nodeId = "02", 
                nodeText = "Deployment", 
                iconCss = "icon-thumbs-up-alt icon", 
 
            }); 
            parentitem.Add(new Parentitem 
            { 
                nodeId = "03", 
                nodeText = "Quick Start", 
                iconCss = "icon-docs icon", 
 
            }); 
            List<childItems> childitem4 = new List<childItems>(); 
            parentitem.Add(new Parentitem 
            { 
                nodeId = "04", 
                nodeText = "Components", 
                iconCss = "icon-th icon", 
                child = childitem4, 
            }); 
            ViewBag.dataSource = parentitem; 
            return View();   
     } 
 
We have modified the sample for your requirement. 
 
 
Refer the below links, to know more about the TreeView and Sidebar components. 
 
UG Documentation: 
 
 
 
Demo link: 
 
 
 
API Reference: 
 
 
 
Please let us know, if you need any further assistance. 
 
Regards,  
Sowmiya.P 


Loader.
Up arrow icon