Quantcast
Channel: Ruby on Rails: Display objects by most recent in the view? - Stack Overflow
Viewing all articles
Browse latest Browse all 2

Ruby on Rails: Display objects by most recent in the view?

$
0
0

I have this method at the moment:

<% for comment in @critical_process.review.comments %><div id="comment"><%=h comment.comment %> <br/><span id="comment_email">        By: <%=h comment.user.email%></span></div><% end %>

however I need it to display the comments in order of the most recently updated at the top and work its way down.

Thanks


Viewing all articles
Browse latest Browse all 2

Latest Images

Trending Articles





Latest Images