aboutsummaryrefslogtreecommitdiff
path: root/views/_alerts_table_alert_summary.haml
blob: 3b03cb0f6aed1a1bcd39a34fae258e111b364cd7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
- alert = alerts_table_alert_summary if defined? alerts_table_alert_summary
- row_class = (row_class || []) + [ cycle(nil, "hilight"), alert.raised? && "triggered", alert.acknowledged? && "acknowledged", alert.level]
%tr{ :class => row_class, :id => ["tr", "summary", alert.id] }
  %td
    %input{ :type => "checkbox", :id => "alerts[#{alert.id}]", :name => "alerts[#{alert.id}]", :class => 'alert' }
  %td
    %label{ :for => "alerts[#{alert.id}]" }
      %strong= alert.subject
      = alert.summary
    %a{ :id => ["a","detail", alert.id], | 
        :href => "/alert/#{alert.id}",   |
        :onclick => "fetchDetail('#{alert.id}'); return false;"} 
    - if alert.suppressed?
      (suppressed)
      Details ↓
  %td= (alert.raised_at || alert.cleared_at || Time.now).to_s_relative