Changeset View
Changeset View
Standalone View
Standalone View
src/resources/vue/CompanionApp.vue
- This file was added.
<template> | |||||
<div class="container" dusk="companionapp-component"> | |||||
<div class="card"> | |||||
<div class="card-body"> | |||||
<div class="card-title">Companion App</div> | |||||
<div class="card-text"> | |||||
machniak: I'd add `<small><sup class="badge bg-primary">{{ $t('dashboard.beta') }}</sup></small>` to the… | |||||
<div class="alert"> | |||||
Connect the companion app for 2fa. | |||||
</div> | |||||
Done Inline ActionsAll text needs to be moved to localization. machniak: All text needs to be moved to localization. | |||||
<p> | |||||
<img :src="qrcode" /> | |||||
</p> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
</div> | |||||
</template> | |||||
<script> | |||||
import { Modal } from 'bootstrap' | |||||
export default { | |||||
components: { | |||||
}, | |||||
data() { | |||||
return { | |||||
companion: {}, | |||||
qrcode: "" | |||||
} | |||||
}, | |||||
mounted() { | |||||
this.$root.startLoading() | |||||
axios.get('/api/v4/companion/1') | |||||
.then(response => { | |||||
this.$root.stopLoading() | |||||
this.companion = response.data | |||||
this.qrcode = response.data.qrcode | |||||
}) | |||||
.catch(this.$root.errorHandler) | |||||
}, | |||||
methods: { | |||||
}, | |||||
} | |||||
</script> | |||||
Done Inline ActionsInstead, we can just add @click="$root.tab" to the nav-link elements. machniak: Instead, we can just add `@click="$root.tab"` to the `nav-link` elements. | |||||
Done Inline ActionsThere's no modal on the page. machniak: There's no modal on the page. |
I'd add <small><sup class="badge bg-primary">{{ $t('dashboard.beta') }}</sup></small> to the title.