Your Name
2022-03-14 aaebe147d319e59a8b510ff4ce9271088a330732
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
<template>
  <div class="dashboard-container">
    {{ getComponentByRole }}
    <component :is="currentRole" />
  </div>
</template>
 
<script>
import { mapGetters } from 'vuex'
import menuIndex from '../mapManage/map/index'
 
export default {
  name: 'Dashboard',
  computed: {
    ...mapGetters([
      'userType',
    ]),
    getComponentByRole() {
      this.currentRole = 'menuIndex'
      return
    }
  },
  components: { menuIndex },
  data() {
    return {
      currentRole: 'menuIndex'
    }
  }
}
</script>