From 2aa88779f2c823ef42fc16e4f509020eebe84214 Mon Sep 17 00:00:00 2001 From: charismatic-claire Date: Fri, 9 Nov 2018 19:12:00 +0100 Subject: [PATCH] Revert "[issue-#39] It is now possible to download group of contacts." This reverts commit 78c8afe2947a19f637f67568db4adf0516060f12. --- src/views/Contacts.vue | 30 +----------------------------- 1 file changed, 1 insertion(+), 29 deletions(-) diff --git a/src/views/Contacts.vue b/src/views/Contacts.vue index af8c63a71..a769f2091 100644 --- a/src/views/Contacts.vue +++ b/src/views/Contacts.vue @@ -145,14 +145,7 @@ export default { }, text: group.name, utils: { - counter: group.contacts.length, - actions: [ - { - icon: 'icon-download', - text: 'Download', - action: this.downloadGroup(group) - } - ] + counter: group.contacts.length } } }).sort(function(a, b) { @@ -326,27 +319,6 @@ export default { }, resetSearch() { this.search('') - }, - - /* DOWNLOAD */ - downloadGroup(group) { - // create result - const contacts = this.contacts - const result = group.contacts.map(uid => contacts[uid].dav.data).join('') - // return result - return function() { - // create element - let element = document.createElement('a') - element.setAttribute('href', 'data:text/plain;charset=utf-8,' + encodeURIComponent(result)) - element.setAttribute('download', group.name + '.vcf') - element.style.display = 'none' - // add element to dom - document.body.appendChild(element) - // click on element - element.click() - // remove element from dom - document.body.removeChild(element) - } } } }