alerting: images in alert notifications is now optional

its now possible to turn of image uploading in alert notifications
for those who operate on very sensitive data.

closes #7419
This commit is contained in:
bergquist
2017-02-13 12:43:12 +01:00
parent f14e25612e
commit bd010289b2
7 changed files with 70 additions and 56 deletions

View File

@@ -17,6 +17,7 @@ export class AlertNotificationEditCtrl {
settings: {
httpMethod: 'POST',
autoResolve: true,
uploadImage: true,
},
isDefault: false
};
@@ -32,7 +33,7 @@ export class AlertNotificationEditCtrl {
}
if (!this.$routeParams.id) {
return this.model;
return _.defaults(this.model, this.defaults);
}
return this.backendSrv.get(`/api/alert-notifications/${this.$routeParams.id}`).then(result => {

View File

@@ -24,15 +24,20 @@
</select>
</div>
</div>
<div class="gf-form">
<gf-form-switch
class="gf-form"
label="Send on all alerts"
label-class="width-12"
checked="ctrl.model.isDefault"
tooltip="Use this notification for all alerts">
</gf-form-switch>
</div>
<gf-form-switch
class="gf-form"
label="Send on all alerts"
label-class="width-12"
checked="ctrl.model.isDefault"
tooltip="Use this notification for all alerts">
</gf-form-switch>
<gf-form-switch
class="gf-form"
label="Include image"
label-class="width-12"
checked="ctrl.model.settings.uploadImage"
tooltip="Captures an image and include it in the notification">
</gf-form-switch>
</div>
<div class="gf-form-group" ng-include src="ctrl.notifierTemplateId">