|
@@ -101,7 +101,7 @@
|
|
class="input"
|
|
class="input"
|
|
v-model="params.receiptAmount"
|
|
v-model="params.receiptAmount"
|
|
@blur="changeNumber($event)"
|
|
@blur="changeNumber($event)"
|
|
- type="number"
|
|
|
|
|
|
+ type="text"
|
|
placeholder="请输入收款金额"
|
|
placeholder="请输入收款金额"
|
|
/>
|
|
/>
|
|
</view>
|
|
</view>
|
|
@@ -182,7 +182,6 @@ const defaultParams = {
|
|
smsContent: '', // 收款短信
|
|
smsContent: '', // 收款短信
|
|
payType: null,
|
|
payType: null,
|
|
receiptType: 1, // 收款款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
|
|
receiptType: 1, // 收款款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
|
|
- openid: null, // 微信openid
|
|
|
|
receiptAmount: '', //收款金额
|
|
receiptAmount: '', //收款金额
|
|
handlingFee: '', //手续费
|
|
handlingFee: '', //手续费
|
|
receiptDate: null // 收款时间
|
|
receiptDate: null // 收款时间
|
|
@@ -238,7 +237,6 @@ export default {
|
|
paymentTypeText: '普通款项', // 款项类型显示文案
|
|
paymentTypeText: '普通款项', // 款项类型显示文案
|
|
banksTypeText: '', // 款项类型显示文案
|
|
banksTypeText: '', // 款项类型显示文案
|
|
params: {
|
|
params: {
|
|
- orderFlag:null,
|
|
|
|
smsContent:'', // 收款短信
|
|
smsContent:'', // 收款短信
|
|
payType: null, //付款类型
|
|
payType: null, //付款类型
|
|
receiptType: 1, // 收款款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
|
|
receiptType: 1, // 收款款项类型:1订单款,2非订单款,3返佣款 4订单款或者非订单款(因财务阶段无法区分订单非订单), 5供应商退款
|
|
@@ -247,6 +245,7 @@ export default {
|
|
receiptDate: null // 收款时间
|
|
receiptDate: null // 收款时间
|
|
},
|
|
},
|
|
handleCharge: 0,
|
|
handleCharge: 0,
|
|
|
|
+ handleReceiptAmount: 0,
|
|
isCheckedCharge: false,
|
|
isCheckedCharge: false,
|
|
isReceiptType: false,
|
|
isReceiptType: false,
|
|
contentModalTitle: '',
|
|
contentModalTitle: '',
|
|
@@ -323,7 +322,7 @@ export default {
|
|
const data = response.data
|
|
const data = response.data
|
|
this.params.payType = data.payType
|
|
this.params.payType = data.payType
|
|
this.params.orderFlag = data.orderFlag
|
|
this.params.orderFlag = data.orderFlag
|
|
- this.params.receiptAmount = data.receiptAmount
|
|
|
|
|
|
+ this.params.receiptAmount = this.handleReceiptAmount = data.receiptAmount
|
|
this.params.receiptDate = data.receiptDate
|
|
this.params.receiptDate = data.receiptDate
|
|
this.handleCharge = this.params.handlingFee = data.handlingFee
|
|
this.handleCharge = this.params.handlingFee = data.handlingFee
|
|
this.receiptTypeActions.forEach(el => {
|
|
this.receiptTypeActions.forEach(el => {
|
|
@@ -407,11 +406,11 @@ export default {
|
|
this.receiptType = 2
|
|
this.receiptType = 2
|
|
this.isConfirm = true
|
|
this.isConfirm = true
|
|
this.isReceiptType = false
|
|
this.isReceiptType = false
|
|
|
|
+ this.isCheckedCharge = false
|
|
this.params = Object.assign(this.params, defaultParams)
|
|
this.params = Object.assign(this.params, defaultParams)
|
|
this.params.receiptDate = this.$api.getNowFormatDate()
|
|
this.params.receiptDate = this.$api.getNowFormatDate()
|
|
this.params.payType = this.receiptTypeActions[0].value
|
|
this.params.payType = this.receiptTypeActions[0].value
|
|
this.banksTypeText = this.receiptTypeActions[0].name
|
|
this.banksTypeText = this.receiptTypeActions[0].name
|
|
- this.params.openid = this.openid
|
|
|
|
},
|
|
},
|
|
checkedSms() {
|
|
checkedSms() {
|
|
// 切换款项识别
|
|
// 切换款项识别
|
|
@@ -437,24 +436,29 @@ export default {
|
|
if (this.receiptType == 1) {
|
|
if (this.receiptType == 1) {
|
|
// 短信收款处理勾选手续费
|
|
// 短信收款处理勾选手续费
|
|
if (!this.isCheckedCharge) {
|
|
if (!this.isCheckedCharge) {
|
|
|
|
+ //未勾选手续费
|
|
this.params.handlingFee = 0
|
|
this.params.handlingFee = 0
|
|
- this.params.receiptAmount = this.params.receiptAmount - this.handleCharge
|
|
|
|
|
|
+ this.params.receiptAmount =(this.handleReceiptAmount*100 - this.handleCharge*100)/100
|
|
} else {
|
|
} else {
|
|
|
|
+ //已勾选手续费
|
|
this.params.handlingFee = this.handleCharge
|
|
this.params.handlingFee = this.handleCharge
|
|
- this.params.receiptAmount = this.params.receiptAmount + this.params.handlingFee
|
|
|
|
|
|
+ this.params.receiptAmount =(this.params.receiptAmount*100 + this.params.handlingFee*100)/100
|
|
}
|
|
}
|
|
} else {
|
|
} else {
|
|
// 无短信收款处理勾选手续费计算
|
|
// 无短信收款处理勾选手续费计算
|
|
if (!this.isCheckedCharge) {
|
|
if (!this.isCheckedCharge) {
|
|
- this.params.receiptAmount = this.params.receiptAmount - this.params.handlingFee
|
|
|
|
|
|
+ //未勾选手续费
|
|
|
|
+ console.log('未勾选手续费')
|
|
|
|
+ this.params.receiptAmount =(this.params.receiptAmount*100 - this.params.handlingFee*100)/100
|
|
this.params.handlingFee = ''
|
|
this.params.handlingFee = ''
|
|
} else {
|
|
} else {
|
|
- this.params.receiptAmount = this.params.receiptAmount + this.params.handlingFee
|
|
|
|
|
|
+ //已勾选手续费
|
|
|
|
+ console.log('已勾选手续费')
|
|
|
|
+ this.params.receiptAmount =(this.params.receiptAmount*100 + this.params.handlingFee*100)/100
|
|
}
|
|
}
|
|
}
|
|
}
|
|
},
|
|
},
|
|
handleClick(e) {
|
|
handleClick(e) {
|
|
- // 确认收款
|
|
|
|
// 确认收款
|
|
// 确认收款
|
|
if (e.index == 1) {
|
|
if (e.index == 1) {
|
|
this.getOrderReceiptSave()
|
|
this.getOrderReceiptSave()
|
|
@@ -467,14 +471,14 @@ export default {
|
|
},
|
|
},
|
|
changeNumber(e) {
|
|
changeNumber(e) {
|
|
// 校验输入为数字
|
|
// 校验输入为数字
|
|
- this.params.receiptAmount = this.checkedNumberVal(e.detail.value)
|
|
|
|
|
|
+ this.params.receiptAmount = this.handleReceiptAmount = this.checkedNumberVal(e.detail.value)
|
|
console.log('receiptAmount', this.params.receiptAmount)
|
|
console.log('receiptAmount', this.params.receiptAmount)
|
|
},
|
|
},
|
|
handlingFeeNumber(e) {
|
|
handlingFeeNumber(e) {
|
|
// 校验输入为数字
|
|
// 校验输入为数字
|
|
this.params.handlingFee = Number(this.checkedNumberVal(e.detail.value))
|
|
this.params.handlingFee = Number(this.checkedNumberVal(e.detail.value))
|
|
if (this.isCheckedCharge) {
|
|
if (this.isCheckedCharge) {
|
|
- this.params.receiptAmount = Number(this.params.receiptAmount) + this.params.handlingFee
|
|
|
|
|
|
+ this.params.receiptAmount = (Number(this.params.receiptAmount)*100 + this.params.handlingFee*100)/100
|
|
}
|
|
}
|
|
},
|
|
},
|
|
checkedNumberVal(val) {
|
|
checkedNumberVal(val) {
|
|
@@ -669,7 +673,7 @@ page {
|
|
}
|
|
}
|
|
.section-textarea {
|
|
.section-textarea {
|
|
width: 100%;
|
|
width: 100%;
|
|
- height: 200rpx;
|
|
|
|
|
|
+ height: 220rpx;
|
|
box-sizing: border-box;
|
|
box-sizing: border-box;
|
|
padding: 20rpx;
|
|
padding: 20rpx;
|
|
background: #f7f7f7;
|
|
background: #f7f7f7;
|