Skip to content

Commit b2f4575

Browse files
committed
Add cumulativeLikes sort field to article list view
1 parent ba7b78e commit b2f4575

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

wcfsetup/install/files/lib/system/listView/user/ArticleListView.class.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,11 @@ public function __construct()
3939
new ListViewSortField('title', 'wcf.global.title', 'title'),
4040
new ListViewSortField('views', 'wcf.article.sortField.views'),
4141
]);
42+
if (\MODULE_LIKE) {
43+
$this->addAvailableSortFields([
44+
new ListViewSortField('cumulativeLikes', 'wcf.like.cumulativeLikes'),
45+
]);
46+
}
4247
$this->addAvailableFilters([
4348
$this->getTitleFilter(),
4449
new TextFilter('username', 'wcf.user.username'),

0 commit comments

Comments
 (0)