cleanup admin 'dashboard'
This commit is contained in:
parent
f44da341b4
commit
d13687a910
3 changed files with 35 additions and 64 deletions
|
@ -7,7 +7,7 @@ import Files from './views/Files';
|
|||
import HowTo from './views/HowTo';
|
||||
import Login from '@/views/Login.vue';
|
||||
import Register from '@/views/Register.vue';
|
||||
import Debug from "@/views/admin/Debug.vue";
|
||||
import Dashboard from "@/views/admin/Dashboard.vue";
|
||||
import Tickets from "@/views/Tickets.vue";
|
||||
import Ticket from "@/views/Ticket.vue";
|
||||
import Admin from "@/views/admin/Admin.vue";
|
||||
|
@ -59,7 +59,7 @@ const routes = [
|
|||
{requiresAuth: true, requiresPermission: 'delete_event'}
|
||||
},
|
||||
{
|
||||
path: '', name: 'admin', component: Debug, meta:
|
||||
path: '', name: 'admin', component: Dashboard, meta:
|
||||
{requiresAuth: true, requiresPermission: 'delete_event'}
|
||||
},
|
||||
{
|
||||
|
|
33
web/src/views/admin/Dashboard.vue
Normal file
33
web/src/views/admin/Dashboard.vue
Normal file
|
@ -0,0 +1,33 @@
|
|||
<template>
|
||||
<div>
|
||||
<h3 class="text-center">Events</h3>
|
||||
<ul>
|
||||
<li v-for="event in events" :key="event.id">
|
||||
{{ event.slug }}
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {mapActions, mapState} from 'vuex';
|
||||
import Table from '@/components/Table';
|
||||
|
||||
export default {
|
||||
name: 'Dashboard',
|
||||
components: {},
|
||||
computed: {
|
||||
...mapState(['events']),
|
||||
},
|
||||
methods: {
|
||||
...mapActions(['loadEvents']),
|
||||
|
||||
},
|
||||
mounted() {
|
||||
this.loadEvents();
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
</style>
|
|
@ -1,62 +0,0 @@
|
|||
<template>
|
||||
<div>
|
||||
<!--qr-code :text="qr_url" color="#000" bg-color="#fff" error-level="H" class="qr-code"></qr-code-->
|
||||
<h3 class="text-center">Events</h3>
|
||||
<!--p>{{ events }}</p-->
|
||||
<ul>
|
||||
<li v-for="event in events" :key="event.id">
|
||||
{{ event.slug }}
|
||||
</li>
|
||||
</ul>
|
||||
<h3 class="text-center">Items</h3>
|
||||
<!--p>{{ loadedItems }}</p-->
|
||||
<ul>
|
||||
<li v-for="item in loadedItems" :key="item.id">
|
||||
{{ item.description }}
|
||||
</li>
|
||||
</ul>
|
||||
<h3 class="text-center">Boxes</h3>
|
||||
<!--p>{{ loadedBoxes }}</p-->
|
||||
<ul>
|
||||
<li v-for="box in loadedBoxes" :key="box.id">
|
||||
{{ box.name }}
|
||||
</li>
|
||||
</ul>
|
||||
<h3 class="text-center">Issues</h3>
|
||||
<!--p>{{ issues }}</p-->
|
||||
<ul>
|
||||
<li v-for="issue in tickets" :key="issue.id">
|
||||
{{ issue.id }}
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import {mapActions, mapState} from 'vuex';
|
||||
import Table from '@/components/Table';
|
||||
|
||||
export default {
|
||||
name: 'Debug',
|
||||
components: {Table},
|
||||
computed: {
|
||||
...mapState(['events', 'loadedItems', 'loadedBoxes', 'tickets']),
|
||||
qr_url() {
|
||||
return window.location.href;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
...mapActions(['changeEvent', 'loadTickets']),
|
||||
|
||||
},
|
||||
mounted() {
|
||||
this.loadTickets();
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
||||
<style>
|
||||
.qr-code img {
|
||||
border: #fff solid 7px
|
||||
}
|
||||
</style>
|
Loading…
Reference in a new issue