instiki/vendor/rails/activerecord/test/models/tagging.rb

10 lines
402 B
Ruby
Raw Normal View History

# test that attr_readonly isn't called on the :taggable polymorphic association
module Taggable
end
2007-01-22 14:43:50 +01:00
class Tagging < ActiveRecord::Base
belongs_to :tag, :include => :tagging
belongs_to :super_tag, :class_name => 'Tag', :foreign_key => 'super_tag_id'
belongs_to :invalid_tag, :class_name => 'Tag', :foreign_key => 'tag_id'
belongs_to :taggable, :polymorphic => true, :counter_cache => true
end