Displaying 1 result from an estimated 1 matches for "remaining_line".
2006 Jun 12
2
Getting 1 from children of has_many, Noob question...
The ''Agile Web'' book says that you can iterate over a list of children
as so:
order.line-items.each do |li|
etc...
This is fine when you need then all consecuitvely, but I need to pull
the first one for the top of the page and still list all at the bottom.
So, the question is:
How do I reference the first item (child) directly?
Thanks
Lance F. Squire
--
Posted via