feat(alerting): new design for alert tab with sidemenu

This commit is contained in:
Torkel Ödegaard
2016-07-31 09:31:32 +02:00
parent 2b276d5cd1
commit 3b69c8f687
10 changed files with 192 additions and 153 deletions

View File

@@ -38,6 +38,10 @@ func (n *RootNotifier) Notify(context *EvalContext) {
return
}
if len(notifiers) == 0 {
return
}
err = n.uploadImage(context)
if err != nil {
n.log.Error("Failed to upload alert panel image", "error", err)
@@ -84,8 +88,11 @@ func (n *RootNotifier) uploadImage(context *EvalContext) error {
}
func (n *RootNotifier) getNotifiers(orgId int64, notificationIds []int64) ([]Notifier, error) {
query := &m.GetAlertNotificationsQuery{OrgId: orgId, Ids: notificationIds}
if len(notificationIds) == 0 {
return []Notifier{}, nil
}
query := &m.GetAlertNotificationsQuery{OrgId: orgId, Ids: notificationIds}
if err := bus.Dispatch(query); err != nil {
return nil, err
}