Commit 56b3967dbd8bbe2af3edad3844441c35a9022e3d

Authored by Nathan Broadbent
1 parent 18b3bb28
Exists in master and in 1 other branch production

Added user attributes to notification email

app/views/mailer/err_notification.html.haml
... ... @@ -40,6 +40,14 @@
40 40 %p.monospace
41 41 = user_agent_graph(@notice.problem)
42 42 %br
  43 + - if @notice.user_attributes.present?
  44 + %p.heading USER:
  45 + %table
  46 + - @notice.user_attributes.each do |key, value|
  47 + %tr
  48 + %td(style="text-align: right; padding-right: 10px; color: #6a6a6a;")= key.to_s.titleize + ":"
  49 + %td= auto_link(value.to_s)
  50 + %br
43 51 %p.heading FULL BACKTRACE:
44 52 - @notice.backtrace_lines.each do |line|
45 53 %p.backtrace
... ...
app/views/mailer/err_notification.text.erb
... ... @@ -29,6 +29,15 @@ BROWSER:
29 29 <%= @notice.user_agent_string %>
30 30  
31 31  
  32 +<%- if @notice.user_attributes.present? %>
  33 +USER:
  34 +
  35 +<%- @notice.user_attributes.each do |key, value| %>
  36 +<%= key.to_s.titleize %>: <%= value.to_s %>
  37 +<%- end %>
  38 +
  39 +<%- end %>
  40 +
32 41 BACKTRACE:
33 42  
34 43 <% @notice.backtrace_lines.each do |line| %>
... ...