1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2025-01-29 18:52:22 +01:00

reservation reminder: tested and fixed

This commit is contained in:
Sylvain 2016-08-23 10:10:58 +02:00
parent cc1d6e4f21
commit ea7410a738

View File

@ -12,7 +12,7 @@ class ReservationReminderWorker
starting = Time.now.beginning_of_hour + delay
ending = starting + 1.hour
Reservation.includes(:slots).where('slots.start_at >= ? AND slots.start_at <= ?', starting, ending).each do |r|
Reservation.joins(:slots).where('slots.start_at >= ? AND slots.start_at <= ?', starting, ending).each do |r|
NotificationCenter.call type: 'notify_member_reservation_reminder',
receiver: r.user,
attached_object: r