mirror of
https://github.com/Bubka/2FAuth.git
synced 2025-06-19 03:16:49 +02:00
Prompt for page refresh when 2FAccount is missing
This commit is contained in:
parent
31d6450d3f
commit
ea5bff816e
@ -35,6 +35,11 @@
|
|||||||
<one-time-password ref="OneTimePassword"></one-time-password>
|
<one-time-password ref="OneTimePassword"></one-time-password>
|
||||||
</twofaccount-show>
|
</twofaccount-show>
|
||||||
</modal>
|
</modal>
|
||||||
|
<modal v-model="ShowNoTwofaccountInModal">
|
||||||
|
<div>
|
||||||
|
resource not found, please <a @click="()=>{this.$router.go()}" class="is-text has-text-white">refresh</a>
|
||||||
|
</div>
|
||||||
|
</modal>
|
||||||
<footer class="has-background-black-ter">
|
<footer class="has-background-black-ter">
|
||||||
<div class="columns is-gapless" v-if="this.accounts.length > 0">
|
<div class="columns is-gapless" v-if="this.accounts.length > 0">
|
||||||
<div class="column has-text-centered">
|
<div class="column has-text-centered">
|
||||||
@ -87,6 +92,7 @@
|
|||||||
return {
|
return {
|
||||||
accounts : [],
|
accounts : [],
|
||||||
ShowTwofaccountInModal : false,
|
ShowTwofaccountInModal : false,
|
||||||
|
ShowNoTwofaccountInModal : false,
|
||||||
twofaccount: {},
|
twofaccount: {},
|
||||||
token : null,
|
token : null,
|
||||||
username : null,
|
username : null,
|
||||||
@ -122,6 +128,11 @@
|
|||||||
this.$on('modalClose', function() {
|
this.$on('modalClose', function() {
|
||||||
console.log('modalClose triggered')
|
console.log('modalClose triggered')
|
||||||
this.$refs.OneTimePassword.clearOTP()
|
this.$refs.OneTimePassword.clearOTP()
|
||||||
|
|
||||||
|
this.twofaccount.id = ''
|
||||||
|
this.twofaccount.service = ''
|
||||||
|
this.twofaccount.account = ''
|
||||||
|
this.twofaccount.icon = ''
|
||||||
});
|
});
|
||||||
|
|
||||||
},
|
},
|
||||||
@ -151,6 +162,9 @@
|
|||||||
this.ShowTwofaccountInModal = true;
|
this.ShowTwofaccountInModal = true;
|
||||||
|
|
||||||
})
|
})
|
||||||
|
.catch(error => {
|
||||||
|
this.ShowNoTwofaccountInModal = true;
|
||||||
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
deleteAccount: function (id) {
|
deleteAccount: function (id) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user