diff options
author | skjnldsv <fremulon@protonmail.com> | 2016-04-07 08:01:22 +0200 |
---|---|---|
committer | Thomas Müller <thomas.mueller@tmit.eu> | 2016-04-10 21:20:22 +0200 |
commit | 6498f49ab9cc3cf8130fb8c29ca5fbb3514ae8b1 (patch) | |
tree | be33c3a0e1f679ae8fa72022a6ca60a447eae84a /templates | |
parent | 7a77692a6d9de883c0d9a78d291ec8f8920e1804 (diff) |
Hide the Add Contact button if we've got an invalid contact
Diffstat (limited to 'templates')
-rw-r--r-- | templates/contactList.html | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/templates/contactList.html b/templates/contactList.html index 602904b7..dd865a46 100644 --- a/templates/contactList.html +++ b/templates/contactList.html @@ -1,10 +1,11 @@ <div style="height: 90%" class="contacts-list" ng-class="{loading: ctrl.loading, 'mobile-show': ctrl.show}"> - <button ng-show="!ctrl.loading" class="app-content-list-button" type="button" name="button" ng-click="ctrl.createContact()">{{ctrl.t.addContact}}</button> + <button ng-show="!ctrl.loading && !ctrl.invalid" class="app-content-list-button" id="new-contact-button" + type="button" name="button" ng-click="ctrl.createContact()">{{ctrl.t.addContact}}</button> <div class="app-content-list-item" - ng-repeat="contact in ctrl.contactList = (ctrl.contacts | contactGroupFilter:ctrl.routeParams.gid | orderBy:'fullName()' | filter:query) track by contact.uid()" - contact data="contact" - ng-click="setSelected(contact.uid())" - ng-class="{active: contact.uid() === ctrl.getSelectedId()}"> + ng-repeat="contact in ctrl.contactList = (ctrl.contacts | contactGroupFilter:ctrl.routeParams.gid | orderBy:'fullName()' | filter:query) track by contact.uid()" + contact data="contact" + ng-click="setSelected(contact.uid())" + ng-class="{active: contact.uid() === ctrl.getSelectedId()}"> </div> <div ng-show="!ctrl.contactList.length && !ctrl.loading && ctrl.searchTerm !== ''"> <div id="emptycontent" class="emptycontent-search"> |