@areas.group_by(&:responsibility).each do |responsibility, areas|
  <p><%=h responsibility.name %></p>
  <% areas.each do |area| %>
  ...

I see that #group_by iterates through my list of areas, splitting them into
sets according to which ones have the same responsibility.

I would like to sort the results of that list.

It seems to me that group_by returns an OrderedHash.  How to I sort those
results prior to passing the |responsibility, areas| pairs?

--wpd

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to