Results 1 to 4 of 4

Thread: Ext.tree.TreeSorter???????????

  1. #1
    Ext JS Premium Member
    Join Date
    Jan 2009
    Posts
    2
    Vote Rating
    0
      0  

    Default Ext.tree.TreeSorter???????????

    ?Ext.tree.TreePanel??+??Ext.tree.AsyncTreeNode??+??Ext.tree.TreeSorter????????????????????????????????

    ?????????????Ext.LoadMask??????????????????????????

    ???????????????????????????????????

    ???????????????????????????????????????????????????????????
    ??????????????????????????

    ??????????????????????????????????????????????

    ????????????????????????????????????
    ???????????????????

  2. #2
    Sencha - Support Team yuki's Avatar
    Join Date
    Jun 2007
    Location
    Chigasaki, Japan
    Posts
    273
    Vote Rating
    0
      0  

    Default

    ???????????beforeexpand?expand???????????????????????????????????????????????????????????????
    Ext Japan, LLC [Twitter: @extjapan]
    [Ext JS / Ext GWT????????][????????????][Ext JS???????????????]

  3. #3
    Ext JS Premium Member
    Join Date
    Jan 2009
    Posts
    2
    Vote Rating
    0
      0  

    Default

    ??????????????

    ?????beforeexpand????????????expand??????????????????????
    expand???????????????????????????????????????

    Ext.tree.TreeSorter?doSort(Ext.tree.TreeNode)??????????????????
    ?????????????????????????

  4. #4
    Sencha - Support Team yuki's Avatar
    Join Date
    Jun 2007
    Location
    Chigasaki, Japan
    Posts
    273
    Vote Rating
    0
      0  

    Default

    ????????????????????1500???????????????????????????????

    PHP Code:
         Ext.onReady(function(){
            var 
    = new Ext.tree.TreePanel({
              
    renderToExt.getBody(),
              
    autoScrolltrue,
              
    height500,
              
    width300,
              
    dataUrl'treesort.php',
              
    root: {
                
    nodeType'async',
                
    text'root'
              
    }
            });

            var 
    ts = new Ext.tree.TreeSorter(t, {
              
    folderSorttrue,
              
    dir"asc",
              
    sortType: function(node){
                return 
    node.attributes.val;
              }
            });
            
            
    t.show();

            
    t.loadmask = new Ext.LoadMask(t.el, { msg"Loading..."});
            
    t.sortmask = new Ext.LoadMask(t.el, { msg"Sorting..."});

            
    t.on({
              
    beforeloadt.loadmask.show,
              
    loadt.loadmask.hide,
              
    scopet.loadmask
            
    });

            
    t.getRootNode().on({
              
    beforeexpandt.sortmask.show,
              
    expandt.sortmask.hide,
              
    scopet.sortmask,
              
    singletrue
            
    });
          }); 
    ?????????? treesort.php ????????????
    PHP Code:
      $nodes = array();
      
    $max 1500;

      for(
    $i=0$i<$max$i++){
        
    $val rand(0,$max);

        
    $n = array(
          
    "text" => "node".$val,
          
    "val" => $val,
          
    "leaf" => true,
        );
        
    array_push($nodes,$n);
      }

      echo 
    json_encode($nodes); 
    Ext Japan, LLC [Twitter: @extjapan]
    [Ext JS / Ext GWT????????][????????????][Ext JS???????????????]

Similar Threads

  1. Custom Template for Ext.tree.TreePanel (Ext.tree.TreeNodeUI)
    By roymartin in forum Ext 3.x: Help & Discussion
    Replies: 4
    Last Post: 28 Oct 2013, 10:03 AM
  2. [1.2] Ext.ux.tree.ArrayTree - Tree from array Extension (stateful, Ext 2.2 compat)
    By jsakalos in forum Ext 2.x: User Extensions and Plugins
    Replies: 31
    Last Post: 22 Aug 2010, 12:34 PM
  3. Ext.tree: reset Treeloader & render Tree without pageref
    By oxi in forum Ext 1.x: Help & Discussion
    Replies: 3
    Last Post: 23 Jan 2010, 12:15 AM
  4. Extendin a EXT.tree.TreeNode or building a new Ext.tree.TreeNodeUI
    By kheraud in forum Ext 3.x: Help & Discussion
    Replies: 0
    Last Post: 25 Jul 2009, 1:52 PM
  5. Replies: 3
    Last Post: 5 Sep 2007, 10:52 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •