Class: Workarea::Insights::ReleaseReminder
- Defined in:
- app/models/workarea/insights/release_reminder.rb
Class Method Summary collapse
Methods inherited from Base
beginning_of_last_month, current, end_of_last_month, generate_monthly!, generate_weekly!, #include?, #slug
Methods included from ApplicationDocument
Methods included from Sidekiq::Callbacks
add_worker, assert_valid_config!, async, caching_classes?, disable, enable, inline, #run_callbacks, workers, workers_list
Methods included from Mongoid::Document
Class Method Details
.dashboards ⇒ Object
5 6 7 |
# File 'app/models/workarea/insights/release_reminder.rb', line 5 def dashboards %w(store) end |
.generate_daily! ⇒ Object
9 10 11 12 13 14 15 16 |
# File 'app/models/workarea/insights/release_reminder.rb', line 9 def generate_daily! releases = Release .tomorrow .soonest .limit(Workarea.config.insights_releases_list_max_results) create!(results: releases.map { |r| { release_id: r.id } }) if releases.present? end |