Commit 016a6243d3be8f160809a14a161dd38e036762d3
Merge branch 'branch_dev' of http://gitlab.renniting.cn/web_developers/HSpark into branch_dev
Showing
7 changed files
with
647 additions
and
317 deletions
.env.development
... | ... | @@ -2,9 +2,9 @@ |
2 | 2 | ENV = 'development' |
3 | 3 | |
4 | 4 | # base api '/dev-api' |
5 | -#VUE_APP_BASE_API = 'http://test.renniting.cn/bcp/' | |
5 | +VUE_APP_BASE_API = 'http://test.renniting.cn/bcp/' | |
6 | 6 | |
7 | -VUE_APP_BASE_API = 'http://127.0.0.1:8099' | |
7 | +#VUE_APP_BASE_API = 'http://127.0.0.1:8099' | |
8 | 8 | |
9 | 9 | |
10 | 10 | # vue-cli uses the VUE_CLI_BABEL_TRANSPILE_MODULES environment variable, | ... | ... |
src/api/account.js
0 → 100644
1 | +import request from '@/utils/request' | |
2 | + | |
3 | +/** | |
4 | + * 获取车主账户 | |
5 | + * @param param | |
6 | + */ | |
7 | +export function getAcctPersonGroupByAcctType(param) { | |
8 | + return request({ | |
9 | + url: '/personPc/acct/getAcctPersonGroupByAcctType', | |
10 | + method: 'post', | |
11 | + data:param | |
12 | + }) | |
13 | +} | |
14 | +/** | |
15 | + * 分页查询车主支出详情 | |
16 | + * @param param | |
17 | + */ | |
18 | +export function queryAcctPayOutForPage(param) { | |
19 | + return request({ | |
20 | + url: '/personPc/acct/queryAcctPayOutForPage', | |
21 | + method: 'post', | |
22 | + data:param | |
23 | + }) | |
24 | +} | |
25 | +/** | |
26 | + * 分页查询车主收费端充值的收入详情" | |
27 | + * @param param | |
28 | + */ | |
29 | +export function queryCustRechargeFeeStaticMsg(param) { | |
30 | + return request({ | |
31 | + url: '/personPc/acct/queryCustRechargeFeeStaticMsg', | |
32 | + method: 'post', | |
33 | + data:param | |
34 | + }) | |
35 | +} | ... | ... |
src/api/index.js
0 → 100644
1 | +import request from '@/utils/request' | |
2 | + | |
3 | +/** | |
4 | + * 获取车主首页卡片信息 | |
5 | + * @param param | |
6 | + */ | |
7 | +export function getCustIndexBaseInfo(param) { | |
8 | + return request({ | |
9 | + url: '/personPc/index/getCustIndexBaseInfo', | |
10 | + method: 'post', | |
11 | + data:param | |
12 | + }) | |
13 | +} | |
14 | +/** | |
15 | + * 获取车主月支出 | |
16 | + * @param param | |
17 | + */ | |
18 | +export function queryOwnerPayOutByMonth(param) { | |
19 | + return request({ | |
20 | + url: '/personPc/index/queryOwnerPayOutByMonth', | |
21 | + method: 'post', | |
22 | + data:param | |
23 | + }) | |
24 | +} | |
25 | +/** | |
26 | + * 获取车主停车记录 | |
27 | + * @param param | |
28 | + */ | |
29 | +export function queryOwnerParkRecord(param) { | |
30 | + return request({ | |
31 | + url: '/personPc/index/queryOwnerParkRecord', | |
32 | + method: 'post', | |
33 | + data:param | |
34 | + }) | |
35 | +} | ... | ... |
src/filters/index.js
... | ... | @@ -235,3 +235,110 @@ export function payOrderTypeFomatter(row,value){ |
235 | 235 | return '未知'; |
236 | 236 | } |
237 | 237 | }; |
238 | + | |
239 | +/** | |
240 | + * 订单状态 | |
241 | + * @param row | |
242 | + * @param value | |
243 | + * @returns {string} | |
244 | + */ | |
245 | +export function inOutStateFormatter(row, value) { | |
246 | + | |
247 | + let orderState = row.orderState; | |
248 | + //停车状态 10:在场 ,20:离场,30:预订 | |
249 | + let parkState = row.parkState; | |
250 | + if (null == parkState) { | |
251 | + if (null != row.parkOutTime) { | |
252 | + parkState = 20; | |
253 | + } else { | |
254 | + parkState = 10; | |
255 | + } | |
256 | + } | |
257 | + | |
258 | + if (parkState == 10) { | |
259 | + return "在场"; | |
260 | + } | |
261 | + | |
262 | + if (parkState == 20) { | |
263 | + | |
264 | + if (orderState == 52) { | |
265 | + return "欠费"; | |
266 | + } else { | |
267 | + return "离场"; | |
268 | + } | |
269 | + } | |
270 | +}; | |
271 | + | |
272 | +/** | |
273 | + * 停车时长 | |
274 | + * @param row | |
275 | + * @param value | |
276 | + * @returns {*} | |
277 | + */ | |
278 | +export function parkingDurationFormatter (row, value) { | |
279 | + // | |
280 | + let parkState = row.parkState; | |
281 | + if (null == parkState) { | |
282 | + if (null != row.parkOutTime) { | |
283 | + parkState = 20; | |
284 | + } else { | |
285 | + parkState = 10; | |
286 | + } | |
287 | + } | |
288 | + | |
289 | + let inTime = row.parkInTime; | |
290 | + if (parkState == 10) { | |
291 | + let thisTime = new Date().getTime(); | |
292 | + let parkDuration = (thisTime - inTime) / 1000; | |
293 | + return formatSeconds(parkDuration); | |
294 | + } | |
295 | + | |
296 | + | |
297 | + if (value == null) { | |
298 | + return ""; | |
299 | + } else { | |
300 | + return formatSeconds(value); | |
301 | + } | |
302 | +}; | |
303 | +function formatSeconds(value) { | |
304 | + let theTime = parseInt(value);// 秒 | |
305 | + let theTime1 = 0;// 分 | |
306 | + let theTime2 = 0;// 小时 | |
307 | + let theTime3 = 0;//天 | |
308 | + if (theTime < 60) { | |
309 | + return theTime + '秒'; | |
310 | + } | |
311 | + if (theTime > 60) { | |
312 | + theTime1 = parseInt(theTime / 60); | |
313 | + theTime = parseInt(theTime % 60); | |
314 | + | |
315 | + | |
316 | + } | |
317 | + | |
318 | + if (theTime1 > 60) { | |
319 | + theTime2 = parseInt(theTime1 / 60); | |
320 | + theTime1 = parseInt(theTime1 % 60); | |
321 | + } | |
322 | + | |
323 | + if (theTime2 > 24) { | |
324 | + theTime3 = parseInt(theTime2 / 24); | |
325 | + theTime2 = parseInt(theTime2 % 24); | |
326 | + } | |
327 | + | |
328 | + let result = ''; | |
329 | + if (theTime1 == 0 && theTime2 == 0 && theTime3 == 0) { | |
330 | + result = parseInt(theTime) + "秒" | |
331 | + } | |
332 | + | |
333 | + if (theTime1 > 0) { | |
334 | + result = "" + parseInt(theTime1) + "分钟" + result; | |
335 | + } | |
336 | + if (theTime2 > 0) { | |
337 | + result = "" + parseInt(theTime2) + "小时" + result; | |
338 | + } | |
339 | + | |
340 | + if (theTime3 > 0) { | |
341 | + result = "" + parseInt(theTime3) + "天" + result; | |
342 | + } | |
343 | + return result; | |
344 | +}; | ... | ... |
src/views/account/index.vue
... | ... | @@ -10,7 +10,7 @@ |
10 | 10 | </el-col> |
11 | 11 | <el-col :span="12" :offset="4"> |
12 | 12 | <el-row :gutter="16"><el-col :span="24">充值账户(元)</el-col></el-row> |
13 | - <el-row :gutter="16" class="common-color font-size24" style="margin-top: 4px"><el-col :span="24">240.0</el-col></el-row> | |
13 | + <el-row :gutter="16" class="common-color font-size24" style="margin-top: 4px"><el-col :span="24">{{rechargeBalance|fen2Yuan}}</el-col></el-row> | |
14 | 14 | </el-col> |
15 | 15 | </el-row> |
16 | 16 | </el-card> |
... | ... | @@ -23,7 +23,7 @@ |
23 | 23 | </el-col> |
24 | 24 | <el-col :span="12" :offset="4"> |
25 | 25 | <el-row :gutter="16"><el-col :span="24">赠送账户(元)</el-col></el-row> |
26 | - <el-row :gutter="16" class="common-color font-size24" style="margin-top: 4px"><el-col :span="24">140.0</el-col></el-row> | |
26 | + <el-row :gutter="16" class="common-color font-size24" style="margin-top: 4px"><el-col :span="24">{{presentBalance|fen2Yuan}}</el-col></el-row> | |
27 | 27 | </el-col> |
28 | 28 | </el-row> |
29 | 29 | </el-card> |
... | ... | @@ -34,70 +34,114 @@ |
34 | 34 | <el-tabs :tab-position="tabPosition" > |
35 | 35 | <el-tab-pane label="充值记录"> |
36 | 36 | <el-table |
37 | - :data="paytableData" | |
37 | + :data="rechargeTableData" | |
38 | 38 | style="width: 100%;" |
39 | 39 | :show-overflow-tooltip="true"> |
40 | 40 | <el-table-column |
41 | - prop="parkName" | |
41 | + prop="acctType" | |
42 | 42 | label="账户类型" |
43 | 43 | :show-overflow-tooltip="true"> |
44 | + <template slot-scope="scope"> | |
45 | + <span v-if="scope.row.acctType == 1">账户余额</span> | |
46 | + <span v-if="scope.row.acctType == 7">充值赠送</span> | |
47 | + </template> | |
44 | 48 | </el-table-column> |
45 | 49 | <el-table-column |
46 | - prop="license" | |
50 | + prop="rechargeFee" | |
47 | 51 | label="充值金额" |
48 | 52 | :show-overflow-tooltip="true"> |
53 | + <template slot-scope="scope"> | |
54 | + <span>{{(scope.row.rechargeFee) |fen2Yuan}} </span> | |
55 | + </template> | |
49 | 56 | </el-table-column> |
50 | 57 | <el-table-column |
51 | - prop="money" | |
58 | + prop="rechargeBalance" | |
52 | 59 | label="充值后余额"> |
60 | + <template slot-scope="scope"> | |
61 | + <span>{{(scope.row.rechargeBalance) |fen2Yuan}} </span> | |
62 | + </template> | |
53 | 63 | </el-table-column> |
54 | 64 | <el-table-column |
55 | - prop="inTime" | |
65 | + prop="rechargeTime" | |
56 | 66 | label="充值时间" |
57 | 67 | :show-overflow-tooltip="true"> |
68 | + <template slot-scope="scope"> | |
69 | + <span>{{(scope.row.rechargeTime) |string2Date(7)}} </span> | |
70 | + </template> | |
58 | 71 | </el-table-column> |
59 | 72 | </el-table> |
60 | 73 | <el-pagination |
61 | 74 | :page-size="10" |
62 | 75 | :pager-count="11" |
63 | 76 | layout="prev, pager, next" |
64 | - :total="total"> | |
77 | + :total="total" | |
78 | + @size-change="handleSizeChange" | |
79 | + @current-change="handleSizeChange" | |
80 | + @prev-click="handleSizeChange" | |
81 | + @next-click="handleSizeChange"> | |
65 | 82 | </el-pagination> |
66 | 83 | </el-tab-pane> |
67 | 84 | <el-tab-pane label="支出记录"> |
68 | 85 | <el-table |
69 | - :data="outtableData" | |
86 | + :data="payOutTableData" | |
70 | 87 | style="width: 100%;" |
71 | 88 | :show-overflow-tooltip="true"> |
72 | 89 | <el-table-column |
73 | - prop="parkName" | |
90 | + prop="acctType" | |
74 | 91 | label="账户类型" |
75 | 92 | :show-overflow-tooltip="true"> |
93 | + <template slot-scope="scope"> | |
94 | + <span v-if="scope.row.acctType == 1">账户余额</span> | |
95 | + <span v-if="scope.row.acctType == 7">充值赠送</span> | |
96 | + </template> | |
76 | 97 | </el-table-column> |
77 | 98 | <el-table-column |
78 | - prop="license" | |
99 | + prop="tradeFee" | |
79 | 100 | label="交易金额" |
80 | 101 | :show-overflow-tooltip="true"> |
102 | + <template slot-scope="scope"> | |
103 | + <span>{{(scope.row.tradeFee) |fen2Yuan}} </span> | |
104 | + </template> | |
81 | 105 | </el-table-column> |
82 | 106 | <el-table-column |
83 | - prop="money" | |
107 | + prop="tradeBalance" | |
84 | 108 | label="交易后余额"> |
109 | + <template slot-scope="scope"> | |
110 | + <span>{{(scope.row.tradeBalance) |fen2Yuan}} </span> | |
111 | + </template> | |
85 | 112 | </el-table-column> |
86 | 113 | <el-table-column |
87 | - prop="outtype" | |
114 | + prop="tradeDetialType" | |
88 | 115 | label="交易类型"> |
116 | + <template slot-scope="scope"> | |
117 | + <span v-if="scope.row.tradeDetialType == 101">停车支付</span> | |
118 | + <span v-if="scope.row.tradeDetialType == 102">停车预付</span> | |
119 | + <span v-if="scope.row.tradeDetialType == 103">停车补缴</span> | |
120 | + <span v-if="scope.row.tradeDetialType == 104">共享车位</span> | |
121 | + <span v-if="scope.row.tradeDetialType == 201">余额充值</span> | |
122 | + <span v-if="scope.row.tradeDetialType == 202">押金充值</span> | |
123 | + <span v-if="scope.row.tradeDetialType == 301">会员卡购买</span> | |
124 | + <span v-if="scope.row.tradeDetialType == 302">会员卡续费</span> | |
125 | + </template> | |
89 | 126 | </el-table-column> |
90 | 127 | <el-table-column |
91 | - prop="inTime" | |
128 | + prop="tradeTime" | |
92 | 129 | label="交易时间" |
93 | 130 | :show-overflow-tooltip="true"> |
131 | + <template slot-scope="scope"> | |
132 | + <span>{{(scope.row.tradeTime) |string2Date(7)}} </span> | |
133 | + </template> | |
94 | 134 | </el-table-column> |
95 | 135 | </el-table> |
96 | 136 | <el-pagination |
97 | 137 | :page-size="10" |
98 | 138 | :pager-count="21" |
99 | 139 | layout="prev, pager, next" |
100 | - :total="total"> | |
140 | + :total="total2" | |
141 | + @size-change="handleSizeChange2" | |
142 | + @current-change="handleSizeChange2" | |
143 | + @prev-click="handleSizeChange2" | |
144 | + @next-click="handleSizeChange2"> | |
101 | 145 | </el-pagination> |
102 | 146 | </el-tab-pane> |
103 | 147 | </el-tabs> |
... | ... | @@ -111,7 +155,8 @@ |
111 | 155 | import pagination from '@/components/Pagination/index.vue'; |
112 | 156 | import LoadingBar from 'nprogress' // progress bar |
113 | 157 | import 'nprogress/nprogress.css' // progress bar style |
114 | - | |
158 | +import {getAcctPersonGroupByAcctType,queryCustRechargeFeeStaticMsg,queryAcctPayOutForPage} from '@/api/account'; | |
159 | +import {fen2Yuan,string2Date} from '@/filters/index'; | |
115 | 160 | export default { |
116 | 161 | components:{ |
117 | 162 | 'i-pagination': pagination |
... | ... | @@ -121,101 +166,140 @@ export default { |
121 | 166 | }, |
122 | 167 | data() { |
123 | 168 | return { |
169 | + rechargeBalance:0, | |
170 | + presentBalance:0, | |
124 | 171 | list: null, |
125 | 172 | tabPosition:'top', |
126 | 173 | listLoading: true, |
127 | 174 | btnLoading:false, |
128 | 175 | loading:false, |
129 | - paytableData: [ | |
130 | - { | |
131 | - parkName: '个人账户', | |
132 | - license: '21', | |
133 | - money: '31', | |
134 | - inTime: '2019-06-02 09:00:00', | |
135 | - }, | |
136 | - { | |
137 | - parkName: '个人账户', | |
138 | - license: '10', | |
139 | - money: '31', | |
140 | - inTime: '2019-06-02 00:23:00', | |
141 | - }, | |
142 | - { | |
143 | - parkName: '个人账户', | |
144 | - license: '21', | |
145 | - money: '31', | |
146 | - inTime: '2019-06-02 09:00:00', | |
147 | - }, | |
148 | - { | |
149 | - parkName: '个人账户', | |
150 | - license: '10', | |
151 | - money: '31', | |
152 | - inTime: '2019-06-02 00:23:00', | |
153 | - },{ | |
154 | - parkName: '个人账户', | |
155 | - license: '10', | |
156 | - money: '31', | |
157 | - inTime: '2019-06-02 00:23:00', | |
158 | - }, | |
176 | + rechargeTableData: [ | |
159 | 177 | ], |
160 | - outtableData: [ | |
161 | - { | |
162 | - parkName: '个人账户', | |
163 | - license: '21', | |
164 | - money: '31', | |
165 | - outtype: '停车支付', | |
166 | - inTime: '2019-06-02 09:00:00', | |
167 | - }, | |
168 | - { | |
169 | - parkName: '个人账户', | |
170 | - license: '10', | |
171 | - money: '31', | |
172 | - outtype: '停车支付', | |
173 | - inTime: '2019-06-02 00:23:00', | |
174 | - }, | |
175 | - { | |
176 | - parkName: '个人账户', | |
177 | - license: '21', | |
178 | - money: '31', | |
179 | - outtype: '停车支付', | |
180 | - inTime: '2019-06-02 09:00:00', | |
181 | - }, | |
182 | - { | |
183 | - parkName: '个人账户', | |
184 | - license: '10', | |
185 | - money: '31', | |
186 | - outtype: '停车支付', | |
187 | - inTime: '2019-06-02 00:23:00', | |
188 | - }, | |
178 | + payOutTableData: [ | |
189 | 179 | ], |
190 | 180 | /** 分页*/ |
191 | - total: 32, | |
181 | + total: 0, | |
192 | 182 | currentPage: 1, |
193 | 183 | pageSize: 10, |
184 | + total2: 0, | |
185 | + currentPage2: 1, | |
186 | + pageSize2: 10, | |
194 | 187 | } |
195 | 188 | }, |
196 | - computed: { | |
189 | + mounted: function() { | |
190 | + this.getAcctPersonGroupByAcctType(); | |
191 | + this.queryCustRechargeFeeStaticMsg(); | |
192 | + this.queryAcctPayOutForPage(); | |
197 | 193 | }, |
198 | - created() { | |
199 | 194 | |
200 | - }, | |
201 | - mounted:function () { | |
202 | - }, | |
203 | 195 | methods: { |
204 | - queryBtn:function () { | |
205 | - LoadingBar.start(); | |
206 | - this.btnLoading=true; | |
207 | - this.loading = true; | |
196 | + /** | |
197 | + * 获取查询参数 | |
198 | + */ | |
199 | + getQueryParams: function() { | |
200 | + let userInfo = this.$store.state.user.userInfo; | |
201 | + let beginTime = new Date(); | |
202 | + let endTime = new Date(); | |
203 | + beginTime.setFullYear(2017); | |
204 | + | |
205 | + let req = { | |
206 | + beginTime:beginTime, | |
207 | + endTime:endTime, | |
208 | + sysCode:'10003', | |
209 | + custId:userInfo.custId, | |
210 | + // custId:'501519113641649119232',//账户支出 | |
211 | + //custId:'501522943145292840960',//账户充值 | |
212 | + | |
213 | + } | |
214 | + return req; | |
215 | + }, | |
216 | + /** | |
217 | + * 查询车主账户信息 | |
218 | + */ | |
219 | + getAcctPersonGroupByAcctType: function() { | |
220 | + let req = this.getQueryParams(); | |
221 | + getAcctPersonGroupByAcctType(req).then(response =>{ | |
222 | + if(response.code=='8888'){ | |
223 | + let data = response.data; | |
224 | + let rechargeBalance = 0; | |
225 | + let presentBalance = 0; | |
226 | + data.forEach(item=>{ | |
227 | + if(item.acctType == 1){ | |
228 | + rechargeBalance += item.acctBalance; | |
229 | + } | |
230 | + if(item.acctType == 7){ | |
231 | + presentBalance += item.acctBalance; | |
232 | + } | |
233 | + }); | |
234 | + this.rechargeBalance = rechargeBalance; | |
235 | + this.presentBalance = presentBalance; | |
236 | + }else{ | |
237 | + console.log(response); | |
238 | + } | |
208 | 239 | |
240 | + }); | |
209 | 241 | }, |
210 | - /**获取子组件页码方法*/ | |
211 | - handleSizeChange: function(pages) { | |
212 | - this.currentPage = pages.page; | |
213 | - this.pageSize = pages.limit; | |
242 | + /** | |
243 | + * 查询车主充值记录 | |
244 | + */ | |
245 | + queryCustRechargeFeeStaticMsg: function() { | |
246 | + let req = this.getQueryParams(); | |
247 | + req.baseRequest={ | |
248 | + pageNum:this.currentPage, | |
249 | + pageSize:this.pageSize, | |
250 | + }, | |
251 | + queryCustRechargeFeeStaticMsg(req).then(response =>{ | |
252 | + if(response.code=='8888'){ | |
253 | + this.rechargeTableData = response.data.rows; | |
254 | + this.total = response.data.total; | |
255 | + }else{ | |
256 | + console.log(response); | |
257 | + } | |
258 | + | |
259 | + }); | |
260 | + }, | |
261 | + | |
262 | + /** | |
263 | + * 查询车主支出记录 | |
264 | + */ | |
265 | + queryAcctPayOutForPage: function() { | |
266 | + let req = this.getQueryParams(); | |
267 | + | |
268 | + req.baseRequest={ | |
269 | + pageNum:this.currentPage2, | |
270 | + pageSize:this.pageSize2, | |
271 | + }, | |
272 | + queryAcctPayOutForPage (req).then(response =>{ | |
273 | + if(response.code=='8888'){ | |
274 | + this.payOutTableData = response.data.rows; | |
275 | + this.total2 = response.data.total; | |
276 | + }else{ | |
277 | + console.log(response); | |
278 | + } | |
279 | + | |
280 | + }); | |
281 | + }, | |
282 | + // 获取子组件页码方法 | |
283 | + handleSizeChange: function(page) { | |
284 | + console.log(page) | |
285 | + this.currentPage = page; | |
214 | 286 | /** 调用表格数据.*/ |
215 | - this.queryBtn(); | |
287 | + this.queryCustRechargeFeeStaticMsg(); | |
288 | + | |
216 | 289 | }, |
290 | + // 获取子组件页码方法 | |
291 | + handleSizeChange2: function(page) { | |
292 | + console.log(page) | |
293 | + this.currentPage2 = page; | |
294 | + /** 调用表格数据.*/ | |
295 | + this.queryAcctPayOutForPage(); | |
296 | + | |
297 | + }, | |
298 | + | |
299 | + }, | |
300 | + | |
301 | + | |
217 | 302 | |
218 | - } | |
219 | 303 | } |
220 | 304 | </script> |
221 | 305 | <style lang="scss" scoped > | ... | ... |
src/views/dashboard/index.vue
... | ... | @@ -8,10 +8,10 @@ |
8 | 8 | </div> |
9 | 9 | <div class="card-panel-description"> |
10 | 10 | <div class="card-panel-text"> |
11 | - 本月订单: 21 | |
11 | + 本月订单: {{cardData.monthOrderNum}} | |
12 | 12 | </div> |
13 | 13 | <div class="card-panel-text"> |
14 | - 订单总量: 1231 | |
14 | + 订单总量: {{cardData.totalOrderNum}} | |
15 | 15 | </div> |
16 | 16 | </div> |
17 | 17 | </div> |
... | ... | @@ -23,10 +23,10 @@ |
23 | 23 | </div> |
24 | 24 | <div class="card-panel-description"> |
25 | 25 | <div class="card-panel-text"> |
26 | - 可用卡券: 101 | |
26 | + 可用卡券: {{cardData.validCouponNum}} | |
27 | 27 | </div> |
28 | 28 | <div class="card-panel-text"> |
29 | - 卡券总量: 332 | |
29 | + 卡券总量: {{cardData.totalCouponNum}} | |
30 | 30 | </div> |
31 | 31 | </div> |
32 | 32 | </div> |
... | ... | @@ -38,10 +38,10 @@ |
38 | 38 | </div> |
39 | 39 | <div class="card-panel-description"> |
40 | 40 | <div class="card-panel-text"> |
41 | - 可用积分: 21 | |
41 | + 可用积分: {{cardData.validScore}} | |
42 | 42 | </div> |
43 | 43 | <div class="card-panel-text"> |
44 | - 全部积分: 231 | |
44 | + 全部积分: {{cardData.totalScore}} | |
45 | 45 | </div> |
46 | 46 | </div> |
47 | 47 | </div> |
... | ... | @@ -115,158 +115,230 @@ |
115 | 115 | style="width: 100%;" |
116 | 116 | :show-overflow-tooltip="true"> |
117 | 117 | <el-table-column |
118 | - prop="parkName" | |
118 | + prop="plName" | |
119 | 119 | label="停车场" |
120 | 120 | :show-overflow-tooltip="true"> |
121 | 121 | </el-table-column> |
122 | 122 | <el-table-column |
123 | - prop="license" | |
123 | + prop="carNumber" | |
124 | 124 | label="车牌" |
125 | 125 | :show-overflow-tooltip="true"> |
126 | 126 | </el-table-column> |
127 | 127 | <el-table-column |
128 | - prop="money" | |
128 | + prop="orderActFee" | |
129 | 129 | label="停车费"> |
130 | + <template slot-scope="scope"> | |
131 | + <span>{{(scope.row.orderActFee) |fen2Yuan}} </span> | |
132 | + </template> | |
130 | 133 | </el-table-column> |
131 | 134 | <el-table-column |
132 | - prop="inTime" | |
135 | + prop="parkInTime" | |
133 | 136 | label="入场时间" |
134 | 137 | :show-overflow-tooltip="true"> |
138 | + <template slot-scope="scope"> | |
139 | + <span>{{(scope.row.parkInTime) |string2Date(7)}} </span> | |
140 | + </template> | |
135 | 141 | </el-table-column> |
136 | 142 | <el-table-column |
137 | - prop="outTime" | |
143 | + prop="parkOutTime" | |
138 | 144 | label="出场时间" |
139 | 145 | :show-overflow-tooltip="true"> |
146 | + <template slot-scope="scope"> | |
147 | + <span>{{(scope.row.parkOutTime) |string2Date(7)}} </span> | |
148 | + </template> | |
140 | 149 | </el-table-column> |
141 | 150 | <el-table-column |
142 | - prop="duration" | |
151 | + prop="parkingDuration" | |
143 | 152 | label="停车时长" |
144 | 153 | :show-overflow-tooltip="true"> |
154 | + <template slot-scope="scope"> | |
155 | + <span>{{(scope.row) |parkingDurationFormatter(scope.row.parkingDuration)}} </span> | |
156 | + </template> | |
145 | 157 | </el-table-column> |
146 | 158 | <el-table-column |
147 | - prop="berthNum" | |
159 | + prop="berthNo" | |
148 | 160 | label="泊位编号"> |
149 | 161 | </el-table-column> |
150 | 162 | <el-table-column |
151 | - prop="status" | |
163 | + prop="orderState" | |
152 | 164 | label="订单状态"> |
165 | + <template slot-scope="scope"> | |
166 | + <span>{{(scope.row) |inOutStateFormatter}} </span> | |
167 | + </template> | |
153 | 168 | </el-table-column> |
154 | 169 | </el-table> |
155 | 170 | <el-pagination |
156 | 171 | :page-size="10" |
157 | 172 | :pager-count="11" |
158 | 173 | layout="prev, pager, next" |
159 | - :total="total"> | |
174 | + :total="total" | |
175 | + @size-change="handleSizeChange" | |
176 | + @current-change="handleSizeChange" | |
177 | + @prev-click="handleSizeChange" | |
178 | + @next-click="handleSizeChange" | |
179 | + > | |
160 | 180 | </el-pagination> |
161 | 181 | </div> |
162 | 182 | </div> |
163 | 183 | </template> |
164 | 184 | |
165 | 185 | <script> |
166 | -import { mapGetters } from 'vuex' | |
167 | - | |
168 | -export default { | |
169 | - name: 'Dashboard', | |
170 | - computed: { | |
171 | - ...mapGetters([ | |
172 | - 'name' | |
173 | - ]) | |
174 | - }, | |
175 | - data() { | |
176 | - return { | |
177 | - total: 15, | |
178 | - currentPage: 1, | |
179 | - pageSize: 10, | |
180 | - moneyData: [{ | |
181 | - name: '消费金额', | |
182 | - january: '123411', | |
183 | - february: '9787162', | |
184 | - march: '123097', | |
185 | - april: '82713', | |
186 | - may: '1239789', | |
187 | - june: '81273', | |
188 | - july: '129387', | |
189 | - august: '1298778', | |
190 | - september: '1239878', | |
191 | - october: '76765', | |
192 | - november: '123124', | |
193 | - december: '12341' | |
194 | - }], | |
195 | - orderData: [ | |
196 | - { | |
197 | - parkName: '承德老二中停车场', | |
198 | - license: '冀H7517732', | |
199 | - money: '31', | |
200 | - inTime: '2019-06-02 00:00:00', | |
201 | - outTime: '2019-06-01 08:00:00', | |
202 | - duration: '2小时28分钟43秒', | |
203 | - berthNum: 'A1212231', | |
204 | - status: '完成' | |
205 | - }, | |
206 | - { | |
207 | - parkName: '承德老二中停车场', | |
208 | - license: '冀H7517732', | |
209 | - money: '31', | |
210 | - inTime: '2019-06-02 00:00:00', | |
211 | - outTime: '2019-06-01 08:00:00', | |
212 | - duration: '2小时28分钟43秒', | |
213 | - berthNum: 'A1212231', | |
214 | - status: '完成' | |
215 | - }, | |
216 | - { | |
217 | - parkName: '承德老二中停车场', | |
218 | - license: '冀H7517732', | |
219 | - money: '31', | |
220 | - inTime: '2019-06-02 00:00:00', | |
221 | - outTime: '2019-06-01 08:00:00', | |
222 | - duration: '2小时28分钟43秒', | |
223 | - berthNum: 'A1212231', | |
224 | - status: '完成' | |
225 | - }, | |
226 | - { | |
227 | - parkName: '承德老二中停车场', | |
228 | - license: '冀H7517732', | |
229 | - money: '31', | |
230 | - inTime: '2019-06-02 00:00:00', | |
231 | - outTime: '2019-06-01 08:00:00', | |
232 | - duration: '2小时28分钟43秒', | |
233 | - berthNum: 'A1212231', | |
234 | - status: '完成' | |
235 | - }, | |
236 | - { | |
237 | - parkName: '承德老二中停车场', | |
238 | - license: '冀H7517732', | |
239 | - money: '31', | |
240 | - inTime: '2019-06-02 00:00:00', | |
241 | - outTime: '2019-06-01 08:00:00', | |
242 | - duration: '2小时28分钟43秒', | |
243 | - berthNum: 'A1212231', | |
244 | - status: '完成' | |
186 | + import { mapGetters } from 'vuex' | |
187 | + import {getCustIndexBaseInfo,queryOwnerPayOutByMonth,queryOwnerParkRecord} from '@/api/index'; | |
188 | + import {fen2Yuan,string2Date,inOutStateFormatter,parkingDurationFormatter} from '@/filters/index'; | |
189 | + export default { | |
190 | + name: 'Dashboard', | |
191 | + computed: { | |
192 | + ...mapGetters([ | |
193 | + 'name' | |
194 | + ]) | |
195 | + }, | |
196 | + data() { | |
197 | + return { | |
198 | + cardData: { | |
199 | + totalOrderNum: 0, | |
200 | + monthOrderNum: 0, | |
201 | + totalCouponNum: 0, | |
202 | + validCouponNum: 0, | |
203 | + totalScore: 0, | |
204 | + validScore: 0, | |
245 | 205 | }, |
246 | - { | |
247 | - parkName: '承德老二中停车场', | |
248 | - license: '冀H7517732', | |
249 | - money: '31', | |
250 | - inTime: '2019-06-02 00:00:00', | |
251 | - outTime: '2019-06-01 08:00:00', | |
252 | - duration: '2小时28分钟43秒', | |
253 | - berthNum: 'A1212231', | |
254 | - status: '完成' | |
255 | - }, | |
256 | - { | |
257 | - parkName: '承德老二中停车场', | |
258 | - license: '冀H7517732', | |
259 | - money: '31', | |
260 | - inTime: '2019-06-02 00:00:00', | |
261 | - outTime: '2019-06-01 08:00:00', | |
262 | - duration: '2小时28分钟43秒', | |
263 | - berthNum: 'A1212231', | |
264 | - status: '完成' | |
206 | + total: 15, | |
207 | + currentPage: 1, | |
208 | + pageSize: 10, | |
209 | + moneyData: [{ | |
210 | + name: '消费金额', | |
211 | + january: '0', | |
212 | + february: '0', | |
213 | + march: '0', | |
214 | + april: '0', | |
215 | + may: '0', | |
216 | + june: '0', | |
217 | + july: '0', | |
218 | + august: '0', | |
219 | + september: '0', | |
220 | + october: '0', | |
221 | + november: '0', | |
222 | + december: '0' | |
223 | + }], | |
224 | + orderData: [], | |
225 | + } | |
226 | + }, | |
227 | + | |
228 | + mounted: function() { | |
229 | + this.getCustIndexBaseInfo(); | |
230 | + this.queryOwnerPayOutByMonth(); | |
231 | + this.queryOwnerParkRecord(); | |
232 | + }, | |
233 | + | |
234 | + methods: { | |
235 | + /** | |
236 | + * 获取查询参数 | |
237 | + */ | |
238 | + getQueryParams: function() { | |
239 | + let userInfo = this.$store.state.user.userInfo; | |
240 | + let beginTime = new Date(); | |
241 | + let endTime = new Date(); | |
242 | + beginTime.setMonth(0); | |
243 | + beginTime.setDate(1); | |
244 | + endTime.setMonth(11); | |
245 | + endTime.setDate(31); | |
246 | + | |
247 | + let req = { | |
248 | + custId:userInfo.custId, | |
249 | + //custId:'501519113641649119232', | |
250 | + beginTime:beginTime, | |
251 | + endTime:endTime, | |
252 | + } | |
253 | + return req; | |
254 | + }, | |
255 | + /** | |
256 | + * 查询首页卡片信息 | |
257 | + */ | |
258 | + getCustIndexBaseInfo: function() { | |
259 | + let req = this.getQueryParams(); | |
260 | + getCustIndexBaseInfo(req).then(response =>{ | |
261 | + if(response.code=='8888'){ | |
262 | + let data = response.data; | |
263 | + this.cardData.totalOrderNum = data.totalOrderNum == null ? 0: data.totalOrderNum; | |
264 | + this.cardData.monthOrderNum = data.monthOrderNum == null ? 0: data.monthOrderNum; | |
265 | + this.cardData.totalCouponNum = data.totalCouponNum == null ? 0: data.totalCouponNum; | |
266 | + this.cardData.validCouponNum = data.validCouponNum == null ? 0: data.validCouponNum; | |
267 | + this.cardData.totalScore = data.totalScore == null ? 0: data.totalScore; | |
268 | + this.cardData.validScore = data.validScore == null ? 0: data.validScore; | |
269 | + }else{ | |
270 | + console.log(response); | |
271 | + } | |
272 | + | |
273 | + }); | |
274 | + }, | |
275 | + /** | |
276 | + * 查询首页月支出信息 | |
277 | + */ | |
278 | + queryOwnerPayOutByMonth: function() { | |
279 | + let req = this.getQueryParams(); | |
280 | + | |
281 | + queryOwnerPayOutByMonth(req).then(response =>{ | |
282 | + if(response.code=='8888'){ | |
283 | + let data = response.data; | |
284 | + this.moneyData[0].january = fen2Yuan(data[0].fee); | |
285 | + this.moneyData[0]. february = fen2Yuan(data[1].fee); | |
286 | + this.moneyData[0]. march = fen2Yuan(data[2].fee); | |
287 | + this.moneyData[0]. april = fen2Yuan(data[3].fee); | |
288 | + this.moneyData[0]. may = fen2Yuan(data[4].fee); | |
289 | + this.moneyData[0]. june = fen2Yuan(data[5].fee); | |
290 | + this.moneyData[0]. july = fen2Yuan(data[6].fee); | |
291 | + this.moneyData[0]. august = fen2Yuan(data[7].fee); | |
292 | + this.moneyData[0]. september = fen2Yuan(data[8].fee); | |
293 | + this.moneyData[0]. october = fen2Yuan(data[9].fee); | |
294 | + this.moneyData[0]. november =fen2Yuan( data[10].fee); | |
295 | + this.moneyData[0]. december = fen2Yuan(data[11].fee); | |
296 | + | |
297 | + }else{ | |
298 | + console.log(response); | |
299 | + } | |
300 | + | |
301 | + }); | |
302 | + }, | |
303 | + | |
304 | + /** | |
305 | + * 查询首页订单信息 | |
306 | + */ | |
307 | + queryOwnerParkRecord: function() { | |
308 | + let req = this.getQueryParams(); | |
309 | + //查询最近三个月的 | |
310 | + let beginTime = new Date(); | |
311 | + let endTime = new Date(); | |
312 | + beginTime.setMonth(beginTime.getMonth() - 3); | |
313 | + req.beginTime = beginTime; | |
314 | + req.endTime = endTime; | |
315 | + req.baseRequest={ | |
316 | + pageNum:this.currentPage, | |
317 | + pageSize:this.pageSize, | |
265 | 318 | }, |
266 | - ] | |
267 | - } | |
319 | + queryOwnerParkRecord (req).then(response =>{ | |
320 | + if(response.code=='8888'){ | |
321 | + this.orderData = response.data.dataList; | |
322 | + this.total = response.data.pageTotals; | |
323 | + }else{ | |
324 | + console.log(response); | |
325 | + } | |
326 | + | |
327 | + }); | |
328 | + }, | |
329 | + // 获取子组件页码方法 | |
330 | + handleSizeChange: function(page) { | |
331 | + console.log(page) | |
332 | + this.currentPage = page; | |
333 | + /** 调用表格数据.*/ | |
334 | + this.queryOwnerParkRecord(); | |
335 | + | |
336 | + }, | |
337 | + | |
338 | + | |
339 | + }, | |
340 | + | |
268 | 341 | } |
269 | -} | |
270 | 342 | </script> |
271 | 343 | |
272 | 344 | <style lang="scss" scoped> | ... | ... |
src/views/order/index.vue
... | ... | @@ -3,30 +3,30 @@ |
3 | 3 | <div class="serch-wrap"> |
4 | 4 | <el-row :gutter="20"> |
5 | 5 | <el-form ref="form" :model="form" label-width="60px" label-position="left"> |
6 | - <el-col :xs="8" :sm="6" :md="7" :lg="7" :xl="1"> | |
6 | + <!--<el-col :xs="8" :sm="6" :md="7" :lg="7" :xl="1">--> | |
7 | 7 | |
8 | - <el-form-item label="停车场"> | |
9 | - <el-select v-model="form.region" placeholder="请选择停车场"> | |
10 | - <el-option label="停车场BA" value="shanghai"/> | |
11 | - <el-option label="停车场" value="beijing"/> | |
12 | - </el-select> | |
13 | - </el-form-item> | |
8 | + <!--<el-form-item label="停车场">--> | |
9 | + <!--<el-select v-model="form.plNos" placeholder="请选择停车场">--> | |
10 | + <!--<el-option label="停车场BA" value="shanghai"/>--> | |
11 | + <!--<el-option label="停车场" value="beijing"/>--> | |
12 | + <!--</el-select>--> | |
13 | + <!--</el-form-item>--> | |
14 | 14 | |
15 | - </el-col> | |
15 | + <!--</el-col>--> | |
16 | 16 | <el-col :xs="8" :sm="6" :md="7" :lg="7" :xl="1"> |
17 | 17 | <el-form-item label="车牌"> |
18 | - <el-input v-model="form.name" maxlength="10" /> | |
18 | + <el-input v-model="form.carNum" maxlength="10" /> | |
19 | 19 | </el-form-item> |
20 | 20 | </el-col> |
21 | - <el-col :xs="8" :sm="6" :md="7" :lg="7" :xl="1"> | |
22 | - <el-form-item label="类型"> | |
23 | - <el-select v-model="form.region" placeholder="请选择类型"> | |
24 | - <el-option label="室内停车场" value="shanghai"/> | |
25 | - <el-option label="路侧停车场" value="beijing"/> | |
26 | - </el-select> | |
27 | - </el-form-item> | |
28 | - </el-col> | |
29 | - <el-col :xs="8" :sm="6" :md="3" :lg="3" :xl="1"> | |
21 | + <!--<el-col :xs="8" :sm="6" :md="7" :lg="7" :xl="1">--> | |
22 | + <!--<el-form-item label="类型">--> | |
23 | + <!--<el-select v-model="form.region" placeholder="请选择类型">--> | |
24 | + <!--<el-option label="室内停车场" value="shanghai"/>--> | |
25 | + <!--<el-option label="路侧停车场" value="beijing"/>--> | |
26 | + <!--</el-select>--> | |
27 | + <!--</el-form-item>--> | |
28 | + <!--</el-col>--> | |
29 | + <el-col :xs="8" :sm="6" :md="3" :lg="3" :xl="1" > | |
30 | 30 | <el-button type="primary" @click="onSubmit">查询</el-button> |
31 | 31 | </el-col> |
32 | 32 | </el-form> |
... | ... | @@ -40,147 +40,144 @@ |
40 | 40 | style="width: 100%;" |
41 | 41 | :show-overflow-tooltip="true"> |
42 | 42 | <el-table-column |
43 | - prop="parkName" | |
43 | + prop="plName" | |
44 | 44 | label="停车场" |
45 | 45 | :show-overflow-tooltip="true"> |
46 | 46 | </el-table-column> |
47 | 47 | <el-table-column |
48 | - prop="license" | |
48 | + prop="carNumber" | |
49 | 49 | label="车牌" |
50 | 50 | :show-overflow-tooltip="true"> |
51 | 51 | </el-table-column> |
52 | 52 | <el-table-column |
53 | - prop="money" | |
53 | + prop="orderActFee" | |
54 | 54 | label="停车费"> |
55 | + <template slot-scope="scope"> | |
56 | + <span>{{(scope.row.orderActFee) |fen2Yuan}} </span> | |
57 | + </template> | |
55 | 58 | </el-table-column> |
56 | 59 | <el-table-column |
57 | - prop="inTime" | |
58 | - label="进场时间" | |
60 | + prop="parkInTime" | |
61 | + label="入场时间" | |
59 | 62 | :show-overflow-tooltip="true"> |
63 | + <template slot-scope="scope"> | |
64 | + <span>{{(scope.row.parkInTime) |string2Date(7)}} </span> | |
65 | + </template> | |
60 | 66 | </el-table-column> |
61 | 67 | <el-table-column |
62 | - prop="outTime" | |
68 | + prop="parkOutTime" | |
63 | 69 | label="出场时间" |
64 | 70 | :show-overflow-tooltip="true"> |
71 | + <template slot-scope="scope"> | |
72 | + <span>{{(scope.row.parkOutTime) |string2Date(7)}} </span> | |
73 | + </template> | |
65 | 74 | </el-table-column> |
66 | 75 | <el-table-column |
67 | - prop="duration" | |
76 | + prop="parkingDuration" | |
68 | 77 | label="停车时长" |
69 | 78 | :show-overflow-tooltip="true"> |
79 | + <template slot-scope="scope"> | |
80 | + <span>{{(scope.row) |parkingDurationFormatter(scope.row.parkingDuration)}} </span> | |
81 | + </template> | |
70 | 82 | </el-table-column> |
71 | 83 | <el-table-column |
72 | - prop="berthNum" | |
84 | + prop="berthNo" | |
73 | 85 | label="泊位编号"> |
74 | 86 | </el-table-column> |
75 | 87 | <el-table-column |
76 | - prop="status" | |
88 | + prop="orderState" | |
77 | 89 | label="订单状态"> |
90 | + <template slot-scope="scope"> | |
91 | + <span>{{(scope.row) |inOutStateFormatter}} </span> | |
92 | + </template> | |
78 | 93 | </el-table-column> |
79 | 94 | </el-table> |
80 | 95 | <el-pagination |
81 | 96 | :page-size="10" |
82 | 97 | :pager-count="11" |
83 | 98 | layout="prev, pager, next" |
84 | - :total="total"> | |
99 | + :total="total" | |
100 | + @size-change="handleSizeChange" | |
101 | + @current-change="handleSizeChange" | |
102 | + @prev-click="handleSizeChange" | |
103 | + @next-click="handleSizeChange" | |
104 | + > | |
85 | 105 | </el-pagination> |
86 | 106 | </div> |
87 | 107 | </div> |
88 | 108 | </template> |
89 | 109 | |
90 | 110 | <script> |
111 | + import {queryOwnerParkRecord} from '@/api/index'; | |
112 | + import {fen2Yuan,string2Date,inOutStateFormatter,parkingDurationFormatter} from '@/filters/index'; | |
91 | 113 | export default { |
92 | 114 | data() { |
93 | 115 | return { |
94 | 116 | form: { |
95 | - name: '', | |
96 | - region: '', | |
97 | - date1: '', | |
98 | - date2: '', | |
99 | - delivery: false, | |
100 | - type: [], | |
101 | - resource: '', | |
102 | - desc: '' | |
117 | + plNos: null, | |
118 | + carNum: null, | |
119 | + | |
103 | 120 | }, |
104 | - total: 55, | |
121 | + total: 0, | |
105 | 122 | currentPage: 1, |
106 | 123 | pageSize: 10, |
107 | 124 | orderData: [ |
108 | - { | |
109 | - parkName: '承德老二中停车场', | |
110 | - license: '冀H7517732', | |
111 | - money: '31', | |
112 | - inTime: '2019-06-02 00:00:00', | |
113 | - outTime: '2019-06-01 08:00:00', | |
114 | - duration: '2小时28分钟43秒', | |
115 | - berthNum: 'A1212231', | |
116 | - status: '完成' | |
117 | - }, | |
118 | - { | |
119 | - parkName: '承德老二中停车场', | |
120 | - license: '冀H7517732', | |
121 | - money: '31', | |
122 | - inTime: '2019-06-02 00:00:00', | |
123 | - outTime: '2019-06-01 08:00:00', | |
124 | - duration: '2小时28分钟43秒', | |
125 | - berthNum: 'A1212231', | |
126 | - status: '完成' | |
127 | - }, | |
128 | - { | |
129 | - parkName: '承德老二中停车场', | |
130 | - license: '冀H7517732', | |
131 | - money: '31', | |
132 | - inTime: '2019-06-02 00:00:00', | |
133 | - outTime: '2019-06-01 08:00:00', | |
134 | - duration: '2小时28分钟43秒', | |
135 | - berthNum: 'A1212231', | |
136 | - status: '完成' | |
137 | - }, | |
138 | - { | |
139 | - parkName: '承德老二中停车场', | |
140 | - license: '冀H7517732', | |
141 | - money: '31', | |
142 | - inTime: '2019-06-02 00:00:00', | |
143 | - outTime: '2019-06-01 08:00:00', | |
144 | - duration: '2小时28分钟43秒', | |
145 | - berthNum: 'A1212231', | |
146 | - status: '完成' | |
147 | - }, | |
148 | - { | |
149 | - parkName: '承德老二中停车场', | |
150 | - license: '冀H7517732', | |
151 | - money: '31', | |
152 | - inTime: '2019-06-02 00:00:00', | |
153 | - outTime: '2019-06-01 08:00:00', | |
154 | - duration: '2小时28分钟43秒', | |
155 | - berthNum: 'A1212231', | |
156 | - status: '完成' | |
157 | - }, | |
158 | - { | |
159 | - parkName: '承德老二中停车场', | |
160 | - license: '冀H7517732', | |
161 | - money: '31', | |
162 | - inTime: '2019-06-02 00:00:00', | |
163 | - outTime: '2019-06-01 08:00:00', | |
164 | - duration: '2小时28分钟43秒', | |
165 | - berthNum: 'A1212231', | |
166 | - status: '完成' | |
167 | - }, | |
168 | - { | |
169 | - parkName: '承德老二中停车场', | |
170 | - license: '冀H7517732', | |
171 | - money: '31', | |
172 | - inTime: '2019-06-02 00:00:00', | |
173 | - outTime: '2019-06-01 08:00:00', | |
174 | - duration: '2小时28分钟43秒', | |
175 | - berthNum: 'A1212231', | |
176 | - status: '完成' | |
177 | - }, | |
178 | 125 | ] |
179 | 126 | } |
180 | 127 | }, |
128 | + mounted: function() { | |
129 | + | |
130 | + this.queryOwnerParkRecord(); | |
131 | + }, | |
181 | 132 | methods: { |
133 | + /** | |
134 | + * 获取查询参数 | |
135 | + */ | |
136 | + getQueryParams: function() { | |
137 | + let userInfo = this.$store.state.user.userInfo; | |
138 | + let plNos = []; | |
139 | + if(this.form.plNos != null && this.form.plNos != ''){ | |
140 | + plNos.push(this.form.plNos); | |
141 | + } | |
142 | + let req = { | |
143 | + custId:userInfo.custId, | |
144 | + // custId:'501519113641649119232', | |
145 | + plNos:plNos, | |
146 | + carNum:this.form.carNum, | |
147 | + } | |
148 | + return req; | |
149 | + }, | |
150 | + /** | |
151 | + * 查询订单信息 | |
152 | + */ | |
153 | + queryOwnerParkRecord: function() { | |
154 | + let req = this.getQueryParams(); | |
155 | + | |
156 | + req.baseRequest={ | |
157 | + pageNum:this.currentPage, | |
158 | + pageSize:this.pageSize, | |
159 | + }, | |
160 | + queryOwnerParkRecord (req).then(response =>{ | |
161 | + if(response.code=='8888'){ | |
162 | + this.orderData = response.data.dataList; | |
163 | + this.total = response.data.pageTotals; | |
164 | + }else{ | |
165 | + console.log(response); | |
166 | + } | |
167 | + | |
168 | + }); | |
169 | + }, | |
170 | + // 获取子组件页码方法 | |
171 | + handleSizeChange: function(page) { | |
172 | + console.log(page) | |
173 | + this.currentPage = page; | |
174 | + /** 调用表格数据.*/ | |
175 | + this.queryOwnerParkRecord(); | |
176 | + | |
177 | + }, | |
178 | + | |
182 | 179 | onSubmit() { |
183 | - this.$message('submit!') | |
180 | + this.queryOwnerParkRecord(); | |
184 | 181 | }, |
185 | 182 | onCancel() { |
186 | 183 | this.$message({ | ... | ... |