Commit 4d3d78753f56b465cb3fbdcc257d86886a7c5198
1 parent
32694e4b
add 余额明细 接口联调
Showing
1 changed file
with
15 additions
and
8 deletions
pages/rechargeDetail/rechargeDetail.vue
| @@ -146,6 +146,8 @@ | @@ -146,6 +146,8 @@ | ||
| 146 | arrayWay: [], | 146 | arrayWay: [], |
| 147 | index: 0, | 147 | index: 0, |
| 148 | indexWay: 0, | 148 | indexWay: 0, |
| 149 | + kind:'', | ||
| 150 | + type:'', | ||
| 149 | beginDate: currentDate, | 151 | beginDate: currentDate, |
| 150 | overDate: currentDate, | 152 | overDate: currentDate, |
| 151 | orderList: [], | 153 | orderList: [], |
| @@ -234,7 +236,9 @@ | @@ -234,7 +236,9 @@ | ||
| 234 | 236 | ||
| 235 | let data = res.data; | 237 | let data = res.data; |
| 236 | that.kindArray = data; | 238 | that.kindArray = data; |
| 239 | + that.kind = data[0].kind; | ||
| 237 | that.arrayWay = data[0].typeList; | 240 | that.arrayWay = data[0].typeList; |
| 241 | + that.type = data[0].typeList[0].type; | ||
| 238 | console.log(data) | 242 | console.log(data) |
| 239 | 243 | ||
| 240 | }) | 244 | }) |
| @@ -242,21 +246,24 @@ | @@ -242,21 +246,24 @@ | ||
| 242 | bindPickerChange: function(e) { | 246 | bindPickerChange: function(e) { |
| 243 | let that = this; | 247 | let that = this; |
| 244 | that.index = e.detail.value | 248 | that.index = e.detail.value |
| 249 | + that.kind = that.kindArray[that.index].kind; | ||
| 245 | that.arrayWay = that.kindArray[that.index].typeList; | 250 | that.arrayWay = that.kindArray[that.index].typeList; |
| 251 | + that.type = that.kindArray[that.index].typeList[0].type; | ||
| 246 | that.fetchData() | 252 | that.fetchData() |
| 247 | }, | 253 | }, |
| 248 | bindPickerChangeWay: function(e) { | 254 | bindPickerChangeWay: function(e) { |
| 249 | console.log('picker发送选择改变,携带值为', e.detail.value) | 255 | console.log('picker发送选择改变,携带值为', e.detail.value) |
| 250 | - this.indexWay = e.detail.value | ||
| 251 | - that.fetchData() | 256 | + this.indexWay = e.detail.value; |
| 257 | + this.type = that.arrayWay[this.indexWay].type; | ||
| 258 | + this.fetchData() | ||
| 252 | }, | 259 | }, |
| 253 | bindStartDateChange: function(e) { | 260 | bindStartDateChange: function(e) { |
| 254 | this.beginDate = e.detail.value | 261 | this.beginDate = e.detail.value |
| 255 | - that.fetchData() | 262 | + this.fetchData() |
| 256 | }, | 263 | }, |
| 257 | bindEndDateChange: function(e) { | 264 | bindEndDateChange: function(e) { |
| 258 | this.overDate = e.detail.value | 265 | this.overDate = e.detail.value |
| 259 | - that.fetchData() | 266 | + this.fetchData() |
| 260 | }, | 267 | }, |
| 261 | getDate(type) { | 268 | getDate(type) { |
| 262 | const date = new Date(); | 269 | const date = new Date(); |
| @@ -275,8 +282,8 @@ | @@ -275,8 +282,8 @@ | ||
| 275 | getDetailSummary() { | 282 | getDetailSummary() { |
| 276 | let that = this; | 283 | let that = this; |
| 277 | let data = { | 284 | let data = { |
| 278 | - kind: '1', | ||
| 279 | - type: '1', | 285 | + kind: that.kind, |
| 286 | + type: that.type, | ||
| 280 | beginDate: new Date(that.beginDate + " 00:00:00"), | 287 | beginDate: new Date(that.beginDate + " 00:00:00"), |
| 281 | endDate: new Date(that.overDate + " 23:59:59") | 288 | endDate: new Date(that.overDate + " 23:59:59") |
| 282 | }; | 289 | }; |
| @@ -304,8 +311,8 @@ | @@ -304,8 +311,8 @@ | ||
| 304 | let paramsData = { | 311 | let paramsData = { |
| 305 | pageNum: that.page, | 312 | pageNum: that.page, |
| 306 | pageSize: that.pageSize, | 313 | pageSize: that.pageSize, |
| 307 | - kind: '1', | ||
| 308 | - type: '1', | 314 | + kind: that.kind, |
| 315 | + type: that.type, | ||
| 309 | beginDate: new Date(that.beginDate + " 00:00:00"), | 316 | beginDate: new Date(that.beginDate + " 00:00:00"), |
| 310 | endDate: new Date(that.overDate + " 23:59:59") | 317 | endDate: new Date(that.overDate + " 23:59:59") |
| 311 | } | 318 | } |