<emui-table
:columns="columns"
:data="dataSource"
bordered
compact
selected
:selectedItems.sync="selectedItems"
:orderBy.sync="orderBy"
:loadding="loading"
expend-filed="description"
height="200"
></emui-table>
<script>
export default {
data(){
return {
columns: [
{ text: "姓名", filed: "name" ,width:"230"},
{ text: "分数", filed: "score" ,width:"230"},
],
dataSource: [
{ id: 1, name: "lili", score: 100 ,description:'score is ok'},
{ id: 2, name: "bobo", score: 100 ,description:'score is ok'},
{ id: 3, name: "siry", score: 100 },
{ id: 4, name: "laoliu", score: 100 },
{ id: 5, name: "laoliu", score: 100 },
{ id: 6, name: "laoliu", score: 100 },
{ id: 7, name: "laoliu", score: 100 },
{ id: 8, name: "laoliu", score: 100 },
{ id: 9, name: "laoliu", score: 100 },
{ id: 10, name: "laoliu", score: 100 },
{ id: 11, name: "laoliu", score: 100 },
{ id: 12, name: "laoliu", score: 100 },
{ id: 13, name: "laoliu", score: 100 },
],
selectedItems: [],
orderBy: {
name: "asc",
score: "desc",
},
loading: false,
}
}
}
</script>
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