Add Nuxt
This commit is contained in:
20
app/pages/adminpanel/Main.vue
Normal file
20
app/pages/adminpanel/Main.vue
Normal file
@@ -0,0 +1,20 @@
|
||||
<script lang="ts" setup>
|
||||
import { useRoute } from 'vue-router'
|
||||
import { ref } from "vue";
|
||||
import AdminPanelLib from "../../adminpanellib.ts";
|
||||
import AdminNavbar from "../../components/admin/AdminNavbar.vue";
|
||||
|
||||
const route = useRoute();
|
||||
|
||||
const token=ref(route.params.token);
|
||||
const userinfo=ref({})
|
||||
|
||||
AdminPanelLib.AdminPanelLib.getUserInfo(token.value).then((result)=>userinfo.value=result);
|
||||
|
||||
|
||||
</script>
|
||||
<template>
|
||||
<AdminNavbar/>
|
||||
<h1>Admin Panel</h1>
|
||||
<h2>Moin {{ userinfo.username }}!</h2>
|
||||
</template>
|
||||
Reference in New Issue
Block a user