Skip to content
This repository has been archived by the owner on Nov 16, 2017. It is now read-only.

Commit

Permalink
sorting
Browse files Browse the repository at this point in the history
  • Loading branch information
sdague committed May 5, 2008
1 parent 7c824f3 commit 555b4e1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/helpers/invite_helper.rb
Expand Up @@ -38,7 +38,7 @@ def na_number()
end

def number_by_state(state)
rsvps = Rsvp.find(:all, :conditions => ["state = ?", state], :order => "email")
rsvps = Rsvp.find(:all, :conditions => ["state = ?", state]).sort_by {|s| s.person.email}
count = 0
rsvps.each do |r|
count += (r.num or 1)
Expand All @@ -47,7 +47,7 @@ def number_by_state(state)
end

def list_by_state(state)
Rsvp.find(:all, :conditions => ["state = ?", state], :order => "email")
Rsvp.find(:all, :conditions => ["state = ?", state]).sort_by {|s| s.person.email}
end

def format_invitee(r)
Expand Down

0 comments on commit 555b4e1

Please sign in to comment.