File tree Expand file tree Collapse file tree 1 file changed +14
-4
lines changed
codepulse/src/main/resources/toserve/pages/traces Expand file tree Collapse file tree 1 file changed +14
-4
lines changed Original file line number Diff line number Diff line change 124124 }
125125 }
126126
127- ; ( node . children || [ ] ) . forEach ( function ( kid ) {
128- var nextParent = ( node . kind == 'group' || node . kind == 'package' ) ? node : packageParentNode
129- setupTreeHierarchy ( nextParent , kid )
130- } )
127+ ; ( node . children || [ ] )
128+ . sort ( function ( a , b ) {
129+ // alphabetic sort by node.name
130+ var an = a . name . toUpperCase ( ) ,
131+ bn = b . name . toUpperCase ( )
132+
133+ if ( an < bn ) return - 1
134+ if ( an > bn ) return 1
135+ return 0
136+ } )
137+ . forEach ( function ( kid ) {
138+ var nextParent = ( node . kind == 'group' || node . kind == 'package' ) ? node : packageParentNode
139+ setupTreeHierarchy ( nextParent , kid )
140+ } )
131141
132142 } ) ( undefined , treeData . root )
133143
You can’t perform that action at this time.
0 commit comments