|
9 | 9 | fees: [], |
10 | 10 | feeTime: '', |
11 | 11 | wechatName: '', |
12 | | - content:'', |
13 | | - qrImg:'' |
| 12 | + content: '', |
| 13 | + qrImg: '', |
| 14 | + roomId: '', |
| 15 | + builtUpArea: '' |
14 | 16 | }, |
15 | 17 | printFlag: '0' |
16 | 18 | }, |
17 | 19 | _initMethod: function () { |
18 | 20 | //vc.component._initPrintPurchaseApplyDateInfo(); |
19 | 21 |
|
20 | 22 | let _fees = vc.getData('java110_printFee'); |
21 | | - $that.printPayFeeInfo.fees = _fees |
| 23 | + $that.printPayFeeInfo.fees = _fees.fees |
| 24 | + |
| 25 | + $that.printPayFeeInfo.roomId = vc.getParam('roomId') |
| 26 | + $that._printOweRoom(); |
| 27 | + |
22 | 28 | $that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date().getTime()); |
23 | 29 |
|
24 | 30 | $that.printPayFeeInfo.communityName = vc.getCurrentCommunity().name; |
25 | 31 |
|
26 | 32 | let _totalAmount = 0.0; |
27 | | - _fees.forEach(item => { |
| 33 | + $that.printPayFeeInfo.fees.forEach(item => { |
28 | 34 | _totalAmount += item.feePrice; |
29 | 35 | }); |
30 | 36 | _totalAmount = Math.round(_totalAmount * 100) / 100; |
31 | 37 | $that.printPayFeeInfo.feePrices = _totalAmount; |
32 | 38 |
|
33 | | - $that._loadPrintSpec(); |
| 39 | + $that._loadPrintSpec(); |
34 | 40 | }, |
35 | 41 | _initEvent: function () { |
36 | 42 |
|
|
81 | 87 | _closePage: function () { |
82 | 88 | window.opener = null; |
83 | 89 | window.close(); |
| 90 | + }, |
| 91 | + _printOweRoom: function () { |
| 92 | + let param = { |
| 93 | + params: { |
| 94 | + page: 1, |
| 95 | + row: 1, |
| 96 | + roomId: $that.printPayFeeInfo.roomId, |
| 97 | + communityId: vc.getCurrentCommunity().communityId |
| 98 | + } |
| 99 | + }; |
| 100 | + //发送get请求 |
| 101 | + vc.http.get('roomCreateFee', |
| 102 | + 'listRoom', |
| 103 | + param, |
| 104 | + function (json, res) { |
| 105 | + var listRoomData = JSON.parse(json); |
| 106 | + vc.copyObject(listRoomData.rooms[0], $that.printPayFeeInfo); |
| 107 | + if (listRoomData.rooms[0].roomType == '2020602') { |
| 108 | + $that.printPayFeeInfo.roomName = listRoomData.rooms[0].floorNum + '-' + listRoomData.rooms[0].roomNum; |
| 109 | + } else { |
| 110 | + $that.printPayFeeInfo.roomName = listRoomData.rooms[0].floorNum + '-' + listRoomData.rooms[0].unitNum + '-' + listRoomData.rooms[0].roomNum; |
| 111 | + } |
| 112 | + }, function (errInfo, error) { |
| 113 | + console.log('请求失败处理'); |
| 114 | + } |
| 115 | + ); |
| 116 | + |
84 | 117 | } |
85 | 118 | } |
86 | 119 | }); |
|
0 commit comments