model: replace Rails2 "named_scope" to Rails3 "scope"
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@9537 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
@@ -49,7 +49,7 @@ class WikiPage < ActiveRecord::Base
|
||||
before_save :handle_redirects
|
||||
|
||||
# eager load information about last updates, without loading text
|
||||
named_scope :with_updated_on, {
|
||||
scope :with_updated_on, {
|
||||
:select => "#{WikiPage.table_name}.*, #{WikiContent.table_name}.updated_on",
|
||||
:joins => "LEFT JOIN #{WikiContent.table_name} ON #{WikiContent.table_name}.page_id = #{WikiPage.table_name}.id"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user