Qualify searchable @text@ column to prevent exception thrown when :content association is not eargerly fetched by AR (#9308).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@7568 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Etienne Massip 2011-10-03 20:17:01 +00:00
parent ac6aaf3f67
commit 0aa63a13bc
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ class WikiPage < ActiveRecord::Base
:datetime => :created_on,
:url => Proc.new {|o| {:controller => 'wiki', :action => 'show', :project_id => o.wiki.project, :id => o.title}}
acts_as_searchable :columns => ['title', 'text'],
acts_as_searchable :columns => ['title', "#{WikiContent.table_name}.text"],
:include => [{:wiki => :project}, :content],
:permission => :view_wiki_pages,
:project_key => "#{Wiki.table_name}.project_id"