- $counter = array();
- $counter[Alert::TYPE_ALARM]    = 0
- $counter[Alert::TYPE_WARNING]  = 0
- $counter[Alert::TYPE_INFO]     = 0

- foreach($data->data as $alert)
  - $counter[$alert->type] = $alert->eventCounter

.event-reporting-summary
  %ul.unstyled.inline
    %li
      - if (Yii::app()->user->checkAccess('view_alerts'))
        %a(href="#{Yii::app()->createAbsoluteUrl('alert/search',  array('types' => Alert::TYPE_ALARM))}")
          %i.icon-exclamation-sign.alarm.alarm-icon
          = $counter[Alert::TYPE_ALARM]
      - else
        %i.icon-exclamation-sign.alarm.alarm-icon
        = $counter[Alert::TYPE_ALARM]
    %li
      - if (Yii::app()->user->checkAccess('view_alerts'))
        %a(href="#{Yii::app()->createAbsoluteUrl('alert/search',  array('types' => Alert::TYPE_WARNING))}")
          %i.icon-warning-sign.alarm.warning-icon
          = $counter[Alert::TYPE_WARNING]
      -else    
        %i.icon-warning-sign.alarm.warning-icon
        = $counter[Alert::TYPE_WARNING]
    %li
      - if (Yii::app()->user->checkAccess('view_alerts'))
        %a(href="#{Yii::app()->createAbsoluteUrl('alert/search',  array('types' => Alert::TYPE_INFO))}")
          %i.icon-info-sign.alarm.info-icon
          = $counter[Alert::TYPE_INFO]
      - else    
        %i.icon-info-sign.alarm.info-icon
        = $counter[Alert::TYPE_INFO]
