1 <md-dialog class="mohSound-dialog" aria-label="New MohSound">
2 <form name="mohSoundForm" class="md-inline-form" novalidate>
3 <md-toolbar class="md-accent md-hue-2">
5 class="md-toolbar-tools"
7 layout-align="space-between center"
9 <span class="title">{{ vm.title | translate }}</span>
10 <md-button class="md-icon-button" ng-click="vm.closeDialog()">
12 md-font-icon="icon-close"
13 aria-label="Close dialog"
19 <md-dialog-content ms-scroll>
20 <div class="error-list">
22 ng-repeat="error in vm.errors"
25 layout-align="space-between center"
28 <span class="message">{{error.message}}</span>
29 <span class="type">({{error.type}})</span>
31 <md-button class="md-icon-button">
33 md-font-icon="icon-alert-box"
34 aria-label="alert error"
40 <md-input-container class="md-block">
41 <label translate="VOICE.FILE">File</label>
42 <md-select name="id" ng-model="vm.mohSound.id" autofocus>
45 ng-repeat="id in vm.sounds"
46 ng-disabled="id.canSelect === false"
47 >{{ id.name }}</md-option
51 ng-messages="mohSoundForm['id'].$error"
52 ng-show="mohSoundForm['id'].$touched"
55 <div ng-message="required">
56 <span translate="VOICE.ERRORS.FILE_REQUIRED"
57 >File field is required</span
63 <div class="error-list">
65 ng-repeat="error in vm.errors"
68 layout-align="space-between center"
71 <span class="message">{{error.message}}</span>
72 <span class="type">({{error.type}})</span>
74 <md-button class="md-icon-button">
76 md-font-icon="icon-alert-box"
77 aria-label="alert error"
87 layout-align="space-between center"
88 ng-if="!vm.crudPermissions.readOnly"
90 <div layout="row" layout-align="start center">
93 ng-if="vm.crudPermissions.canEdit && !vm.newMohSound"
94 ng-click="vm.saveMohSound()"
95 class="send-button md-accent md-raised"
96 ng-disabled="mohSoundForm.$invalid || mohSoundForm.$pristine"
98 translate="VOICE.SAVE"
99 translate-attr-aria-label="VOICE.SAVE"
106 ng-if="vm.crudPermissions.canEdit && vm.newMohSound"
107 ng-click="vm.addNewMohSound()"
108 class="send-button md-accent md-raised"
109 ng-disabled="mohSoundForm.$invalid"
111 translate="VOICE.ADD_MOHSOUND"
112 translate-attr-aria-label="VOICE.ADD_MOHSOUND"
119 class="md-icon-button"
120 ng-if="vm.crudPermissions.canDelete && !vm.newMohSound"
121 ng-click="vm.deleteMohSound($event)"
124 translate-attr-aria-label="VOICE.DELETE"
126 <md-icon md-font-icon="icon-delete"></md-icon>
127 <md-tooltip><span translate="VOICE.DELETE">DELETE</span></md-tooltip>