!!! 5 - nav_haml = Haml::Engine.new(File.read(File.dirname(__FILE__) + '/_nav.haml')) - nav = nav_haml.render - css_haml = Haml::Engine.new(File.read(File.dirname(__FILE__) + '/_css.haml')) - css = css_haml.render %html %head %title Flapjack - Contact: #{@contact.name} = css %body %div#wrapper = nav %h1= @contact.name - if @entities && !@entities.empty? %table %tr %th Entity name %th Checks %th Media - @entities.sort_by(&:name).each do |entity| %tr %td %p= entity.name %td - checks = entity.check_list - if !checks.empty? - checks.each do |check| - link = "/check?entity=#{entity.name}&check=#{check}" %p %a(title='check status' href=link) #{check} - else %p No checks %td - if @contact.media && !@contact.media.empty? %ul - @contact.media.each_pair do |mk, mv| - if 'pagerduty'.eql?(mk) %li= "PagerDuty: " %ul - @pagerduty_credentials.each_pair do |pk, pv| - if 'password'.eql?(pk) %li= "#{pk}: ..." - else %li= "#{pk}: #{pv}" - else %li= "#{mk.capitalize}: #{mv}" - else %p No media - else %p No entities