| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116 |
- <div class="editor-row">
- <div class="gf-form-group section" >
- <h5 class="section-heading">Alert Query</h5>
- <div class="gf-form-inline">
- <div class="gf-form">
- <query-part-editor
- class="gf-form-label query-part"
- part="ctrl.query"
- part-updated="ctrl.queryUpdated()">
- </query-part-editor>
- </div>
- <div class="gf-form">
- <span class="gf-form-label">Transform using</span>
- <div class="gf-form-select-wrapper">
- <select class="gf-form-input"
- ng-model="ctrl.alert.transform.type"
- ng-options="f.type as f.text for f in ctrl.transforms"
- ng-change="ctrl.transformChanged()"
- >
- </select>
- </div>
- </div>
- <div class="gf-form" ng-if="ctrl.transformDef.type === 'aggregation'">
- <span class="gf-form-label">Method</span>
- <div class="gf-form-select-wrapper">
- <select class="gf-form-input"
- ng-model="ctrl.alert.transform.method"
- ng-options="f for f in ctrl.aggregators">
- </select>
- </div>
- </div>
- <div class="gf-form" ng-if="ctrl.transformDef.type === 'forecast'">
- <span class="gf-form-label">Timespan</span>
- <input class="gf-form-input max-width-5" type="text" ng-model="ctrl.alert.transform.timespan" ng-change="ctrl.ruleUpdated()"></input>
- </div>
- </div>
- </div>
- <div class="gf-form-group section">
- <h5 class="section-heading">Levels</h5>
- <div class="gf-form-inline">
- <div class="gf-form">
- <span class="gf-form-label">
- <i class="icon-gf icon-gf-warn alert-icon-warn"></i>
- Warn if
- </span>
- <metric-segment-model property="ctrl.alert.warning.op" options="ctrl.levelOpList" custom="false" css-class="query-segment-operator"></metric-segment-model>
- <input class="gf-form-input max-width-7" type="number" ng-model="ctrl.alert.warnLevel" ng-change="ctrl.thresholdsUpdated()"></input>
- </div>
- <div class="gf-form">
- <span class="gf-form-label">
- <i class="icon-gf icon-gf-warn alert-icon-critical"></i>
- Critcal if
- </span>
- <metric-segment-model property="ctrl.alert.critical.op" options="ctrl.levelOpList" custom="false" css-class="query-segment-operator"></metric-segment-model>
- <input class="gf-form-input max-width-7" type="number" ng-model="ctrl.alert.critLevel" ng-change="ctrl.thresholdsUpdated()"></input>
- </div>
- </div>
- </div>
- </div>
- <div class="editor-row">
- <div class="gf-form-group section">
- <h5 class="section-heading">Execution</h5>
- <div class="gf-form-inline">
- <div class="gf-form">
- <span class="gf-form-label">Scheduler</span>
- <div class="gf-form-select-wrapper">
- <select class="gf-form-input"
- ng-model="ctrl.alert.scheduler"
- ng-options="f.value as f.text for f in ctrl.schedulers">
- </select>
- </div>
- </div>
- <div class="gf-form">
- <span class="gf-form-label">Evaluate every</span>
- <input class="gf-form-input max-width-7" type="text" ng-model="ctrl.alert.frequency"></input>
- </div>
- </div>
- </div>
- <div class="gf-form-group section">
- <h5 class="section-heading">Notifications</h5>
- <div class="gf-form-inline">
- <div class="gf-form">
- <span class="gf-form-label">Groups</span>
- <bootstrap-tagsinput ng-model="ctrl.alert.notify" tagclass="label label-tag" placeholder="add tags">
- </bootstrap-tagsinput>
- </div>
- </div>
- </div>
- </div>
- <div class="gf-form-group section">
- <h5 class="section-heading">Information</h5>
- <div class="gf-form">
- <span class="gf-form-label width-10">Alert name</span>
- <input type="text" class="gf-form-input width-22" ng-model="ctrl.panel.alerting.name">
- </div>
- <div class="gf-form-inline">
- <div class="gf-form">
- <span class="gf-form-label width-10" style="margin-top: -73px;">Alert description</span>
- </div>
- <div class="gf-form">
- <textarea rows="5" ng-model="ctrl.panel.alerting.description" class="gf-form-input width-22"></textarea>
- </div>
- </div>
- </div>
- <div class="editor-row">
- <div class="gf-form-button-row">
- <button class="btn btn-danger" ng-click="ctrl.delete()" ng-show="ctrl.alert.enabled">Delete</button>
- <button class="btn btn-success" ng-click="ctrl.enable()" ng-hide="ctrl.alert.enabled">Enable</button>
- <button class="btn btn-secondary" ng-click="ctrl.disable()" ng-show="ctrl.alert.enabled">Disable</button>
- </div>
- </div>
|