1
0
mirror of synced 2026-08-06 10:17:13 +00:00

FEATURE: in:unsolved filter

This commit is contained in:
Sam
2015-06-23 12:56:22 +10:00
parent 7ebd56665b
commit 8011731aa0
+10
View File
@@ -201,6 +201,16 @@ after_initialize do
)")
end
Search.advanced_filter(/in:unsolved/) do |posts|
posts.where("topics.id NOT IN (
SELECT tc.topic_id
FROM topic_custom_fields tc
WHERE tc.name = 'accepted_answer_post_id' AND
tc.value IS NOT NULL
)")
end
end
require_dependency 'topic_list_item_serializer'