dedicated screen for inspecting user emails
This commit is contained in:
parent
d7fff61d5d
commit
f298d2c2ba
5 changed files with 137 additions and 3 deletions
12
app/helpers/email_helper.rb
Normal file
12
app/helpers/email_helper.rb
Normal file
|
@ -0,0 +1,12 @@
|
|||
module EmailHelper
|
||||
def event_color_code(email_events)
|
||||
unique_events = email_events.map(&:event)
|
||||
if unique_events.include?('delivered')
|
||||
return 'email-sent'
|
||||
elsif unique_events.include?('blocked') || unique_events.include?('hardBounces')
|
||||
return 'email-blocked'
|
||||
else
|
||||
return ''
|
||||
end
|
||||
end
|
||||
end
|
Loading…
Add table
Add a link
Reference in a new issue