Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    TreeGrid - LoadOnDemand

    Hello,
    I am working with LoadOnDemand=="true" - "...By default, a newly loaded node will be considered to be a folder that has not loaded its children yet...."
    I want to avoid this behavior.
    I know what is the nature of my dataset, I know that each folder has only 1 level.
    Meaning that I only need the first level records to be isFolder == true and the records I will retrieve from the server (on demand) to be isFolder == false.
    In the following photo, you can see the current behavior that each child element is expandable (isFolder == true).
    I also want to avoid traverse all children and mark them as - isFolder == false.
    Click image for larger version  Name:	2019-11-20_190512.png Views:	0 Size:	54.3 KB ID:	260077

    #2
    We would recommend simply setting isFolder=false on your leaves when you return data from the server. If that's somehow onerous, two other options would be:
    1. implement a transformResponse on the DataSource that manipulates the isFolder property
    2. override the isFolder method on the auto-created ResultTree via treeGrid.dataProperties

    Comment

    Working...
    X