Alerting: Fixed bad background color for default notifications in alert tab (#22660)

* fix: remove harcoded bg color

* added default info

Co-authored-by: Torkel Ödegaard <torkel@grafana.com>
This commit is contained in:
Miguel Carvajal 2020-03-10 11:24:23 +01:00 committed by GitHub
parent 4e25823705
commit 6979b44592
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -237,7 +237,6 @@ export class AlertTabCtrl {
for (const notification of this.notifications) {
if (notification.isDefault) {
notification.iconClass = this.getNotificationIcon(notification.type);
notification.bgColor = '#00678b';
this.alertNotifications.push(notification);
}
}

View File

@ -139,8 +139,9 @@
<span class="gf-form-label width-8">Send to</span>
</div>
<div class="gf-form" ng-repeat="nc in ctrl.alertNotifications">
<span class="gf-form-label" ng-style="{'background-color': nc.bgColor }">
<i class="{{nc.iconClass}}"></i>&nbsp;{{nc.name}}&nbsp;
<span class="gf-form-label">
<i class="{{nc.iconClass}}"></i>
&nbsp;{{nc.name}}&nbsp;<span ng-if="nc.isDefault">(default)</span>
<i class="fa fa-remove pointer muted" ng-click="ctrl.removeNotification(nc)" ng-if="nc.isDefault === false"></i>
</span>
</div>