diff --git a/README.md b/README.md index edc6418..2173680 100644 --- a/README.md +++ b/README.md @@ -118,6 +118,8 @@ Attributes of angular treecontrol - `labelSelected` : inhect classes into the div element around the label only when the node is selected - `on-selection` : function to call on the current `$scope` on node selection. - `selected-node` : parameter on the `$scope` to update with the current selection. +- `order-by` : value for ng-repeat to use for ording sibling nodes +- `reverse-order` : whether or not to reverse the ordering of sibling nodes based on the value of `order-by` ### The tree labels diff --git a/angular-tree-control.js b/angular-tree-control.js index 840ff93..55c3b90 100644 --- a/angular-tree-control.js +++ b/angular-tree-control.js @@ -31,7 +31,9 @@ treeModel: "=", selectedNode: "=?", onSelection: "&", - options: "=?" + options: "=?", + orderBy: "@", + reverseOrder: "@" }, controller: function( $scope ) { @@ -111,7 +113,7 @@ //tree template var template = '