1
0
Fork 0
mirror of https://github.com/rails/rails.git synced 2022-11-09 12:12:34 -05:00
rails--rails/activerecord/test/models/subscriber.rb

12 lines
265 B
Ruby
Raw Normal View History

# frozen_string_literal: true
class Subscriber < ActiveRecord::Base
self.primary_key = "nick"
has_many :subscriptions
2016-08-06 13:37:57 -04:00
has_many :books, through: :subscriptions
has_many :published_books, through: :subscriptions
end
class SpecialSubscriber < Subscriber
end