mirasvit / module-blog

Magento 2 Blog Extension
https://mirasvit.com/magento-2-extensions/blog.html
Open Software License 3.0
67 stars 48 forks source link

Changing default sort order to `updated_at` #141

Closed bassplayer7 closed 5 years ago

bassplayer7 commented 5 years ago

This method is called on the PostList regardless of other circumstances. Due to the updated_at sort order, the collection leans heavily towards sorting blog posts by date of update – which does not seem right.

The most obvious place where this method is called is here: Block/Post/PostList.php#L215. It seems to me that it should be an if/else there. If that was to be done though, the is_pinned attribute sort would need to be moved a different method.

bassplayer7 commented 5 years ago

@adrok, do you have a minute to review this pull request?

adrok commented 5 years ago

@bassplayer7 sorry for delay