f82f592536055d8bbb6e34ed374a673440f0d876
[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.TIMES">times</label>
45         <md-select
46           name="times"
47           ng-model="vm.autoreply.times"
48           autofocus
49           required
50           ng-disabled="!vm.crudPermissions.canEdit"
51         >
52           <md-option ng-value="1">One Time</md-option>
53           <md-option ng-value="0">Always</md-option>
54         </md-select>
55         <div
56           ng-messages="openchannelAccountFormApp['times'].$error"
57           ng-show="openchannelAccountFormApp['times'].$touched"
58           role="alert"
59         >
60           <div ng-message="required">
61             <span translate="OPENCHANNEL.ERRORS.TIMES_REQUIRED"
62               >times field is required</span
63             >
64           </div>
65         </div>
66       </md-input-container>
67       <md-input-container class="md-block">
68         <label translate="OPENCHANNEL.TEXT">Text</label>
69         <textarea name="text" ng-model="vm.autoreply.text" required></textarea>
70
71         <div
72           ng-messages="openchannelAccountFormApp['text'].$error"
73           ng-show="openchannelAccountFormApp['text'].$touched"
74           role="alert"
75         >
76           <div ng-message="required">
77             <span translate="OPENCHANNEL.ERRORS.TEXT_REQUIRED"
78               >Text field is required</span
79             >
80           </div>
81         </div>
82       </md-input-container>
83
84       <div class="error-list">
85         <div
86           ng-repeat="error in vm.errors"
87           class="error"
88           layout="row"
89           layout-align="space-between center"
90         >
91           <div>
92             <span class="message">{{error.message}}</span>
93             <span class="type">({{error.type}})</span>
94           </div>
95           <md-button class="md-icon-button">
96             <md-icon
97               md-font-icon="icon-alert-box"
98               aria-label="alert error"
99               class="s16"
100             ></md-icon>
101           </md-button>
102         </div>
103       </div>
104     </md-dialog-content>
105
106     <md-dialog-actions layout="row" layout-align="space-between center">
107       <div
108         layout="row"
109         layout-align="start center"
110         ng-if="vm.crudPermissions.canEdit"
111       >
112         <md-button
113           type="submit"
114           ng-click="vm.saveOpenchannelAccountApp()"
115           class="send-button md-accent md-raised"
116           ng-disabled="openchannelAccountFormApp.$invalid || openchannelAccountFormApp.$pristine"
117           aria-label="SAVE"
118           translate="OPENCHANNEL.SAVE"
119           translate-attr-aria-label="OPENCHANNEL.SAVE"
120         >
121           SAVE
122         </md-button>
123       </div>
124     </md-dialog-actions>
125   </form>
126 </md-dialog>