From 26c1f04f3e47557089d4553c5cebb8a024b37fa4 Mon Sep 17 00:00:00 2001 From: java110 <928255095@qq.com> Date: Mon, 1 Aug 2022 10:51:59 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8A=A0=E5=85=A5=20=E4=B8=9C=E8=8E=9E?= =?UTF-8?q?=E5=B8=82=20=E5=A4=A9=E9=BA=9F=E7=89=A9=E4=B8=9A=20=E6=89=93?= =?UTF-8?q?=E5=8D=B0=E6=94=B6=E6=8D=AE=20=E5=8D=95?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../printPayFeeTianlin.html | 106 +++++++++ .../printPayFeeTianlin/printPayFeeTianlin.js | 205 ++++++++++++++++++ public/print.html | 7 +- 3 files changed, 314 insertions(+), 4 deletions(-) create mode 100644 public/pages/property/printPayFeeTianlin/printPayFeeTianlin.html create mode 100644 public/pages/property/printPayFeeTianlin/printPayFeeTianlin.js diff --git a/public/pages/property/printPayFeeTianlin/printPayFeeTianlin.html b/public/pages/property/printPayFeeTianlin/printPayFeeTianlin.html new file mode 100644 index 000000000..08067b3b4 --- /dev/null +++ b/public/pages/property/printPayFeeTianlin/printPayFeeTianlin.html @@ -0,0 +1,106 @@ +
+
+
+

{{printPayFeeInfo.storeName}}缴费通知单

+
+
小区名称:{{printPayFeeInfo.communityName}}
+
栋号:{{printPayFeeInfo.roomInfo.floorNum}}栋
+
建筑面积:{{printPayFeeInfo.fees && printPayFeeInfo.fees.length>0?printPayFeeInfo.fees[0].area:'无'}}
+
+
+
户主姓名:{{printPayFeeInfo.payObjName}}
+
房号:{{printPayFeeInfo.roomInfo.roomNum}}
+
房屋编号:{{printPayFeeInfo.fees && printPayFeeInfo.fees.length>0?printPayFeeInfo.fees[0].objName:'无'}}
+
+
+
+ +
+
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
{{item.feeName}}{{vc.dateFormat(item.startTime)}}{{vc.dateSubOneDay(vc.dateFormat(item.startTime),vc.dateFormat(item.endTime),item.feeFlag)}}{{item.preDegrees}} -{{item.curDegrees}}-{{item.curDegrees - item.preDegrees}}-m2{{item.squarePrice}}{{item.amount}}
{{vc.changeNumMoneyToChinese(printPayFeeInfo.amount)}} + {{printPayFeeInfo.amount}}
物业费预存日期上期预存0.00预存剩余0.00抵扣预存后应缴{{printPayFeeInfo.amount}}
备注1 +

+ +

+

+
备注2 +

+ +

