From f867bd3fc5605ab62edf9d8e6c372ca7249c2862 Mon Sep 17 00:00:00 2001 From: Bubka <858858+Bubka@users.noreply.github.com> Date: Mon, 10 Oct 2022 13:53:43 +0200 Subject: [PATCH] Add a Clear button to empty the Import view when all is imported --- resources/js/views/twofaccounts/Import.vue | 7 +++++++ resources/lang/en/commons.php | 1 + 2 files changed, 8 insertions(+) diff --git a/resources/js/views/twofaccounts/Import.vue b/resources/js/views/twofaccounts/Import.vue index 87c01215..c1ecff69 100644 --- a/resources/js/views/twofaccounts/Import.vue +++ b/resources/js/views/twofaccounts/Import.vue @@ -108,6 +108,9 @@ +
+ +
@@ -177,6 +180,10 @@ duplicateCount() { return this.exportedAccounts.filter(account => account.id === -1 && account.imported === -1).length; }, + + importedCount() { + return this.exportedAccounts.filter(account => account.imported === 1).length; + } }, mounted: async function() { diff --git a/resources/lang/en/commons.php b/resources/lang/en/commons.php index bd7c46f3..edcf2775 100644 --- a/resources/lang/en/commons.php +++ b/resources/lang/en/commons.php @@ -26,6 +26,7 @@ return [ 'create' => 'Create', 'save' => 'Save', 'close' => 'Close', + 'clear' => 'Clear', 'demo_do_not_post_sensitive_data' => 'This is a demo app, do not post any sensitive data', 'testing_do_not_post_sensitive_data' => 'This is a testing app, do not post any sensitive data', 'selected' => 'selected',