2019-06-12 20:16:55 +00:00
|
|
|
<template>
|
2019-07-05 07:17:44 +00:00
|
|
|
<div class="login panel panel-default">
|
|
|
|
<!-- Default panel contents -->
|
2019-06-12 20:16:55 +00:00
|
|
|
|
2019-07-05 07:17:44 +00:00
|
|
|
<div class="panel-heading">
|
|
|
|
{{ $t('login.heading.totp') }}
|
|
|
|
</div>
|
2019-06-12 20:16:55 +00:00
|
|
|
|
2019-07-05 07:17:44 +00:00
|
|
|
<div class="panel-body">
|
|
|
|
<form
|
|
|
|
class="login-form"
|
|
|
|
@submit.prevent="submit"
|
|
|
|
>
|
|
|
|
<div class="form-group">
|
|
|
|
<label for="code">
|
|
|
|
{{ $t('login.authentication_code') }}
|
|
|
|
</label>
|
|
|
|
<input
|
|
|
|
id="code"
|
|
|
|
v-model="code"
|
|
|
|
class="form-control"
|
|
|
|
>
|
|
|
|
</div>
|
2019-06-12 20:16:55 +00:00
|
|
|
|
2019-07-05 07:17:44 +00:00
|
|
|
<div class="form-group">
|
|
|
|
<div class="login-bottom">
|
|
|
|
<div>
|
2020-11-24 10:32:42 +00:00
|
|
|
<button
|
|
|
|
class="button-unstyled -link"
|
2019-07-05 07:17:44 +00:00
|
|
|
@click.prevent="requireRecovery"
|
2021-02-01 19:07:09 +00:00
|
|
|
type="button"
|
2019-07-05 07:17:44 +00:00
|
|
|
>
|
|
|
|
{{ $t('login.enter_recovery_code') }}
|
2020-11-24 10:32:42 +00:00
|
|
|
</button>
|
2019-07-05 07:17:44 +00:00
|
|
|
<br>
|
2020-11-24 10:32:42 +00:00
|
|
|
<button
|
|
|
|
class="button-unstyled -link"
|
2019-07-05 07:17:44 +00:00
|
|
|
@click.prevent="abortMFA"
|
2021-02-01 19:07:09 +00:00
|
|
|
type="button"
|
2019-07-05 07:17:44 +00:00
|
|
|
>
|
|
|
|
{{ $t('general.cancel') }}
|
2020-11-24 10:32:42 +00:00
|
|
|
</button>
|
2019-07-05 07:17:44 +00:00
|
|
|
</div>
|
|
|
|
<button
|
|
|
|
type="submit"
|
2020-11-24 10:32:42 +00:00
|
|
|
class="btn button-default"
|
2019-07-05 07:17:44 +00:00
|
|
|
>
|
|
|
|
{{ $t('general.verify') }}
|
|
|
|
</button>
|
2019-06-12 20:16:55 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
2019-07-05 07:17:44 +00:00
|
|
|
</form>
|
|
|
|
</div>
|
2019-06-12 20:16:55 +00:00
|
|
|
|
2019-07-05 07:17:44 +00:00
|
|
|
<div
|
|
|
|
v-if="error"
|
|
|
|
class="form-group"
|
|
|
|
>
|
|
|
|
<div class="alert error">
|
|
|
|
{{ error }}
|
2020-10-20 21:01:28 +00:00
|
|
|
<FAIcon
|
|
|
|
size="lg"
|
2020-10-28 19:31:16 +00:00
|
|
|
class="fa-scale-110 fa-old-padding"
|
2020-10-20 21:01:28 +00:00
|
|
|
icon="times"
|
2019-07-05 07:17:44 +00:00
|
|
|
@click="clearError"
|
|
|
|
/>
|
|
|
|
</div>
|
2019-06-12 20:16:55 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</template>
|
|
|
|
<script src="./totp_form.js"></script>
|