分页显示
Showing
1 changed file
with
64 additions
and
66 deletions
... | @@ -50,52 +50,51 @@ | ... | @@ -50,52 +50,51 @@ |
50 | <td>权利人</td> | 50 | <td>权利人</td> |
51 | <td>坐落</td> | 51 | <td>坐落</td> |
52 | </tr> | 52 | </tr> |
53 | <tr v-if="Data.length==0"> | 53 | <tr v-if="Data.length == 0"> |
54 | <td colspan="8"> | 54 | <td colspan="8"> |
55 | <span class="noData">暂无数据</span> | 55 | <span class="noData">暂无数据</span> |
56 | </td> | 56 | </td> |
57 | </tr> | 57 | </tr> |
58 | <tr v-else v-for="(item,index) in Data" :key="index"> | 58 | <tr v-else v-for="(item, index) in Data" :key="index"> |
59 | <td>{{index+1}}</td> | 59 | <td>{{ index + 1 }}</td> |
60 | <td @click="xzzrz(item)" class="xz"> | 60 | <td @click="xzzrz(item)" class="xz"> |
61 | <span>选择</span> | 61 | <span>选择</span> |
62 | </td> | 62 | </td> |
63 | <td>{{item.zddm}}</td> | 63 | <td>{{ item.zddm }}</td> |
64 | <td>{{item.bdcdyh}}</td> | 64 | <td>{{ item.bdcdyh }}</td> |
65 | <td>{{item.xmmc}}</td> | 65 | <td>{{ item.xmmc }}</td> |
66 | <td>{{item.bdcqzh}}</td> | 66 | <td>{{ item.bdcqzh }}</td> |
67 | <td>{{item.qlr}}</td> | 67 | <td>{{ item.qlr }}</td> |
68 | <td>{{item.zl}}</td> | 68 | <td>{{ item.zl }}</td> |
69 | </tr> | 69 | </tr> |
70 | |||
71 | </table> | 70 | </table> |
72 | </div> | 71 | </div> |
73 | <span slot="footer" class="dialog-footer"> | 72 | <span slot="footer" class="dialog-footer"> </span> |
74 | </span> | 73 | <cxlz-query-data |
75 | <cxlz-query-data :centerDialogVisible="centerDialogVisible" :dylxs="dylxs" @close="close" | 74 | :centerDialogVisible="centerDialogVisible" |
76 | :zrzbsm="zrzbsm"></cxlz-query-data> | 75 | :dylxs="dylxs" |
76 | @close="close" | ||
77 | :zrzbsm="zrzbsm" | ||
78 | ></cxlz-query-data> | ||
77 | <div> | 79 | <div> |
78 | <el-pagination | 80 | <el-pagination |
79 | background | 81 | background |
80 | @size-change="sizeChange" | 82 | layout="prev, pager, next,total" |
83 | :total="total" | ||
81 | @current-change="currentChange" | 84 | @current-change="currentChange" |
82 | :current-page.sync="queryData.pageNo" | 85 | > |
83 | :page-size="queryData.pageSize" | ||
84 | layout="total, prev, pager, next" | ||
85 | :total="total"> | ||
86 | </el-pagination> | 86 | </el-pagination> |
87 | </div> | 87 | </div> |
88 | |||
89 | </div> | 88 | </div> |
90 | </template> | 89 | </template> |
91 | 90 | ||
92 | <script> | 91 | <script> |
93 | import {getSearchList} from './../../../../api/search' | 92 | import { getSearchList } from "./../../../../api/search"; |
94 | import cxlzQueryData from "../../../../components/cxlxQueryData/cxlzQueryData"; | 93 | import cxlzQueryData from "../../../../components/cxlxQueryData/cxlzQueryData"; |
95 | 94 | ||
96 | export default { | 95 | export default { |
97 | name: "", | 96 | name: "", |
98 | components: {cxlzQueryData}, | 97 | components: { cxlzQueryData }, |
99 | props: {}, | 98 | props: {}, |
100 | data() { | 99 | data() { |
101 | return { | 100 | return { |
... | @@ -105,108 +104,107 @@ | ... | @@ -105,108 +104,107 @@ |
105 | queryData: { | 104 | queryData: { |
106 | bdcdyh: "", | 105 | bdcdyh: "", |
107 | bdcqzh: "", | 106 | bdcqzh: "", |
108 | dylxs: ['zrz'], | 107 | dylxs: ["zrz"], |
109 | qlrmc: "", | 108 | qlrmc: "", |
110 | qszt: "", | 109 | qszt: "", |
111 | xmmc: "", | 110 | xmmc: "", |
112 | zddm: "", | 111 | zddm: "", |
113 | zl: "", | 112 | zl: "", |
114 | pageNo: 1, | 113 | pageNo: 1, |
115 | pageSize: 5 | 114 | pageSize: 5, |
116 | }, | 115 | }, |
117 | Data: [], | 116 | Data: [], |
118 | dylxs: ['zd'] | 117 | dylxs: ["zd"], |
119 | } | 118 | }; |
120 | }, | ||
121 | created() { | ||
122 | }, | 119 | }, |
120 | created() {}, | ||
123 | mounted() { | 121 | mounted() { |
124 | this.getData(this.queryData) | 122 | this.getData(this.queryData); |
125 | }, | 123 | }, |
126 | methods: { | 124 | methods: { |
127 | sizeChange: function (val) { | 125 | sizeChange: function(val) { |
128 | console.log(`每页 ${val} 条`); | 126 | console.log(`每页 ${val} 条`); |
129 | this.queryData.pageSize = val | 127 | this.queryData.pageSize = val; |
130 | }, | 128 | }, |
131 | currentChange: function (val) { | 129 | currentChange: function(val) { |
132 | console.log(`当前页: ${val}`); | 130 | console.log(`当前页: ${val}`); |
133 | this.queryData.pageNo = val | 131 | this.queryData.pageNo = val; |
134 | this.getData(this.queryData) | 132 | this.getData(this.queryData); |
135 | }, | 133 | }, |
136 | xzzrz: function (item) { | 134 | xzzrz: function(item) { |
137 | this.centerDialogVisible = true; | 135 | this.centerDialogVisible = true; |
138 | this.zrzbsm = item.glbsm; | 136 | this.zrzbsm = item.glbsm; |
139 | }, | 137 | }, |
140 | close: function () { | 138 | close: function() { |
141 | this.centerDialogVisible = false; | 139 | this.centerDialogVisible = false; |
142 | }, | 140 | }, |
143 | result: function () { | 141 | result: function() { |
144 | this.queryData = { | 142 | this.queryData = { |
145 | bdcdyh: "", | 143 | bdcdyh: "", |
146 | bdcqzh: "", | 144 | bdcqzh: "", |
147 | dylxs: ['zrz'], | 145 | dylxs: ["zrz"], |
148 | qlrmc: "", | 146 | qlrmc: "", |
149 | qszt: "", | 147 | qszt: "", |
150 | xmmc: "", | 148 | xmmc: "", |
151 | zddm: "", | 149 | zddm: "", |
152 | zl: "", | 150 | zl: "", |
153 | pageNo: 1, | 151 | pageNo: 1, |
154 | pageSize: 10 | 152 | pageSize: 10, |
155 | }; | 153 | }; |
156 | this.getData(this.queryData) | 154 | this.getData(this.queryData); |
157 | }, | 155 | }, |
158 | getData: function (data) { | 156 | getData: function(data) { |
159 | getSearchList(data).then(res => { | 157 | getSearchList(data).then((res) => { |
160 | this.Data = res.result.records | 158 | this.Data = res.result.records; |
161 | this.total = res.total | 159 | this.total = res.result.total; |
162 | }) | 160 | }); |
163 | }, | 161 | }, |
164 | search: function () { | 162 | search: function() { |
165 | this.getData(this.queryData) | 163 | this.getData(this.queryData); |
166 | }, | 164 | }, |
167 | }, | 165 | }, |
168 | computed: {}, | 166 | computed: {}, |
169 | watch: {}, | 167 | watch: {}, |
170 | } | 168 | }; |
171 | </script> | 169 | </script> |
172 | <style scoped lang="less"> | 170 | <style scoped lang="less"> |
173 | .main { | 171 | .main { |
174 | box-sizing: border-box; | 172 | box-sizing: border-box; |
175 | padding: 18px; | 173 | padding: 18px; |
176 | height: auto; | 174 | height: auto; |
177 | width: 80%; | 175 | width: 80%; |
178 | } | 176 | } |
179 | 177 | ||
180 | table { | 178 | table { |
181 | margin-top: 10px; | 179 | margin-top: 10px; |
182 | background-color: #fff; | 180 | background-color: #fff; |
183 | font-size: 14px; | 181 | font-size: 14px; |
184 | width: 100%; | 182 | width: 100%; |
185 | } | 183 | } |
186 | 184 | ||
187 | td { | 185 | td { |
188 | text-align: center; | 186 | text-align: center; |
189 | height: 36px; | 187 | height: 36px; |
190 | min-width: 50px; | 188 | min-width: 50px; |
191 | } | 189 | } |
192 | 190 | ||
193 | table:hover { | 191 | table:hover { |
194 | cursor: pointer; | 192 | cursor: pointer; |
195 | } | 193 | } |
196 | 194 | ||
197 | .inputtitle { | 195 | .inputtitle { |
198 | line-height: 40px; | 196 | line-height: 40px; |
199 | } | 197 | } |
200 | 198 | ||
201 | .shop { | 199 | .shop { |
202 | margin-top: 20px; | 200 | margin-top: 20px; |
203 | } | 201 | } |
204 | 202 | ||
205 | .xz { | 203 | .xz { |
206 | color: blue; | 204 | color: blue; |
207 | } | 205 | } |
208 | 206 | ||
209 | .noData { | 207 | .noData { |
210 | color: #b2b2b2; | 208 | color: #b2b2b2; |
211 | } | 209 | } |
212 | </style> | 210 | </style> | ... | ... |
-
Please register or sign in to post a comment