fix
songhuangfeng123
2022-04-07 02409ed8fe01eb40b40b87ca872dd4b07d3b633b
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 '../doublePreventAction/riskLevelManage/analyseUnit/index'
 
export default {
  name: 'Dashboard',
  computed: {
    ...mapGetters([
      'userType',
    ]),
    getComponentByRole() {
      this.currentRole = 'menuIndex'
      return
    }
  },
  components: { menuIndex },
  data() {
    return {
      currentRole: 'menuIndex'
    }
  }
}
</script>