Reputation: 557
By default, the wayfinder plugin in modx revo should sort by menuindex. This doesn't seem to work. I have the following:
[[!Wayfinder? &startId=`2` &level=`1` &ignoreHidden=`TRUE` &outerClass=`news` &sortBy=`menuindex` &sortOrder=`DESC`]]
I suspect it's something stupid I overlooked...
EDIT: I've made it work now.
I looked into the wayfinder code in wayfinder.class.php
. The following line was commented out:
$c->groupby($this->modx->getSelectColumns('modResource','modResource','',array('id')));
It happened because of the following comment in the code:
/* not sure why this groupby is here in the first place. removing for now as it causes issues with the sortby clauses */
Maybe this will help someone in the future.
Upvotes: 1
Views: 857
Reputation: 557
I looked at the wayfinder code in wayfinder.class.php The following line was commented: $c->groupby($this->modx->getSelectColumns('modResource','modResource','',array('id')));
It was commented out because of the following comment in the code:
/* not sure why this groupby is here in the first place. removing for now as it causes issues with the sortby clauses */
Maybe this helps anyone in the future
Upvotes: 1