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
31
32
33
34
35
36
37
38
39
40
41
| <template>
|
| <div>
| <el-tabs v-model="activeName" @tab-click="handleClick">
| <el-tab-pane label="人/房标签统计" name="first"></el-tab-pane>
| <el-tab-pane label="场所标签统计" name="second"></el-tab-pane>
| </el-tabs>
|
| <div v-if="activeName ==='first'">
| <houseStatistics ref="houseStatistics" />
| </div>
|
| <div v-else>
| <placeStatistics ref="placeStatistics" />
| </div>
|
|
| </div>
|
|
| </template>
| <script>
| import houseStatistics from '../components/houseStatistics.vue'
| import placeStatistics from '../components/placeStatistics.vue'
| export default {
| data() {
| return {
| activeName: 'first'
| };
| },
| components: {
| houseStatistics,
| placeStatistics
| },
| methods: {
| handleClick(tab, event) {
| console.log(tab, event);
| }
| }
| };
| </script>
|
|