TermOrder final class
Minn\Runtime\TermOrder · public/minn/src/Minn/Runtime/TermOrder.php · 61 lines
A term query's ORDER BY as the reference writes it (probe wp-term-query-sql): term and taxonomy columns, the relationship's order, the order include or slug lists give, none, or the name; then get_terms_orderby, and after it a meta key or meta_value[_num] when the query has meta clauses.
Uses 1
Used by 1
Constants and properties
| private | TERM_COLUMNS = array ( 0 => 'term_id', 1 => 'name', 2 => 'slug', 3 => 'term_group', ) | |
| private | TAXONOMY_COLUMNS = array ( 0 => 'count', 1 => 'parent', 2 => 'taxonomy', 3 => 'term_taxonomy_id', 4 => 'description', ) |
Public
| static | direction(mixed $order): string# | ASC when asked for, DESC for anything else. |
| static | clause(WP_Term_Query $query, string $raw): string# | The ORDER BY body for an orderby value, filtered as the reference filters it. |
| static | meta(WP_Term_Query $query, string $orderby): string# | A meta key, meta_value[_num] or a named meta clause as SQL (parse_orderby_meta), or '' when the query has no such clause. |
Nothing matches.