Sha256: 90803af7f5f8aa856a871f5ded4287e83b18f052d4a9d058316ff30a18226325
Contents?: true
Size: 513 Bytes
Versions: 1
Compression:
Stored size: 513 Bytes
Contents
module Zvents class SearchResults require 'zvents/event' require 'zvents/venue' include Virtus.model attribute :events, Array[Event] attribute :venues, Array[Venue] def events unless @venues_initialized @events.each do |event| event.venue = @venues.detect{|venue| venue.id == event.venue_id} end end @venues_initialized = true @events end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
zvents-0.1.0 | lib/zvents/search_results.rb |