> which means it could live in a helper

That is:

```ruby
class Event
  def started_at
    [event_start_date, event_start_time]
  end
end

class ParticipantsController
  def show
    @events_and_contacts = events_and_contact_links
  end

  def events_and_contact_links
    @participants.contact_links.collect # etc
  end
end

module ListHelper
  def sort_by_start(list)
    list.sort_by { |x| x.started_at.map { |dt| dt || Unspecified } }
  end

  class Unspecified
    def self.<=>(other); 1; end
  end
end
```


and in your view:

```haml
- sort_by_start(@events_and_contacts).each do |o|
  # ...
```