|
@@ -0,0 +1,96 @@
|
|
1
|
+<template>
|
|
2
|
+ <div class="global">
|
|
3
|
+ <div class="contentContainerGg">
|
|
4
|
+ <div class="container">
|
|
5
|
+ <el-table border :data="tableList" highlight-current-row style="width:100%" :header-cell-style="{background:'#f8f8f8'}">
|
|
6
|
+ <el-table-column type="index" align="center" label="序号" width="50px"/>
|
|
7
|
+ <el-table-column prop="warnName" label="仓房" align="center" />
|
|
8
|
+ <el-table-column prop="warnName" label="所属公司" align="center" />
|
|
9
|
+ <el-table-column prop="warnName" label="储存状态(个)" align="center" />
|
|
10
|
+ <el-table-column prop="warnName" label="粮食种类(个)" align="center" />
|
|
11
|
+ <el-table-column prop="warnName" label="仓房状态(个)" align="center" />
|
|
12
|
+ </el-table>
|
|
13
|
+ <div class="pagination-container">
|
|
14
|
+ <el-pagination
|
|
15
|
+ class="right"
|
|
16
|
+ background
|
|
17
|
+ :current-page.sync="listQuery.page"
|
|
18
|
+ :page-size="listQuery.limit"
|
|
19
|
+ :page-sizes="[10,20,30,40]"
|
|
20
|
+ :total="total"
|
|
21
|
+ @size-change="sizeChange"
|
|
22
|
+ @current-change="pageChange"
|
|
23
|
+ layout="total, sizes, prev, pager, next, jumper"
|
|
24
|
+ ></el-pagination>
|
|
25
|
+ </div>
|
|
26
|
+ </div>
|
|
27
|
+ </div>
|
|
28
|
+ </div>
|
|
29
|
+</template>
|
|
30
|
+<script>
|
|
31
|
+import { getList } from '@/api/system/earlyWarningManagement'
|
|
32
|
+export default {
|
|
33
|
+ data() {
|
|
34
|
+ return {
|
|
35
|
+ // 列表数据
|
|
36
|
+ tableList: [],
|
|
37
|
+ // 分页
|
|
38
|
+ total: 0,
|
|
39
|
+ listLoading: true,
|
|
40
|
+ listQuery: {
|
|
41
|
+ page: 1,
|
|
42
|
+ limit: 10,
|
|
43
|
+ },
|
|
44
|
+ roleList:[]
|
|
45
|
+ }
|
|
46
|
+ },
|
|
47
|
+ created() {
|
|
48
|
+ this.getList()
|
|
49
|
+ },
|
|
50
|
+ methods: {
|
|
51
|
+ getList() {
|
|
52
|
+ let data = {
|
|
53
|
+ pageIndex: this.listQuery.page,
|
|
54
|
+ pageSize: this.listQuery.limit
|
|
55
|
+ }
|
|
56
|
+ getList(data).then((res) => {
|
|
57
|
+ if (res.code == 200) {
|
|
58
|
+ this.tableList = res.data.records
|
|
59
|
+ this.listQuery.limit = res.data.size
|
|
60
|
+ this.total = res.data.total
|
|
61
|
+ }else{
|
|
62
|
+ this.$message({
|
|
63
|
+ type: 'error',
|
|
64
|
+ message: res.msg
|
|
65
|
+ })
|
|
66
|
+ }
|
|
67
|
+ }).catch((err) => {
|
|
68
|
+ console.log(err)
|
|
69
|
+ })
|
|
70
|
+ },
|
|
71
|
+ sizeChange(v) {
|
|
72
|
+ this.listQuery.limit = v;
|
|
73
|
+ this.getList();
|
|
74
|
+ },
|
|
75
|
+ pageChange(v) {
|
|
76
|
+ this.listQuery.page = v;
|
|
77
|
+ this.getList();
|
|
78
|
+ },
|
|
79
|
+ }
|
|
80
|
+}
|
|
81
|
+</script>
|
|
82
|
+<style lang="scss" scoped>
|
|
83
|
+.top {
|
|
84
|
+ height: 40px;
|
|
85
|
+ line-height: 40px;
|
|
86
|
+ border-bottom: 1px solid #ccc;
|
|
87
|
+}
|
|
88
|
+.container {
|
|
89
|
+ padding: 10px;
|
|
90
|
+}
|
|
91
|
+.pagination-container {
|
|
92
|
+ margin-top:10px;
|
|
93
|
+ margin-right:20px;
|
|
94
|
+ text-align: right;
|
|
95
|
+}
|
|
96
|
+</style>
|