diff --git a/modules/backend/widgets/Lists.php b/modules/backend/widgets/Lists.php index f1946d747..59fc31194 100644 --- a/modules/backend/widgets/Lists.php +++ b/modules/backend/widgets/Lists.php @@ -1517,7 +1517,7 @@ class Lists extends WidgetBase /** * Returns the current sorting column, saved in a session or cached. */ - protected function getSortColumn() + public function getSortColumn() { if (!$this->isSortable()) { return false; @@ -1564,6 +1564,14 @@ class Lists extends WidgetBase return $this->sortColumn; } + /* + * Returns the current sort direction or default of 'asc' + */ + public function getSortDirection() + { + return $this->sortDirection ?? 'asc'; + } + /** * Returns true if the column can be sorted. */