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: November 16, 2018).
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

Hide expansion indicator for rows with no children

Thread ID:

Created:

Updated:

Platform:

Replies:

123955 May 3,2016 08:56 AM UTC May 4,2016 12:52 PM UTC JavaScript 4
loading
Tags: ejTreeGrid
Martin Cully
Asked On May 3, 2016 08:56 AM UTC

Is it possible to hide the default expansion indicator on Treegrid rows that have no children?

Regards,

Martin

Martin Cully
Replied On May 3, 2016 01:09 PM UTC

I've tried to handle this in the queryCellInfo and it seems to work for the first page when paging is on but not on subsequent pages. Looks to me like the queryCellInfo event is not fired when going to next page.

Here's my code - I think it's too wide a scope on the css selector but I can get more specific once the event fires when going page to page:

function queryCellInfo(args) {
    if (args.data.hasChildRecords === false) {
        $(".e-treegridexpand").css({ "display": "none" });
        $(".e-treegridcollapse").css({ "display": "none" });
    }
}


Jonesherine Stephen [Syncfusion]
Replied On May 4, 2016 10:55 AM UTC

Hi Martin, 
Query 1: Is it possible to hide the default expansion indicator on Treegrid rows that have no children? 
Solution:  Only the Parent records having expander/collapse icon in Treegrid. These icons were absent in the tasks with no children.so could you please share more details related to this query with us and it will be very helpful for us to understand your requirement clearly and update the response?  
   
Query 2: I've tried to handle this in the queryCellInfo and it seems to work for the first page when paging is on but not on subsequent pages. Looks to me like the queryCellInfo event is not fired when going to next page. 
Solution: We were able to reproduce the issue in queryCellInfo trigger while selecting the subsequent pages in Paging and we have confirmed this as bug and logged a report on this. Also we have created a support incident under your account to track the status of this issue. 
Please log on to our support website to check for further updates. 
 
Please let us know if you require further assistance on this.
Regards,
Jone Sherine .P.S.
 


Martin Cully
Replied On May 4, 2016 11:30 AM UTC

With regards to query 1, this JSFiddle shows the issue. For the first row "No Children", the subtasks array is empty but the row is rendered with an expansion indicator.

https://jsfiddle.net/ptmyek7b/

Regards,

Martin

Jonesherine Stephen [Syncfusion]
Replied On May 4, 2016 12:52 PM UTC

Hi Martin, 
We regret about the inconvenience caused. 
We were able to reproduce the issue regarding the visibility of expander/collapse icon on parent record with no children and we have confirmed this as bug and logged a report on this. Also we have created a support incident under your account to track the status of this issue. 
Please log on to our support website to check for further updates. 
Please let us know if you require further assistance on this.

Regards,
Jone Sherine .P.S.
 


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.

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

;