LP#1402797 Separate stock and custom penalty type models
[working/Evergreen.git] / Open-ILS / src / templates / staff / circ / share / t_new_message_dialog.tt2
1 <form ng-submit="ok(args)" role="form">
2     <div class="modal-header">
3       <button type="button" class="close" ng-click="cancel()" 
4         aria-hidden="true">&times;</button>
5       <h4 class="modal-title">[% l('Apply Standing Penalty / Message') %]</h4>
6     </div>
7     <div class="modal-body">
8       <div class="row">
9         <div class="col-md-8">
10           <ul class="nav nav-pills">
11             <!-- 21 == SILENT_NOTE -->
12             <li ng-class="{active : args.penalty == 21}">
13               <a href ng-click="args.penalty=21">[% l('Note') %]</a>
14             </li>
15             <!-- 20 == ALERT_NOTE -->
16             <li ng-class="{active : args.penalty == 20}">
17               <a href ng-click="args.penalty=20">[% l('Alert') %]</a>
18             </li>
19             <!-- 25 == STAFF_CHR -->
20             <li ng-class="{active : args.penalty == 25}">
21               <a href ng-click="args.penalty=25">[% l('Block') %]</a>
22             </li>
23           </ul>
24         </div>
25         <div class="col-md-4 pull-right">
26           <select class="form-control" ng-model="args.custom_penalty">
27             <option disabled="disabled" ng-selected="args.custom_penalty = ''" value="">[% l('Penalty Type') %]</option>
28             <option ng-repeat="penalty in penalties" 
29               ng-selected="args.custom_penalty = penalty.id"
30               value="{{penalty.id()}}">{{penalty.label()}}</option>
31           </select>
32         </div>
33       </div>
34       <div class="form-group row pad-vert">
35         <div class="col-md-12">
36           <textarea class="form-control" 
37             ng-model="args.note" placeholder="[% l('Note...') %]">
38           </textarea>
39         </div>
40       </div>
41     </div>
42     <div class="modal-footer">
43       <input type="submit" class="btn btn-primary" value="[% l('OK') %]"/>
44       <button class="btn btn-warning" ng-click="cancel($event)">[% l('Cancel') %]</button>
45     </div>
46 </form>