Module: WithReminders::ClassMethods
- Defined in:
- app/models/concerns/with_reminders.rb
Instance Method Summary collapse
- #remindable ⇒ Object
-
#reminder_frequency ⇒ Object
The frequency of reminders, expressed in days.
Instance Method Details
#remindable ⇒ Object
63 64 65 |
# File 'app/models/concerns/with_reminders.rb', line 63 def remindable where('accepts_reminders and (last_submission_date < ? or last_submission_date is null)', reminder_frequency.days.ago) end |
#reminder_frequency ⇒ Object
The frequency of reminders, expressed in days
68 69 70 |
# File 'app/models/concerns/with_reminders.rb', line 68 def reminder_frequency Rails.configuration.reminder_frequency end |