5cf30e469c954a764ddd6a52ec683099bab53782
[motion-next.git] /
1 <md-dialog
2   class="openchannelAccount-dialog"
3   aria-label="New OpenchannelAccount"
4 >
5   <form name="openchannelAccountFormApp" class="md-inline-form" novalidate>
6     <md-toolbar class="md-accent md-hue-2">
7       <div
8         class="md-toolbar-tools"
9         layout="row"
10         layout-align="space-between center"
11       >
12         <span class="title">{{ vm.title | translate }}</span>
13         <md-button class="md-icon-button" ng-click="vm.closeDialog()">
14           <md-icon
15             md-font-icon="icon-close"
16             aria-label="Close dialog"
17           ></md-icon>
18         </md-button>
19       </div>
20     </md-toolbar>
21
22     <md-dialog-content ms-scroll>
23       <div class="error-list">
24         <div
25           ng-repeat="error in vm.errors"
26           class="error"
27           layout="row"
28           layout-align="space-between center"
29         >
30           <div>
31             <span class="message">{{error.message}}</span>
32             <span class="type">({{error.type}})</span>
33           </div>
34           <md-button class="md-icon-button">
35             <md-icon
36               md-font-icon="icon-alert-box"
37               aria-label="alert error"
38               class="s16"
39             ></md-icon>
40           </md-button>
41         </div>
42       </div>
43       <md-input-container class="md-block">
44         <label translate="OPENCHANNEL.PRIORITY">Priority</label>
45         <input
46           type="number"
47           name="priority"
48           ng-model="vm.gotop.priority"
49           min="0"
50           ng-required="true"
51           autofocus
52           ng-disabled="!vm.crudPermissions.canEdit"
53         />
54
55         <div
56           ng-messages="openchannelAccountFormApp['priority'].$error"
57           ng-show="openchannelAccountFormApp['priority'].$touched"
58           role="alert"
59         >
60           <div ng-message="required">
61             <span translate="OPENCHANNEL.ERRORS.PRIORITY_REQUIRED"
62               >Priority field is required</span
63             >
64           </div>
65           <div ng-message="min">
66             <span
67               translate="OPENCHANNEL.ERRORS.PRIORITY_MUST_BE_GREATER_THAN_OR_EQUAL_TO"
68               >Priority must be a valid greater or equal than</span
69             >
70             <span>0</span>
71           </div>
72         </div>
73       </md-input-container>
74
75       <div class="error-list">
76         <div
77           ng-repeat="error in vm.errors"
78           class="error"
79           layout="row"
80           layout-align="space-between center"
81         >
82           <div>
83             <span class="message">{{error.message}}</span>
84             <span class="type">({{error.type}})</span>
85           </div>
86           <md-button class="md-icon-button">
87             <md-icon
88               md-font-icon="icon-alert-box"
89               aria-label="alert error"
90               class="s16"
91             ></md-icon>
92           </md-button>
93         </div>
94       </div>
95     </md-dialog-content>
96
97     <md-dialog-actions layout="row" layout-align="space-between center">
98       <div
99         layout="row"
100         layout-align="start center"
101         ng-if="vm.crudPermissions.canEdit"
102       >
103         <md-button
104           type="submit"
105           ng-click="vm.saveOpenchannelAccountApp()"
106           class="send-button md-accent md-raised"
107           ng-disabled="openchannelAccountFormApp.$invalid || openchannelAccountFormApp.$pristine"
108           aria-label="SAVE"
109           translate="OPENCHANNEL.SAVE"
110           translate-attr-aria-label="OPENCHANNEL.SAVE"
111         >
112           SAVE
113         </md-button>
114       </div>
115     </md-dialog-actions>
116   </form>
117 </md-dialog>