1 <md-dialog class="sugarcrmAccount-dialog" aria-label="New SugarcrmAccount">
2 <form name="sugarcrmAccountForm" 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="INTEGRATIONS.NAME">Name</label>
45 ng-model="vm.sugarcrmAccount.name"
51 ng-messages="sugarcrmAccountForm['name'].$error"
52 ng-show="sugarcrmAccountForm['name'].$touched"
55 <div ng-message="required">
56 <span translate="INTEGRATIONS.ERRORS.NAME_REQUIRED"
57 >Name field is required</span
62 <md-input-container class="md-block">
63 <label translate="INTEGRATIONS.USERNAME">Username</label>
67 ng-model="vm.sugarcrmAccount.username"
72 ng-messages="sugarcrmAccountForm['username'].$error"
73 ng-show="sugarcrmAccountForm['username'].$touched"
76 <div ng-message="required">
77 <span translate="INTEGRATIONS.ERRORS.USERNAME_REQUIRED"
78 >Username field is required</span
83 <md-input-container class="md-block">
84 <label translate="INTEGRATIONS.URI">Uri</label>
88 ng-model="vm.sugarcrmAccount.remoteUri"
93 ng-messages="sugarcrmAccountForm['remoteUri'].$error"
94 ng-show="sugarcrmAccountForm['remoteUri'].$touched"
97 <div ng-message="required">
98 <span translate="INTEGRATIONS.ERRORS.URI_REQUIRED"
99 >Uri field is required</span
102 <div ng-message="url">
103 <span translate="INTEGRATIONS.ERRORS.URI_MUST_VALID_URL"
104 >Uri must be a valid url http://www.xcally.com</span
108 </md-input-container>
109 <md-input-container class="md-block">
110 <label translate="INTEGRATIONS.PASSWORD">Password</label>
114 ng-model="vm.sugarcrmAccount.password"
115 placeholder="Password"
117 translate-attr-placeholder="INTEGRATIONS.PASSWORD"
120 <div ng-messages="sugarcrmAccountForm['password'].$error" role="alert">
121 <div ng-message="required">
122 <span translate="INTEGRATIONS.ERRORS.PASSWORD_REQUIRED"
123 >Password field is required</span
126 <div ng-message="pattern">
127 <span translate="INTEGRATIONS.ERRORS.SECURE_PASSWORD_PATTERN"
128 >Must contain at least 8 characters, with a minimum of 1 lowercase
129 letter, 1 uppercase letter, 1 numeric character and 1 special
130 character ~!?*@#$%^&-_=+[{]}.</span
134 </md-input-container>
136 <md-input-container class="md-block">
137 <label translate="INTEGRATIONS.MOTIONPROXYADDRESS"
138 >MotionProxyAddress</label
143 ng-model="vm.sugarcrmAccount.serverUrl"
147 <span translate="INTEGRATIONS.HELP.MOTIONPROXYADDRESS"></span>
150 ng-messages="sugarcrmAccountForm['serverUrl'].$error"
151 ng-show="sugarcrmAccountForm['serverUrl'].$touched"
154 <div ng-message="required">
155 <span translate="INTEGRATIONS.ERRORS.MOTIONPROXYADDRESS_REQUIRED"
156 >MotionProxyAddress field is required</span
159 <div ng-message="url">
161 translate="INTEGRATIONS.ERRORS.MOTIONPROXYADDRESS_MUST_VALID_URL"
162 >MotionProxyAddress must be a valid url
163 http://www.xcally.com</span
167 </md-input-container>
168 <md-input-container class="md-block">
169 <label translate="INTEGRATIONS.DESCRIPTION">Description</label>
173 ng-model="vm.sugarcrmAccount.description"
177 ng-messages="sugarcrmAccountForm['description'].$error"
178 ng-show="sugarcrmAccountForm['description'].$touched"
181 <div ng-message="required">
182 <span translate="INTEGRATIONS.ERRORS.DESCRIPTION_REQUIRED"
183 >Description field is required</span
187 </md-input-container>
189 <div class="error-list">
191 ng-repeat="error in vm.errors"
194 layout-align="space-between center"
197 <span class="message">{{error.message}}</span>
198 <span class="type">({{error.type}})</span>
200 <md-button class="md-icon-button">
202 md-font-icon="icon-alert-box"
203 aria-label="alert error"
213 layout-align="space-between center"
214 ng-if="!vm.crudPermissions.readOnly"
216 <div layout="row" layout-align="start center">
219 ng-if="vm.crudPermissions.canEdit && !vm.newSugarcrmAccount"
220 ng-click="vm.saveSugarcrmAccount()"
221 class="send-button md-accent md-raised"
222 ng-disabled="sugarcrmAccountForm.$invalid || sugarcrmAccountForm.$pristine"
224 translate="INTEGRATIONS.SAVE"
225 translate-attr-aria-label="INTEGRATIONS.SAVE"
232 ng-if="vm.crudPermissions.canEdit && vm.newSugarcrmAccount"
233 ng-click="vm.addNewSugarcrmAccount()"
234 class="send-button md-accent md-raised"
235 ng-disabled="sugarcrmAccountForm.$invalid"
237 translate="INTEGRATIONS.ADD_SUGARCRMACCOUNT"
238 translate-attr-aria-label="INTEGRATIONS.ADD_SUGARCRMACCOUNT"
245 class="md-icon-button"
246 ng-if="vm.crudPermissions.canDelete && !vm.newSugarcrmAccount"
247 ng-click="vm.deleteSugarcrmAccount($event)"
250 translate-attr-aria-label="INTEGRATIONS.DELETE"
252 <md-icon md-font-icon="icon-delete"></md-icon>
254 ><span translate="INTEGRATIONS.DELETE">DELETE</span></md-tooltip