We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. (Last updated on: June 24, 2019).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

After checkbox click

Thread ID:

Created:

Updated:

Platform:

Replies:

144987 May 31,2019 07:19 AM UTC Jun 5,2019 06:15 AM UTC Angular - EJ 2 5
loading
Tags: Treeview
Neha Das
Asked On May 31, 2019 07:19 AM UTC

After I click on checkbox of my tree.I am not able to create another tree structure after selection. Does the tree only load at the beginning?

It is in data-fetch component


Attachment: src_be2ddc14.zip

Vinoth Kumar Sundara Moorthy [Syncfusion]
Replied On June 3, 2019 12:19 PM UTC

Hi Neha, 
 
Good day to you. 
 
We have validated the reported issue in your provided sample and we found that you have not mapped the fields properly while assigning the dataSource which caused this issue. Please find the modified code snippets. 
 
for (let k = 0; k < this.showData.length; k++) { 
    this.showSelection.push(this.showData[k].text); 
    if (this.showData[k]["parentID"] === null) { 
        this.showData[k].hasChildren = true; 
    } 
} 
this.dataSelection = { dataSource: this.showData, id: 'id', parentID: 'parentID', text: 'text', hasChildren: 'expanded', data: 'data' }; 
 
Please check the below screenshot, 
   
 
 
Could you please check the above sample and get back to us if you need any further assistance in this? 
 
Regards, 
Vinoth Kumar S 


Neha Das
Replied On June 3, 2019 02:26 PM UTC

I am not able to remove the same by unchecking the box.It seems to hold only one data value while unchecking

Vinoth Kumar Sundara Moorthy [Syncfusion]
Replied On June 4, 2019 11:27 AM UTC

Hi Neha, 
 
Good day to you. 
 
We have checked your query “it holds one data value while unchecking” and we can able to get all the data values while unchecking the same node. Please check the below screenshot, 
 
 
 
In your source code, you have not reset the datasource using this.dataSelection while unchecking the node. Could you please provide more information about your exact use case scenario whether you need to reset the datasource of second Treeview while unchecking the node or do you want to remove the nodes based on condition? Based on this we will validate and provide you better solution quickly.  
 
Regards, 
Vinoth Kumar S 


Neha Das
Replied On June 4, 2019 11:35 AM UTC

I have done it.Thank you for the response

Kanagambigai Murugan [Syncfusion]
Replied On June 5, 2019 06:15 AM UTC

Hi Neha , 

Good day to you. 

Thanks for the update. Please get back to us if you need any further assistance. 

Regards, 
Kanagambigai 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon