2cb8a6d9
梁灏
commit Table comp...
|
1
|
<template>
|
ceeb9361
梁灏
fixed Table bug i...
|
2
|
<Table border :columns="columns6" :data="data5"></Table>
|
2cb8a6d9
梁灏
commit Table comp...
|
3
4
|
</template>
<script>
|
2cb8a6d9
梁灏
commit Table comp...
|
5
|
export default {
|
51356c2c
梁灏
fixed #658
|
6
7
|
data () {
return {
|
ceeb9361
梁灏
fixed Table bug i...
|
8
9
10
11
12
|
columns6: [
{
title: 'Date',
key: 'date'
},
|
437b8059
Sergio Crisostomo
Added Table to CS...
|
13
|
{
|
55f90d87
梁灏
fixed #1648
|
14
|
title: 'Name',
|
ceeb9361
梁灏
fixed Table bug i...
|
15
|
key: 'name'
|
2993f4ee
梁灏
update Tab
|
16
17
|
},
{
|
55f90d87
梁灏
fixed #1648
|
18
19
|
title: 'Age',
key: 'age',
|
ceeb9361
梁灏
fixed Table bug i...
|
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
filters: [
{
label: 'Greater than 25',
value: 1
},
{
label: 'Less than 25',
value: 2
}
],
filterMultiple: false,
filterMethod (value, row) {
if (value === 1) {
return row.age > 25;
} else if (value === 2) {
return row.age < 25;
}
}
|
2993f4ee
梁灏
update Tab
|
38
39
|
},
{
|
55f90d87
梁灏
fixed #1648
|
40
41
|
title: 'Address',
key: 'address',
|
ceeb9361
梁灏
fixed Table bug i...
|
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
filters: [
{
label: 'New York',
value: 'New York'
},
{
label: 'London',
value: 'London'
},
{
label: 'Sydney',
value: 'Sydney'
}
],
filterMethod (value, row) {
return row.address.indexOf(value) > -1;
|
b142865e
梁灏
fixed #2102
|
58
|
}
|
437b8059
Sergio Crisostomo
Added Table to CS...
|
59
60
|
}
],
|
ceeb9361
梁灏
fixed Table bug i...
|
61
|
data5: [
|
b142865e
梁灏
fixed #2102
|
62
63
64
65
|
{
name: 'John Brown',
age: 18,
address: 'New York No. 1 Lake Park',
|
ceeb9361
梁灏
fixed Table bug i...
|
66
|
date: '2016-10-03'
|
b142865e
梁灏
fixed #2102
|
67
68
69
70
|
},
{
name: 'Jim Green',
age: 24,
|
ceeb9361
梁灏
fixed Table bug i...
|
71
72
|
address: 'London No. 1 Lake Park',
date: '2016-10-01'
|
b142865e
梁灏
fixed #2102
|
73
74
75
76
77
|
},
{
name: 'Joe Black',
age: 30,
address: 'Sydney No. 1 Lake Park',
|
ceeb9361
梁灏
fixed Table bug i...
|
78
|
date: '2016-10-02'
|
b142865e
梁灏
fixed #2102
|
79
80
81
82
83
|
},
{
name: 'Jon Snow',
age: 26,
address: 'Ottawa No. 2 Lake Park',
|
ceeb9361
梁灏
fixed Table bug i...
|
84
|
date: '2016-10-04'
|
437b8059
Sergio Crisostomo
Added Table to CS...
|
85
|
}
|
ceeb9361
梁灏
fixed Table bug i...
|
86
|
],
|
c5beedf8
梁灏
fixed #690
|
87
|
}
|
2cb8a6d9
梁灏
commit Table comp...
|
88
|
}
|
6c634aa6
梁灏
fixed #2078
|
89
|
}
|
17db7df4
梁灏
fixed #1751
|
90
|
</script>
|