Hi <%= @alert.medium.contact.name %>

Monitoring has detected the following:

<% check = @alert.check -%> <% summary = @alert.summary -%> <% unless summary.nil? || summary.empty? -%> <% end %> <% details = @alert.details -%> <% unless details.nil? || details.empty? -%> <% end %> <% time = @alert.time -%> <% unless time.nil? -%> <% end %> <% condition_duration = @alert.condition_duration -%> <% unless condition_duration.nil? || (condition_duration <= 40.0) -%> <% end %> <% unless @alert.last_state.nil? -%> <% end %> <% last_summary = @alert.last_summary -%> <% unless last_summary.nil? || last_summary.empty? -%> <% end %>
Check <%= check.name %>
State <%= @alert.state_title_case %>
Summary <%= summary %>
Details <%= details %>
Time <%= Time.at(time.to_i).to_s %>
Duration <%= ChronicDuration.output(condition_duration, :keep_zero => true) || '0 secs' %>
Previous State <%= @alert.last_state_title_case %>
Previous Summary <%= last_summary %>

Cheers,
Flapjack