Add preference for report notification e-mails, skip for duplicates (#8559)
If an unresolved report for the same target account already exists, no new notification is generated
This commit is contained in:
parent
a060beee72
commit
c593d6df9c
8 changed files with 36 additions and 2 deletions
|
@ -60,6 +60,10 @@ class Report < ApplicationRecord
|
|||
!action_taken?
|
||||
end
|
||||
|
||||
def unresolved_siblings?
|
||||
Report.where.not(id: id).where(target_account_id: target_account_id).unresolved.exists?
|
||||
end
|
||||
|
||||
def history
|
||||
time_range = created_at..updated_at
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue