-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Tree] Allow multiple order critieria in reorder and reorderAll #2744
base: main
Are you sure you want to change the base?
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||
---|---|---|---|---|
|
@@ -801,11 +801,11 @@ public function removeFromTree($node) | |||
* Reorders $node's child nodes, | ||||
* according to the $sortByField and $direction specified | ||||
* | ||||
* @param object|null $node node from which to start reordering the tree; null will reorder everything | ||||
* @param string $sortByField field name to sort by | ||||
* @param string $direction sort direction : "ASC" or "DESC" | ||||
* @param bool $verify true to verify tree first | ||||
* @param bool $recursive true to also reorder further descendants, not just the direct children | ||||
* @param object|null $node node from which to start reordering the tree; null will reorder everything | ||||
* @param string|string[]|null $sortByField Field name or array of fields names to sort by | ||||
* @param string|string[] $direction Sort order ('asc'|'desc'|'ASC'|'DESC'). If $sortByField is an array, this may also be an array with matching number of elements | ||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Is this change allowing the combination of There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yes it does. The reorder functions does nothing with the
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the context. |
||||
* @param bool $verify true to verify tree first | ||||
* @param bool $recursive true to also reorder further descendants, not just the direct children | ||||
* | ||||
* @return void | ||||
*/ | ||||
|
@@ -836,9 +836,9 @@ public function reorder($node, $sortByField = null, $direction = 'ASC', $verify | |||
/** | ||||
* Reorders all nodes in the tree according to the $sortByField and $direction specified. | ||||
* | ||||
* @param string $sortByField field name to sort by | ||||
* @param string $direction sort direction : "ASC" or "DESC" | ||||
* @param bool $verify true to verify tree first | ||||
* @param string|string[]|null $sortByField Field name or array of fields names to sort by | ||||
* @param string|string[] $direction Sort order ('asc'|'desc'|'ASC'|'DESC'). If $sortByField is an array, this may also be an array with matching number of elements | ||||
* @param bool $verify true to verify tree first | ||||
* | ||||
* @return void | ||||
*/ | ||||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.