+
+
+
+
制单人:{{printPayFeeInfo.userName}}
+
复核人:
+
客服管家:
+
缴费方式:{{printPayFeeInfo.fees && printPayFeeInfo.fees.length>0?printPayFeeInfo.fees[0].primeRate:'无'}}
+
+
+
日期:{{vc.dateFormat(new Date())}}
+
+
手机/微信号:
+
实缴日期:{{printPayFeeInfo.feeTime}}
+
+
+
东莞市天麟物业管理有限公司
+
物业服务中心
+
+ +
\ No newline at end of file diff --git a/public/pages/property/printPayFeeTianlin/printPayFeeTianlin.js b/public/pages/property/printPayFeeTianlin/printPayFeeTianlin.js new file mode 100644 index 000000000..4c59818fd --- /dev/null +++ b/public/pages/property/printPayFeeTianlin/printPayFeeTianlin.js @@ -0,0 +1,205 @@ +(function(vc) { + + vc.extends({ + data: { + printPayFeeInfo: { + communityName: '', + receiptId: '', + receiptIds: '', + detailIds: '', + roomName: '', + amount: 0.00, + fees: [], + feeTime: '', + wechatName: '', + content: '', + qrImg: '', + payObjName: '', + feeReceipt: [], + apply: 'N', + userName: vc.getData('/nav/getUserInfo').name, + storeName: '', + roomInfo: { + + } + }, + printFlag: '0' + }, + _initMethod: function() { + //vc.component._initPrintPurchaseApplyDateInfo(); + + $that.printPayFeeInfo.receiptId = vc.getParam('receiptId'); + $that.printPayFeeInfo.receiptIds = vc.getParam('receiptIds'); + $that.printPayFeeInfo.detailIds = vc.getParam('detailIds'); + $that.printPayFeeInfo.apply = vc.getParam('apply'); + + //$that.printPayFeeInfo.feeTime = vc.dateTimeFormat(new Date()); + + $that.printPayFeeInfo.communityName = vc.getCurrentCommunity().name; + + $that._loadReceipt(); + + $that._loadPrintSpec(); + }, + _initEvent: function() { + + + }, + methods: { + _initPayFee: function() { + + }, + _loadReceipt: function() { + + var param = { + params: { + page: 1, + row: 30, + receiptId: $that.printPayFeeInfo.receiptId, + receiptIds: $that.printPayFeeInfo.receiptIds, + detailIds: $that.printPayFeeInfo.detailIds, + communityId: vc.getCurrentCommunity().communityId + } + }; + + //发送get请求 + vc.http.apiGet('/feeReceipt/queryFeeReceipt', + param, + function(json, res) { + var _feeReceiptManageInfo = JSON.parse(json); + let _feeReceipt = _feeReceiptManageInfo.data; + let _amount = 0; + _feeReceipt.forEach(item => { + _amount += parseFloat(item.amount) + }); + + $that.printPayFeeInfo.amount = _amount.toFixed(2); + $that.printPayFeeInfo.roomName = _feeReceipt[0].objName; + $that.printPayFeeInfo.feeTime = _feeReceipt[0].createTime; + $that.printPayFeeInfo.receiptNum = _feeReceipt[0].receiptId; + $that.printPayFeeInfo.payObjName = _feeReceipt[0].payObjName; + $that.printPayFeeInfo.storeName = _feeReceipt[0].storeName; + $that.printPayFeeInfo.feeReceipt = _feeReceipt; + + $that.listRoom(_feeReceipt[0].objId); + + $that._loadReceiptDetail(); + + }, + function(errInfo, error) { + console.log('请求失败处理'); + } + ); + }, + _loadReceiptDetail: function() { + + var param = { + params: { + page: 1, + row: 100, + receiptId: $that.printPayFeeInfo.receiptId, + receiptIds: $that.printPayFeeInfo.receiptIds, + detailIds: $that.printPayFeeInfo.detailIds, + communityId: vc.getCurrentCommunity().communityId + } + }; + + //发送get请求 + vc.http.apiGet('/feeReceipt/queryFeeReceiptDetail', + param, + function(json, res) { + var _feeReceiptManageInfo = JSON.parse(json); + let _feeReceiptDetails = _feeReceiptManageInfo.data; + _feeReceiptDetails.forEach(item => { + $that.printPayFeeInfo.feeReceipt.forEach(im => { + if (item.receiptId == im.receiptId) { + item.objName = im.objName; + item.feeTypeCd = im.feeTypeCd; + } + }) + }) + $that.printPayFeeInfo.fees = _feeReceiptDetails; + + + }, + function(errInfo, error) { + console.log('请求失败处理'); + } + ); + }, + _loadPrintSpec: function() { + var param = { + params: { + page: 1, + row: 1, + specCd: 2020, + communityId: vc.getCurrentCommunity().communityId + } + }; + + //发送get请求 + vc.http.apiGet('/feePrintSpec/queryFeePrintSpec', + param, + function(json, res) { + var _json = JSON.parse(json); + var _data = _json.data; + if (_data.length > 0) { + $that.printPayFeeInfo.content = _data[0].content; + $that.printPayFeeInfo.qrImg = _data[0].qrImg; + if (_data[0].printName) { + $that.printPayFeeInfo.communityName = _data[0].printName; + } + } + }, + function(errInfo, error) { + console.log('请求失败处理'); + } + ); + + }, + + _printPurchaseApplyDiv: function() { + + $that.printFlag = '1'; + console.log('console.log($that.printFlag);', $that.printFlag); + document.getElementById("print-btn").style.display = "none"; //隐藏 + + window.print(); + //$that.printFlag = false; + window.opener = null; + window.close(); + }, + _closePage: function() { + window.opener = null; + window.close(); + }, + + listRoom: function(_roomId) { + let param = { + params: { + page: 1, + row: 1, + communityId: vc.getCurrentCommunity().communityId, + roomId: _roomId + } + }; + //发送get请求 + vc.http.apiGet('/room.queryRooms', + param, + function(json, res) { + let listRoomData = JSON.parse(json); + if (!listRoomData.rooms || listRoomData.rooms.length < 1) { + return; + } + vc.component.printPayFeeInfo.roomInfo = listRoomData.rooms[0]; + }, + function(errInfo, error) { + console.log('请求失败处理'); + } + ); + }, + + } + }); + +})(window.vc); \ No newline at end of file diff --git a/public/print.html b/public/print.html index 9573fd481..501966d5b 100755 --- a/public/print.html +++ b/public/print.html @@ -17,6 +17,7 @@ + @@ -50,11 +51,9 @@
-
+
-
+