Sha256: 1e8e259d4166e57bd6d9cd1ea8977cc862fbf867e9818f020f2f979a2a2983ec
Contents?: true
Size: 286 Bytes
Versions: 16
Compression:
Stored size: 286 Bytes
Contents
class User < ActiveRecord::Base has_many :readings has_many :articles, :through => :readings has_many :comments, :as => :person has_one :first_comment, :as => :person, :class_name => "Comment" def find_custom_articles articles.where("name = ?", "Article One") end end
Version data entries
16 entries across 16 versions & 1 rubygems