page.vue
2.26 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
<template>
<div>
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
{{ current }}
<Button type="primary" @click="subject">- 1</Button>
<Button type="primary" @click="change">Change</Button>
<Page :current="2" :total="50" simple></Page>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
<div style="margin:20px 0px">
<Page :total="total" show-sizer show-elevator show-total transfer :current.sync="current"></Page>
</div>
</div>
</template>
<script>
export default {
data () {
return {
current: 1,
total: 21
}
},
methods: {
subject() {
this.total -= 1;
},
change() {
this.current = 1;
}
}
}
</script>