1 <form ng-submit="ok(copy_alert)" role="form">
2 <div class="modal-header">
3 <button type="button" class="close" ng-click="cancel()"
4 aria-hidden="true">×</button>
5 <h4 class="modal-title">[% l('New Item Alert') %]</h4>
7 <div class="modal-body">
9 <div class="col-md-6 form-inline">
10 <label for="copy-alert-type-selector"> [% l('Type') %]</label>
11 <select id="copy-alert-type-selector" class="form-control"
12 ng-model="copy_alert.alert_type"
13 ng-options="at.id() as at.name() for at in alert_types | orderBy:'name()'">
16 <div class="col-md-3">
18 <input type="checkbox" ng-model="copy_alert.temp"/>
23 <div class="row pad-vert">
24 <div class="col-md-12">
25 <textarea class="form-control"
26 ng-model="copy_alert.note" placeholder="[% l('Alert...') %]">
31 <div class="modal-footer">
33 <div class="col-md-10 pull-right">
34 <input type="submit" class="btn btn-primary" value="[% l('OK') %]"/>
35 <button class="btn btn-warning" ng-click="cancel($event)">[% l('Cancel') %]</button>
39 <div class="row pad-vert" ng-if="copy_alert_list.length > 0">
40 <div class="col-md-12">
42 <div class="col-md-12">
47 <div class="col-md-12">
48 <h4 class="pull-left">[% l('Existing Item Alerts') %]</h4>
54 <div class="row" ng-repeat="a in copy_alert_list | orderBy:'id()'" ng-init="temp = (a.temp() == 't'); note = a.note(); acked = (a.ack_time() !== null); alert_type = a.alert_type().id()">
55 <div class="col-md-12">
57 <div class="col-md-6 form-inline">
58 <label for="copy-alert-type-select-{{a.id()}}">[% l('Type') %]</label>
59 <select id="copy-alert-type-select-{{a.id()}}" class="form-control"
61 ng-change="a.alert_type(alert_type) && a.ischanged(1)"
62 ng-options="at.id() as at.name() for at in alert_types | orderBy:'name()'">
65 <div class="col-md-3">
67 <input type="checkbox" ng-model="temp" ng-change="a.temp(temp ? 't' : 'f') && a.ischanged(1)" ng-disabled="acked"/>
71 <div class="col-md-3">
73 <input type="checkbox" ng-model="acked" ng-change="(acked ? a.ack_time('now') : a.ack_time(null)) && a.ischanged(1)"/>
78 <div class="row pad-vert">
79 <div class="col-md-12">
80 <textarea class="form-control" ng-change="a.note(note) && a.ischanged(1)"
81 ng-model="note" placeholder="[% l('Alert...') %]" ng-disabled="acked">
86 <div class="col-md-12">