diff options
author | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2007-09-27 17:28:22 +0000 |
---|---|---|
committer | Jean-Philippe Lang <jp_lang@yahoo.fr> | 2007-09-27 17:28:22 +0000 |
commit | a96421019f3a813b93798e4ec8099edd09f8a661 (patch) | |
tree | 102827aea563063b29ae21800bfff88fb16550f9 /app/models/issue.rb | |
parent | d723bea502faedb218f929b40849935d61c577e2 (diff) | |
download | redmine-a96421019f3a813b93798e4ec8099edd09f8a661.tar.gz redmine-a96421019f3a813b93798e4ec8099edd09f8a661.zip |
Search engines now supports pagination.
Results are sorted in reverse chronological order.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@766 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app/models/issue.rb')
-rw-r--r-- | app/models/issue.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/app/models/issue.rb b/app/models/issue.rb index 23cc71f7c..7d214de8a 100644 --- a/app/models/issue.rb +++ b/app/models/issue.rb @@ -36,8 +36,9 @@ class Issue < ActiveRecord::Base has_many :relations_to, :class_name => 'IssueRelation', :foreign_key => 'issue_to_id', :dependent => :delete_all acts_as_watchable + acts_as_searchable :columns => ['subject', 'description'], :with => {:journal => :issue} acts_as_event :title => Proc.new {|o| "#{o.tracker.name} ##{o.id}: #{o.subject}"}, - :url => Proc.new {|o| {:controller => 'issues', :action => 'show', :id => o.id}} + :url => Proc.new {|o| {:controller => 'issues', :action => 'show', :id => o.id}} validates_presence_of :subject, :description, :priority, :tracker, :author, :status validates_length_of :subject, :maximum => 255 |