sacarmonar15
9/22/2017 - 5:20 PM

Meetings report

#Reporte de meetings para un evento.
I18n.locale = :es
 
results  = []
results << ['Fecha', "Hora", "Locacion", "Anfitrion", "Participante"]
 
c = BusinessConference.find(526)
c.business_conference_meetings.where(status: 2).each do |m|
  start = m.start_date
  final = m.end_date
  date = start.strftime("%d/%m/%Y")
  slot = "#{start.strftime('%r')} - #{final.strftime('%r')}"
  participant = m.participant.attendee.full_name
  host        = m.host.attendee.full_name
  results << [date, slot, m.location, "#{m.host.profile_display_name}(#{host})", "#{m.participant.profile_display_name}(#{participant})"]
end