diff --git a/appinfo/routes.php b/appinfo/routes.php index 08a8970..2c8b55b 100644 --- a/appinfo/routes.php +++ b/appinfo/routes.php @@ -21,6 +21,10 @@ declare(strict_types=1); return [ 'resources' => [ - 'AuthSettings' => ['url' => '/authtokens' , 'root' => ''], + // Apparently has the convention calling AuthSettingsController.destroy() on DELETE + 'AuthSettings' => ['url' => '/authtokens' , 'root' => ''], ], + 'routes' => [ + ['name' => 'AuthSettings#wipe', 'url' => '/authtokens/wipe/{id}', 'verb' => 'POST' , 'root' => ''], + ] ]; diff --git a/src/components/security/AuthToken.vue b/src/components/security/AuthToken.vue index 9b9d764..7f4ada0 100644 --- a/src/components/security/AuthToken.vue +++ b/src/components/security/AuthToken.vue @@ -350,7 +350,7 @@ export default defineComponent({ }, wipe() { this.actionOpen = false - this.authTokenStore.wipeToken(this.token) + this.$emit('wipe', this.token) }, }, }) diff --git a/src/components/security/AuthTokenList.vue b/src/components/security/AuthTokenList.vue index d4532a5..089e34f 100644 --- a/src/components/security/AuthTokenList.vue +++ b/src/components/security/AuthTokenList.vue @@ -40,6 +40,7 @@ diff --git a/src/components/security/AuthTokenSection.vue b/src/components/security/AuthTokenSection.vue index be54a0e..70bcf6f 100644 --- a/src/components/security/AuthTokenSection.vue +++ b/src/components/security/AuthTokenSection.vue @@ -26,14 +26,38 @@

{{ t('simplesettings', 'Web, desktop and mobile clients currently logged in to your account.') }}

- + + + {{ t('simplesettings', 'Do you really want to wipe your data from this device?') }} +
+ + {{ t('simplesettings', 'Cancel') }} + + + + {{ t('simplesettings', 'Confirm wipe') }} + +
+
+ + diff --git a/src/components/security/AuthTokenSetup.vue b/src/components/security/AuthTokenSetup.vue index 44829df..8e5ae48 100644 --- a/src/components/security/AuthTokenSetup.vue +++ b/src/components/security/AuthTokenSetup.vue @@ -44,6 +44,7 @@