feat: add push notification when SLA missed (#9078)
* feat: add push notification when SLA missed * chore: sent notification only for inbox members * feat: add conv particpants+admins to SLA notification list * chore: add spec to ensure notification is created * chore: refactor to multiple alerts for SLA conditions * chore: add sla_policy as secondary_actor in notification
This commit is contained in:
@@ -22,4 +22,14 @@ class SlaPolicy < ApplicationRecord
|
||||
validates :name, presence: true
|
||||
|
||||
has_many :conversations, dependent: :nullify
|
||||
|
||||
def push_event_data
|
||||
{
|
||||
id: id,
|
||||
name: name,
|
||||
frt: first_response_time_threshold,
|
||||
nrt: next_response_time_threshold,
|
||||
rt: resolution_time_threshold
|
||||
}
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user