Announcement

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

    TreeGrid: load on demand

    Hi Isomorphic,

    We are using SmartGWT Pro 3.0 branch (02/02/2012 nightly build).

    Does TreeGrid have a built-in load on demand similar to ListGrid?

    What is the best practice to load 10,000 nodes in the TreeGrid?

    Thanks,

    #2
    TreeGrid supports folder by folder load on demand. See the Tree DataBinding overview.

    You shouldn't attempt to load 10,000 nodes because that's an inefficient approach. But via load on demand the TreeGrid can of course allow navigation through a tree that large or much larger, without loading all of the nodes.

    If you have nodes that have a very large number of children, we recommend parallel us of a TreeGrid plus a ListGrid to show nodes in a folder (similar to Outlook email). This is both more usable and more efficient.

    Comment


      #3
      Hi Isomorphic,

      We are using the TreeGrid with the load data on demand option loading the folder's nodes when the user expands a folder.
      We are also using the TreeGrid.setCascadeSelection(true) option.
      How we can make a cascadingSelection work when not all the folders open, but some nodes in those folders could be selected?

      Thanks,

      Comment


        #4
        Unfortunately we do not currently support having cascadeSelection enabled with load data on demand.

        Implementing this is not a trivial change - we'd need support for the client detecting and applying initial server-side selection state, as well as a mechanism for performing cascaded selection on the client and notifying the server of selection changes. The server would also need to have logic in place to react to changes made by the client.
        If this is a feature you need, it would be eligible for feature sponsorship. If you are interested in this please let us know and we can pin down the specification and put together an estimate.

        Depending on your usage it would also be possible to implement your own solution using a dedicated dataSource field containing your "selection state" information (selected, unselected, partially selected) and using valueIcons to display this to the user. If this is static (not editable by the user) this would be quite straightforward.
        If you needed the user to be able to edit this field, it could be marked as editable and you would need some logic in place to handle "cascading" the selection when the user made a change (most likely by updating values in your server side logic and then notifying the client of the changes so it could redraw to reflect the new selection state).

        Hopefully this clears things up

        Thanks
        Isomorphic Software

        Comment

        Working...
        X