App.vue
1.13 KB
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
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
<template>
<div id="app">
<el-tabs v-model="activeName">
<el-tab-pane
label="传入接口(getListApi)"
name="autoTabel"
>
<h1>自动调用接口,并刷新表格</h1>
<auto-table></auto-table>
</el-tab-pane>
<el-tab-pane
label="不传入接口(getListApi)"
name="table"
>
<h1>手动调用接口,并刷新表格</h1>
<manual-table></manual-table>
</el-tab-pane>
</el-tabs>
</div>
</template>
<script>
import autoTable from './view/autoTable'
import manualTable from './view/manualTable'
export default {
name: 'app',
data() {
return {
activeName: 'autoTabel'
}
},
components: {
autoTable,
manualTable
}
}
</script>
<style>
#app {
font-family: "Avenir", Helvetica, Arial, sans-serif;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
text-align: center;
color: #2c3e50;
/* margin-top: 60px; */
}
h1,
h2 {
font-weight: normal;
}
ul {
list-style-type: none;
padding: 0;
}
li {
display: inline-block;
margin: 0 10px;
}
a {
color: #42b983;
}
</style>