【修改】资料网员 成员应收金额修改
This commit is contained in:
@@ -4,6 +4,11 @@
|
|||||||
* */
|
* */
|
||||||
|
|
||||||
export const CalcAmountMixin = {
|
export const CalcAmountMixin = {
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
ysjeKey:'receivableAmount',// 应收金额的表单key值
|
||||||
|
}
|
||||||
|
},
|
||||||
methods:{
|
methods:{
|
||||||
/**
|
/**
|
||||||
* 改变应收金额 计算税额 未税金额
|
* 改变应收金额 计算税额 未税金额
|
||||||
@@ -27,7 +32,7 @@ export const CalcAmountMixin = {
|
|||||||
* */
|
* */
|
||||||
calcAmount(){
|
calcAmount(){
|
||||||
// 获取应收金额
|
// 获取应收金额
|
||||||
let ysje = Number(this.form.getFieldValue('receivableAmount'))
|
let ysje = Number(this.form.getFieldValue(this.ysjeKey))
|
||||||
// 没有输入应收金额 不进行计算
|
// 没有输入应收金额 不进行计算
|
||||||
if(!ysje) return
|
if(!ysje) return
|
||||||
// 获取税率
|
// 获取税率
|
||||||
|
|||||||
@@ -79,20 +79,59 @@
|
|||||||
<a-input
|
<a-input
|
||||||
placeholder="请输入应收金额"
|
placeholder="请输入应收金额"
|
||||||
:maxLength="50"
|
:maxLength="50"
|
||||||
|
@change="changeReceivableAmount"
|
||||||
v-decorator="[
|
v-decorator="[
|
||||||
'amountReceivable',
|
'amountReceivable',
|
||||||
validatorRules.amountReceivable,
|
validatorRules.amountReceivable,
|
||||||
]"
|
]"
|
||||||
@blur="addZero"
|
@blur="addZero"
|
||||||
@change="
|
|
||||||
(e) => {
|
|
||||||
e.target.value = e.target.value.replace(/[^0-9.]/g, '');
|
|
||||||
}
|
|
||||||
"
|
|
||||||
></a-input>
|
></a-input>
|
||||||
<span class="yuan">元</span>
|
<span class="yuan">元</span>
|
||||||
</a-form-item>
|
</a-form-item>
|
||||||
</a-col>
|
</a-col>
|
||||||
|
<a-col :xl="12" :sm="24">
|
||||||
|
<a-form-item label="税率" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||||
|
<j-dict-select-tag @change="changeRate" placeholder="请选择税率" dict-code="rate" :trigger-change="true"
|
||||||
|
v-decorator="['taxRate',validatorRules.taxRate]"></j-dict-select-tag>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
|
<a-col :xl="12" :sm="24">
|
||||||
|
<a-form-item label="税额" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||||
|
<a-row :gutter="10">
|
||||||
|
<a-col :span="20">
|
||||||
|
<a-input placeholder="请输入税额"
|
||||||
|
v-decorator="['tax',validatorRules.tax]"
|
||||||
|
:maxLength='50'
|
||||||
|
@blur="addZero"
|
||||||
|
read-only
|
||||||
|
disabled
|
||||||
|
@change="(e) => {e.target.value = (e.target.value.replace(/[^0-9.]/g,'')).trim()}"></a-input>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="1">元</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
|
||||||
|
<a-col :xl="12" :sm="24">
|
||||||
|
<a-form-item label="未税金额" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||||
|
<a-row :gutter="10">
|
||||||
|
<a-col :span="20">
|
||||||
|
<a-input placeholder="请输入未税金额"
|
||||||
|
v-decorator="['noTaxAmount',validatorRules.noTaxAmount]"
|
||||||
|
:maxLength='50'
|
||||||
|
disabled
|
||||||
|
@blur="addZero"
|
||||||
|
read-only
|
||||||
|
@change="(e) => {e.target.value = (e.target.value.replace(/[^0-9.]/g,'')).trim()}"></a-input>
|
||||||
|
</a-col>
|
||||||
|
<a-col :span="1">元</a-col>
|
||||||
|
</a-row>
|
||||||
|
</a-form-item>
|
||||||
|
</a-col>
|
||||||
|
</a-row>
|
||||||
|
<a-row>
|
||||||
<a-col :xl="12" :sm="24">
|
<a-col :xl="12" :sm="24">
|
||||||
<a-form-item
|
<a-form-item
|
||||||
label="需要发票"
|
label="需要发票"
|
||||||
@@ -232,11 +271,15 @@ import { addZero } from '@/utils/util'
|
|||||||
import { money } from '@/utils/validate'
|
import { money } from '@/utils/validate'
|
||||||
import { checkAssociatedProject } from '@/utils/projectCheck'
|
import { checkAssociatedProject } from '@/utils/projectCheck'
|
||||||
import SelectRevenueContract from '../../../../components/tools/SelectRevenueContract'
|
import SelectRevenueContract from '../../../../components/tools/SelectRevenueContract'
|
||||||
|
import JDictSelectTag from '@comp/dict/JDictSelectTag'
|
||||||
|
import {CalcAmountMixin} from '@/mixins/CalcAmountMixin'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'SafeguardMemberModal',
|
name: 'SafeguardMemberModal',
|
||||||
|
mixins:[CalcAmountMixin],
|
||||||
components: {
|
components: {
|
||||||
JUpload,
|
JUpload,
|
||||||
|
JDictSelectTag,
|
||||||
CompanySelect,
|
CompanySelect,
|
||||||
// ContactManagementModule,
|
// ContactManagementModule,
|
||||||
SelectContacts,
|
SelectContacts,
|
||||||
@@ -245,6 +288,7 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
title: '操作',
|
title: '操作',
|
||||||
|
ysjeKey:'amountReceivable',
|
||||||
width: 800,
|
width: 800,
|
||||||
visible: false,
|
visible: false,
|
||||||
confirmLoading: false,
|
confirmLoading: false,
|
||||||
@@ -294,6 +338,10 @@ export default {
|
|||||||
],
|
],
|
||||||
validateTrigger: ['blur']
|
validateTrigger: ['blur']
|
||||||
},
|
},
|
||||||
|
taxRate: {
|
||||||
|
rules: [{ required: true,message: '请选择税率' }],
|
||||||
|
validateTrigger: 'change',initialValue:'0.06'
|
||||||
|
},
|
||||||
|
|
||||||
chargeNoticeNo: {
|
chargeNoticeNo: {
|
||||||
rules: [{ required: true, message: '请输入收费通知号' }],
|
rules: [{ required: true, message: '请输入收费通知号' }],
|
||||||
@@ -396,6 +444,9 @@ export default {
|
|||||||
'companyContactId',
|
'companyContactId',
|
||||||
'postContactId',
|
'postContactId',
|
||||||
'amountReceivable',
|
'amountReceivable',
|
||||||
|
'taxRate',
|
||||||
|
'tax',
|
||||||
|
'noTaxAmount',
|
||||||
'needInvoice',
|
'needInvoice',
|
||||||
'paymentMethod',
|
'paymentMethod',
|
||||||
'contractNo',
|
'contractNo',
|
||||||
|
|||||||
Reference in New Issue
Block a user