📢 Moderators Needed 🚀

Moderators are needed with resources to post or have access to resources to post. Submit an application to be considered.
X

RSS ThreadRepository::getDefaultThreadListSortOptions doesn't properly support multi-column sorting

  • Thread starter Thread starter Xon
  • Start date Start date
X

Xon

Guest
Guest or Bot
The ThreadRepository::getDefaultThreadListSortOptions returns a list of valid sorts, and "supports" multi-column sorting.

Suppose an add-on defines a new multi-column sort option like so;
PHP:

Code:
public function getDefaultThreadListSortOptions($forAdminConfig): array
{
    $options = parent::getDefaultThreadListSortOptions($forAdminConfig);
    $options['MyNewColumn'] = [
        ['MyNewColumn'],
        ['last_post_date'],
    ];
    return $options;
}

Then the filter functionality...

Read more

Continue reading...
 
Similar content Most view View more
Back
Top