mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
2076dca63f
Ticket #1874 - Firebird adapter r3107@asus: jeremy | 2005-11-16 00:06:14 -0800 quote column aliases r3108@asus: jeremy | 2005-11-16 00:08:12 -0800 quote columns in construct_conditions_from_arguments. update sequence_name docs. introduce prefetched primary keys. r3109@asus: jeremy | 2005-11-16 00:09:08 -0800 double-quote rather than single-quote sqlite columns r3110@asus: jeremy | 2005-11-16 00:09:56 -0800 quote column names and use attribute_condition in validates_uniqueness_of r3111@asus: jeremy | 2005-11-16 00:12:24 -0800 Use QUOTED_TYPE constant in tests r3112@asus: jeremy | 2005-11-16 00:13:28 -0800 restrict test_inserts_with_pre_and_suffix to those adapters which support migrations r3113@asus: jeremy | 2005-11-16 00:14:09 -0800 Use QUOTED_TYPE constant in tests r3114@asus: jeremy | 2005-11-16 00:14:30 -0800 Use QUOTED_TYPE constant in tests git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3051 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
23 lines
No EOL
404 B
Ruby
23 lines
No EOL
404 B
Ruby
class Comment < ActiveRecord::Base
|
|
belongs_to :post
|
|
|
|
def self.what_are_you
|
|
'a comment...'
|
|
end
|
|
|
|
def self.search_by_type(q)
|
|
self.find(:all, :conditions => ["#{QUOTED_TYPE} = ?", q])
|
|
end
|
|
end
|
|
|
|
class SpecialComment < Comment
|
|
def self.what_are_you
|
|
'a special comment...'
|
|
end
|
|
end
|
|
|
|
class VerySpecialComment < Comment
|
|
def self.what_are_you
|
|
'a very special comment...'
|
|
end
|
|
end |