Displaying 1 result from an estimated 1 matches for "last_reply".
Did you mean:
fast_reply
2006 May 26
0
Paginate include => :last and order by value
...does it seem like I''m having so much trouble with this?
I created a topics table, and a replies table. In my Topic model I used
the following lines of code:
has_many :replies
has_one :first_reply, :class_name => ''Reply'', :order => "created_on"
has_one :last_reply, :class_name => ''Reply'', :order => "created_on DESC"
Thought I would be good at this point to paginate like so, where the
created_on value is in the replies table:
@topic_pages, @topics = paginate :topics, :per_page => 10, :include =>
:last_reply, :order...