]> source.dussan.org Git - redmine.git/commitdiff
Preload wiki page content for search results.
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Fri, 26 Dec 2014 12:23:05 +0000 (12:23 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Fri, 26 Dec 2014 12:23:05 +0000 (12:23 +0000)
git-svn-id: http://svn.redmine.org/redmine/trunk@13814 e93f8b46-1217-0410-a6f0-8f06a7374b81

app/models/wiki_page.rb

index 8d81bce7efdec6327b6e7ee08a2931cf595c784d..32d04335522bfa5d0ae2e2ba9b217a83b2f73131 100644 (file)
@@ -34,7 +34,7 @@ class WikiPage < ActiveRecord::Base
 
   acts_as_searchable :columns => ['title', "#{WikiContent.table_name}.text"],
                      :scope => joins(:content, {:wiki => :project}),
-                     :preload => {:wiki => :project},
+                     :preload => [:content, {:wiki => :project}],
                      :permission => :view_wiki_pages,
                      :project_key => "#{Wiki.table_name}.project_id"