diff options
author | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2017-08-25 19:15:01 +0200 |
---|---|---|
committer | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2017-09-03 18:51:25 +0200 |
commit | c448a4c1f838310a4925c095cac90451e2e0acd6 (patch) | |
tree | ec1bb36bea47124dbd6e5e4d71746fa75793543a /templates | |
parent | 1c1a4cfda3e0f8c092913aaa313209073e5335ac (diff) |
No import if only ab left is in read-only mode
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
Diffstat (limited to 'templates')
-rw-r--r-- | templates/contactImport.html | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/templates/contactImport.html b/templates/contactImport.html index b63d8489..c4bfcb1a 100644 --- a/templates/contactImport.html +++ b/templates/contactImport.html @@ -1,8 +1,10 @@ -<input type="file" id="contact-import" class="hidden-visually" multiple/> -<label for="contact-import" class="button {{ctrl.loadingClass}}" ng-class="{'no-select': ctrl.addressBooks.length === 1}" id="upload"> - {{ctrl.importText}} - <span ng-if="ctrl.addressBooks.length === 1 && !ctrl.importing" ng-class="{'icon-loading-small': ctrl.loading}">{{ctrl.selectedAddressBook.displayName}}</span> -</label> +<span ng-if="!(ctrl.addressBooks.length===1 && ctrl.addressBooks[0].readOnly)"> + <input type="file" id="contact-import" class="hidden-visually" multiple /> + <label for="contact-import" class="button {{ctrl.loadingClass}}" ng-class="{'no-select': ctrl.addressBooks.length === 1}" id="upload"> + {{ctrl.importText}} + <span ng-if="ctrl.addressBooks.length === 1 && !ctrl.importing" ng-class="{'icon-loading-small': ctrl.loading}">{{ctrl.selectedAddressBook.displayName}}</span> + </label> +</span> <ui-select ng-model="ctrl.selectedAddressBook" ng-if="ctrl.addressBooks.length > 1" search-enabled="ctrl.addressBooks.length > 4" theme="select2" class="form-control" title="{{ctrl.t.selectAddressbook}}" uis-open-close="ctrl.stopHideMenu(isOpen)" ng-class="{'icon-loading-small': ctrl.loading}"> |