From 7b91da067bd6d63c5f38da223bfb1398feba5de2 Mon Sep 17 00:00:00 2001 From: barisusakli Date: Tue, 18 Apr 2017 14:21:28 -0400 Subject: [PATCH] closes #5602 --- .../language/en-GB/admin/settings/post.json | 2 ++ src/topics/recent.js | 3 ++- src/views/admin/settings/post.tpl | 20 ++++++++++++++++--- 3 files changed, 21 insertions(+), 4 deletions(-) diff --git a/public/language/en-GB/admin/settings/post.json b/public/language/en-GB/admin/settings/post.json index f293e554d9..aca8b39d64 100644 --- a/public/language/en-GB/admin/settings/post.json +++ b/public/language/en-GB/admin/settings/post.json @@ -29,6 +29,8 @@ "unread": "Unread Settings", "unread.cutoff": "Unread cutoff days", "unread.min-track-last": "Minimum posts in topic before tracking last read", + "recent": "Recent Settings", + "recent.categoryFilter.disable": "Disable filtering of topics in ignored categories on the /recent page", "signature": "Signature Settings", "signature.disable": "Disable signatures", "signature.no-links": "Disable links in signatures", diff --git a/src/topics/recent.js b/src/topics/recent.js index dbecd035b4..6801c0095b 100644 --- a/src/topics/recent.js +++ b/src/topics/recent.js @@ -8,6 +8,7 @@ var plugins = require('../plugins'); var privileges = require('../privileges'); var user = require('../user'); var categories = require('../categories'); +var meta = require('../meta'); module.exports = function (Topics) { var terms = { @@ -65,7 +66,7 @@ module.exports = function (Topics) { function (tids, next) { async.parallel({ ignoredCids: function (next) { - if (filter === 'watched') { + if (filter === 'watched' || parseInt(meta.config.disableRecentCategoryFilter, 10) === 1) { return next(null, []); } user.getIgnoredCategories(uid, next); diff --git a/src/views/admin/settings/post.tpl b/src/views/admin/settings/post.tpl index 0eef74390c..18d31c0cdf 100644 --- a/src/views/admin/settings/post.tpl +++ b/src/views/admin/settings/post.tpl @@ -123,9 +123,23 @@
- - -
+ + + + + + + +
+
[[admin/settings/post:recent]]
+
+
+
+ +