Class: Iro::Alert
- Inherits:
-
ApplicationRecord
- Object
- ActiveRecord::Base
- ApplicationRecord
- Iro::Alert
- Defined in:
- app/models/iro/alert.rb
Constant Summary collapse
- SLEEP_TIME_SECONDS =
Rails.env.production? ? 60 : 15
- DIRECTION_ABOVE =
'ABOVE'- DIRECTION_BELOW =
'BELOW'- STATUS_ACTIVE =
'active'- STATUS_INACTIVE =
'inactive'- STATUSES =
[ 'active', 'inactive' ]
Class Method Summary collapse
Class Method Details
.active ⇒ Object
18 19 20 |
# File 'app/models/iro/alert.rb', line 18 def self.active where( status: STATUS_ACTIVE ) end |
.directions_list ⇒ Object
9 10 11 |
# File 'app/models/iro/alert.rb', line 9 def self.directions_list [ nil, DIRECTION_ABOVE, DIRECTION_BELOW ] end |