Automattic\WooCommerce\Internal\Admin\ProductReviews
ReviewsListTable::get_sortable_columns()
Gets a list of sortable columns.
Key is the column ID and value is which database column we perform the sorting on. The rating column uses a unique key instead, as that requires sorting by meta value.
Method of the class: ReviewsListTable{}
No Hooks.
Return
Array
.
Usage
// protected - for code of main (parent) or child class $result = $this->get_sortable_columns() : array;
ReviewsListTable::get_sortable_columns() ReviewsListTable::get sortable columns code WC 8.7.0
protected function get_sortable_columns() : array { return [ 'author' => 'comment_author', 'response' => 'comment_post_ID', 'date' => 'comment_date_gmt', 'type' => 'comment_type', 'rating' => 'rating', ]; }