From 3ab250e7813f4dbc299d4782b0b5309ffd0a7c2d Mon Sep 17 00:00:00 2001
From: java110 <928255095@qq.com>
Date: Wed, 26 Aug 2020 22:57:42 +0800
Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E4=BB=A3=E7=A0=81?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
app.js | 8 +--
.../pages/property/listRoomFee/listRoomFee.js | 1 +
.../property/payFeeOrder/payFeeOrder.html | 42 +++++++++++++--
.../pages/property/payFeeOrder/payFeeOrder.js | 53 +++++++++++++++----
4 files changed, 85 insertions(+), 19 deletions(-)
diff --git a/app.js b/app.js
index 4b4cb0be0..0ba9148d2 100644
--- a/app.js
+++ b/app.js
@@ -34,10 +34,10 @@ let opts = {
//app.use('/callComponent',proxy('https://app.demo.winqi.cn/',opts));
//app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012/',opts));
//app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012',opts));
-//app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012',opts));
-//app.use('/app',proxy('http://api.demo.winqi.cn:8012',opts));
-app.use('/callComponent',proxy('http://192.168.1.16:8012',opts));
-app.use('/app',proxy('http://192.168.1.16:8012',opts));
+app.use('/callComponent',proxy('http://api.demo.winqi.cn:8012',opts));
+app.use('/app',proxy('http://api.demo.winqi.cn:8012',opts));
+//app.use('/callComponent',proxy('http://192.168.1.16:8012',opts));
+//app.use('/app',proxy('http://192.168.1.16:8012',opts));
//app.listen(3000);
app.use(express.json());
diff --git a/public/pages/property/listRoomFee/listRoomFee.js b/public/pages/property/listRoomFee/listRoomFee.js
index a990dde79..e226a0820 100644
--- a/public/pages/property/listRoomFee/listRoomFee.js
+++ b/public/pages/property/listRoomFee/listRoomFee.js
@@ -60,6 +60,7 @@
},
_payFee:function(_fee){
_fee.roomName=$that.listRoomCreateFeeInfo.roomName;
+ _fee.builtUpArea=$that.listRoomCreateFeeInfo.builtUpArea;
vc.jumpToPage('/admin.html#/pages/property/payFeeOrder?'+vc.objToGetParam(_fee));
},
_payFeeHis:function(_fee){
diff --git a/public/pages/property/payFeeOrder/payFeeOrder.html b/public/pages/property/payFeeOrder/payFeeOrder.html
index d726906ae..ba913a1f6 100644
--- a/public/pages/property/payFeeOrder/payFeeOrder.html
+++ b/public/pages/property/payFeeOrder/payFeeOrder.html
@@ -38,15 +38,23 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ style="font-size: 30px;color: red;padding-left:0px;">¥{{_mathCeil(payFeeOrderInfo.totalFeePrice)}}
diff --git a/public/pages/property/payFeeOrder/payFeeOrder.js b/public/pages/property/payFeeOrder/payFeeOrder.js
index 742a4a249..119ab9f63 100644
--- a/public/pages/property/payFeeOrder/payFeeOrder.js
+++ b/public/pages/property/payFeeOrder/payFeeOrder.js
@@ -10,15 +10,19 @@
endTime: '',
feeFlag: '',
feePrice: 0.00,
- cycles: '1',
+ tempCycles: '',
+ cycles: '',
paymentCycles: [],
totalFeePrice: 0.00,
receivedAmount: '',
communityId: vc.getCurrentCommunity().communityId,
- roomName:'',
- squarePrice:'',
- additionalAmount:'',
- remark:''
+ roomName: '',
+ squarePrice: '',
+ additionalAmount: '',
+ remark: '',
+ builtUpArea: 0.0,
+ squarePrice: 0.0,
+ additionalAmount: 0.0
}
},
_initMethod: function () {
@@ -32,6 +36,11 @@
$that.payFeeOrderInfo.roomName = vc.getParam('roomName');
$that.payFeeOrderInfo.squarePrice = vc.getParam('squarePrice');
$that.payFeeOrderInfo.additionalAmount = vc.getParam('additionalAmount');
+ $that.payFeeOrderInfo.builtUpArea = vc.getParam('builtUpArea');
+ $that.payFeeOrderInfo.squarePrice = vc.getParam('squarePrice');
+ $that.payFeeOrderInfo.additionalAmount = vc.getParam('additionalAmount');
+
+
$that.payFeeOrderInfo.paymentCycles = [];
for (let _index = 1; _index < 7; _index++) {
$that.payFeeOrderInfo.paymentCycles.push(_index * vc.getParam('paymentCycle'))
@@ -81,17 +90,26 @@
});
},
_payFee: function (_page, _row) {
+ if ($that.payFeeOrderInfo.tempCycles != "" && $that.payFeeOrderInfo.tempCycles != '-102') {
+ $that.payFeeOrderInfo.cycles = $that.payFeeOrderInfo.tempCycles;
+ }
+ if ($that.payFeeOrderInfo.cycles == "") {
+ $that.payFeeOrderInfo.cycles = '-101';
+ }
if (!vc.component.payFeeValidate()) {
vc.toast(vc.validate.errInfo);
return;
}
+
+
+
let _printFees = [];
_printFees.push({
feeId: $that.payFeeOrderInfo.feeId,
- squarePrice:$that.payFeeOrderInfo.squarePrice,
+ squarePrice: $that.payFeeOrderInfo.squarePrice,
additionalAmount: $that.payFeeOrderInfo.additionalAmount,
feeName: $that.payFeeOrderInfo.feeName,
- amount: $that.payFeeOrderInfo.feePrice
+ amount: $that.payFeeOrderInfo.receivedAmount
});
vc.http.post(
@@ -105,11 +123,11 @@
//vm.menus = vm.refreshMenuActive(JSON.parse(json),0);
if (res.status == 200) {
let _feeInfo = {
- totalAmount: $that.payFeeOrderInfo.feePrice,
+ totalAmount: $that.payFeeOrderInfo.receivedAmount,
fees: _printFees
}
- vc.saveData('_feeInfo',_feeInfo);
+ vc.saveData('_feeInfo', _feeInfo);
//关闭model
$("#payFeeResult").modal({
backdrop: "static",//点击空白处不关闭对话框
@@ -125,11 +143,23 @@
});
},
_changeMonth: function (_cycles) {
- if ('-101' == _cycles) {
+ if ('-102' == _cycles) {
vc.component.payFeeOrderInfo.totalFeePrice = 0.00;
vc.component.payFeeOrderInfo.receivedAmount = '';
return;
}
+ let _newCycles = _cycles;
+
+ if (_cycles == '') {
+ _newCycles = $that.payFeeOrderInfo.paymentCycles[0];
+ }
+ vc.component.payFeeOrderInfo.totalFeePrice = Math.floor(parseFloat(_newCycles) * parseFloat(vc.component.payFeeOrderInfo.feePrice) * 100) / 100;
+ vc.component.payFeeOrderInfo.receivedAmount = vc.component.payFeeOrderInfo.totalFeePrice;
+ },
+ changeCycle:function(_cycles){
+ if(_cycles == ''){
+ return ;
+ }
vc.component.payFeeOrderInfo.totalFeePrice = Math.floor(parseFloat(_cycles) * parseFloat(vc.component.payFeeOrderInfo.feePrice) * 100) / 100;
vc.component.payFeeOrderInfo.receivedAmount = vc.component.payFeeOrderInfo.totalFeePrice;
},
@@ -140,6 +170,9 @@
_printAndBack: function () {
//$('#payFeeResult').modal("hide");
window.open("/print.html#/pages/property/printPayFee?roomName=" + $that.payFeeOrderInfo.roomName)
+ },
+ _mathCeil:function(_price){
+ return Math.ceil(_price);
}
}