From ad593e43933d4908c361d5bc23d448ebd931eae6 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Thu, 13 Mar 2014 01:07:52 +0400 Subject: [PATCH] disable headlines grouping for recently read vfeed --- classes/feeds.php | 12 +++++++----- include/functions2.php | 1 + 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/classes/feeds.php b/classes/feeds.php index ea3967911..c90b11d5d 100644 --- a/classes/feeds.php +++ b/classes/feeds.php @@ -248,6 +248,8 @@ class Feeds extends Handler_Protected { false, 0, $include_children); } + $vfeed_group_enabled = get_pref("VFEED_GROUP_BY_FEED") && $feed != -6; + if ($_REQUEST["debug"]) $timing_info = print_checkpoint("H1", $timing_info); $result = $qfh_ret[0]; @@ -421,7 +423,7 @@ class Feeds extends Handler_Protected { if (!get_pref('COMBINED_DISPLAY_MODE')) { - if (get_pref('VFEED_GROUP_BY_FEED')) { + if ($vfeed_group_enabled) { if ($feed_id != $vgroup_last_feed && $line["feed_title"]) { $cur_feed_title = $line["feed_title"]; @@ -472,7 +474,7 @@ class Feeds extends Handler_Protected { $reply['content'] .= ""; - if (!get_pref('VFEED_GROUP_BY_FEED')) { + if (!$vfeed_group_enabled) { if (@$line["feed_title"]) { $rgba = @$rgba_cache[$feed_id]; @@ -491,7 +493,7 @@ class Feeds extends Handler_Protected { $reply['content'] .= $score_pic; - if ($line["feed_title"] && !get_pref('VFEED_GROUP_BY_FEED')) { + if ($line["feed_title"] && !$vfeed_group_enabled) { $reply['content'] .= "hook_render_article_cdm($line); } - if (get_pref('VFEED_GROUP_BY_FEED') && $line["feed_title"]) { + if ($vfeed_group_enabled && $line["feed_title"]) { if ($feed_id != $vgroup_last_feed) { $cur_feed_title = $line["feed_title"]; @@ -592,7 +594,7 @@ class Feeds extends Handler_Protected { $reply['content'] .= ""; - if (!get_pref('VFEED_GROUP_BY_FEED')) { + if (!$vfeed_group_enabled) { if (@$line["feed_title"]) { $rgba = @$rgba_cache[$feed_id]; diff --git a/include/functions2.php b/include/functions2.php index 7c35b22cb..ed0963c46 100644 --- a/include/functions2.php +++ b/include/functions2.php @@ -583,6 +583,7 @@ $query_strategy_part = "unread = false AND last_read IS NOT NULL"; $vfeed_query_part = "ttrss_feeds.title AS feed_title,"; $allow_archived = true; + $ignore_vfeed_group = true; if (!$override_order) $override_order = "last_read DESC";