You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

52 lines
1.1 KiB

2 years ago
2 years ago
3 years ago
2 years ago
2 years ago
  1. <template>
  2. <v-app>
  3. <the-header>
  4. <template #leftDrawerIcon>
  5. <v-app-bar-nav-icon @click="drawerLeft = !drawerLeft" />
  6. </template>
  7. </the-header>
  8. <v-navigation-drawer v-model="drawerLeft" app clipped color="">
  9. <the-side-bar :is-project-admin="isProjectAdmin" :project="currentProject" />
  10. </v-navigation-drawer>
  11. <v-main>
  12. <v-container fluid fill-height>
  13. <v-layout justify-center>
  14. <v-flex fill-height>
  15. <nuxt />
  16. </v-flex>
  17. </v-layout>
  18. </v-container>
  19. </v-main>
  20. </v-app>
  21. </template>
  22. <script>
  23. import { mapGetters } from 'vuex'
  24. import TheHeader from '~/components/layout/TheHeader'
  25. import TheSideBar from '~/components/layout/TheSideBar'
  26. export default {
  27. components: {
  28. TheSideBar,
  29. TheHeader
  30. },
  31. middleware: ['check-auth', 'auth', 'check-admin'],
  32. data() {
  33. return {
  34. drawerLeft: null,
  35. isProjectAdmin: false
  36. }
  37. },
  38. computed: {
  39. ...mapGetters('projects', ['currentProject'])
  40. },
  41. async created() {
  42. this.isProjectAdmin = await this.$services.member.isProjectAdmin(this.$route.params.id)
  43. }
  44. }
  45. </script>