[需求变更] 企业联系人添加备注备注,只在管理端的项目详情可查看联系人的备注,企业端和小程序不可查看
This commit is contained in:
@@ -16,7 +16,8 @@
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>应收金额:</label>
|
||||
<span><j-ellipsis :value="`${basicInfo.receivableAmount ? basicInfo.receivableAmount : '0.00'}元`" :length="20"></j-ellipsis></span>
|
||||
<span><j-ellipsis :value="`${basicInfo.receivableAmount ? basicInfo.receivableAmount : '0.00'}元`"
|
||||
:length="20"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
@@ -64,7 +65,7 @@
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人:</label>
|
||||
<span>{{ basicInfo.name }}</span>
|
||||
<span><j-ellipsis :value="basicInfo.name" :length="20"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
@@ -74,7 +75,7 @@
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人职务:</label>
|
||||
<span>{{ basicInfo.post }}</span>
|
||||
<span><j-ellipsis :value="basicInfo.post" :length="17"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
@@ -94,9 +95,108 @@
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人地址:</label>
|
||||
<span><j-ellipsis :value="basicInfo.contactAddress" :length="20"></j-ellipsis></span>
|
||||
<span><j-ellipsis :value="basicInfo.contactAddress" :length="17"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<!-- 工作组项目有企业联系人2、3-->
|
||||
<template v-if="basicInfo.projectType===2">
|
||||
<!-- 企业联系人1的备注-->
|
||||
<template>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人1备注:</label>
|
||||
<span><j-ellipsis :value="basicInfo.remarksOne" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
<!-- 企业联系人2-->
|
||||
<template v-if="basicInfo.nameTwo">
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2:</label>
|
||||
<span><j-ellipsis :value="basicInfo.nameTwo" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<label>企业联系人2性别:</label>
|
||||
<span>{{ basicInfo.genderTwo_dictText }}</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2职务:</label>
|
||||
<span><j-ellipsis :value="basicInfo.postTwo" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2电话:</label>
|
||||
<span>{{ basicInfo.phoneTwo }}</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2邮箱:</label>
|
||||
<span>{{ basicInfo.emailTwo }}</span>
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2邮编:</label>
|
||||
<span>{{ basicInfo.postalCodeContactsTwo }}</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2地址:</label>
|
||||
<span><j-ellipsis :value="basicInfo.contactAddressTwo" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人2备注:</label>
|
||||
<span><j-ellipsis :value="basicInfo.remarksTwo" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
<!-- 企业联系人3-->
|
||||
<template v-if="basicInfo.nameThree">
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3:</label>
|
||||
<span><j-ellipsis :value="basicInfo.nameThree" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
<a-col :span="12">
|
||||
<label>企业联系人3性别:</label>
|
||||
<span>{{ basicInfo.genderThree_dictText }}</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3职务:</label>
|
||||
<span><j-ellipsis :value="basicInfo.postThree" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3电话:</label>
|
||||
<span>{{ basicInfo.phoneThree }}</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3邮箱:</label>
|
||||
<span>{{ basicInfo.emailThree }}</span>
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3邮编:</label>
|
||||
<span>{{ basicInfo.postalCodeContactsThree }}</span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3地址:</label>
|
||||
<span><j-ellipsis :value="basicInfo.contactAddressThree" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>企业联系人3备注:</label>
|
||||
<span><j-ellipsis :value="basicInfo.remarksThree" :length="16"></j-ellipsis></span>
|
||||
</a-col>
|
||||
</a-row>
|
||||
</template>
|
||||
</template>
|
||||
<!-- 工作组项目有企业联系人2、3-->
|
||||
<a-row :gutter="24">
|
||||
<a-col :span="12" class="detail-item">
|
||||
<label>是否需要发票:</label>
|
||||
@@ -305,7 +405,6 @@ export default {
|
||||
console.log('未查到相应的信息')
|
||||
}
|
||||
})
|
||||
|
||||
},
|
||||
handleCancel() {
|
||||
this.visible = false
|
||||
|
||||
@@ -56,10 +56,33 @@
|
||||
v-decorator="['contactsIdTwo',validatorRules.contactsRepeat]"
|
||||
:maxLength='50'
|
||||
ref="selectContacts2"
|
||||
@change="contactsTwoChange"
|
||||
@ok="addContactsTwoOk"></select-contacts>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="备注1" :labelCol="labelCol" :wrapperCol="wrapperCol" v-show="hasContactOne">
|
||||
<a-input
|
||||
placeholder="请输入备注1"
|
||||
v-decorator="['remarksOne']"
|
||||
:maxLength='50'
|
||||
@change="e => {e.target.value = (e.target.value + '').trim()}">
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="备注2" :labelCol="labelCol" :wrapperCol="wrapperCol" v-show="hasContactTwo">
|
||||
<a-input
|
||||
placeholder="请输入备注2"
|
||||
v-decorator="['remarksTwo']"
|
||||
:maxLength='50'
|
||||
@change="e => {e.target.value = (e.target.value + '').trim()}">
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="企业联系人3" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
@@ -69,6 +92,7 @@
|
||||
v-decorator="['contactsIdThree',validatorRules.contactsRepeat]"
|
||||
:maxLength='50'
|
||||
ref="selectContacts3"
|
||||
@change="contactsThreeChange"
|
||||
@ok="addContactsThreeOk"></select-contacts>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
@@ -84,6 +108,18 @@
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="备注3" :labelCol="labelCol" :wrapperCol="wrapperCol" v-show="hasContactThree">
|
||||
<a-input
|
||||
placeholder="请输入备注3"
|
||||
v-decorator="['remarksThree']"
|
||||
:maxLength='50'
|
||||
@change="e => {e.target.value = (e.target.value + '').trim()}">
|
||||
</a-input>
|
||||
</a-form-item>
|
||||
</a-col>
|
||||
</a-row>
|
||||
<a-row>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="来款方式" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
@@ -140,11 +176,11 @@
|
||||
</a-col>
|
||||
<a-col :xl="12" :sm="24">
|
||||
<a-form-item label="合同号" :labelCol="labelCol" :wrapperCol="wrapperCol">
|
||||
<!-- <a-input placeholder="请输入合同号"-->
|
||||
<!-- v-decorator="['contractNum',validatorRules.contractNum]"-->
|
||||
<!-- :maxLength='50'-->
|
||||
<!-- :disabled="isContractNumDisabled || isAssociatedContract"-->
|
||||
<!-- @change="e => {e.target.value = (e.target.value + '').trim()}"></a-input>-->
|
||||
<!-- <a-input placeholder="请输入合同号"-->
|
||||
<!-- v-decorator="['contractNum',validatorRules.contractNum]"-->
|
||||
<!-- :maxLength='50'-->
|
||||
<!-- :disabled="isContractNumDisabled || isAssociatedContract"-->
|
||||
<!-- @change="e => {e.target.value = (e.target.value + '').trim()}"></a-input>-->
|
||||
<select-revenue-contract
|
||||
placeholder="请选择合同号"
|
||||
:company="selectedCompany"
|
||||
@@ -364,6 +400,9 @@ export default {
|
||||
workingGroupList: [],
|
||||
disabledCompany: false, // 企业是否禁用
|
||||
isAssociatedContract: false, // 是否关联合同
|
||||
hasContactOne: false, // 是否选择联系人1
|
||||
hasContactTwo: false, // 是否选择联系人2
|
||||
hasContactThree: false, // 是否选择联系人3
|
||||
url: {
|
||||
add: '/project/payWorkingGroupSubitem/add',
|
||||
edit: '/project/payWorkingGroupSubitem/edit'
|
||||
@@ -420,7 +459,6 @@ export default {
|
||||
checkAssociatedProject(record.id).then(res => {
|
||||
this.disabledCompany = this.disabledChargeCompany || res || (!!record.inAccount && record.inAccount !== 0) || (!!record.makeInvoice && record.makeInvoice !== 0) || (!!record.mail && record.mail !== 0)
|
||||
this.isAssociatedContract = res
|
||||
console.log(this.isContractNumDisabled,this.isAssociatedContract, this.isContractNumDisabled || this.isAssociatedContract, '----------------')
|
||||
})
|
||||
} else {
|
||||
this.disabledCompany = this.disabledChargeCompany
|
||||
@@ -453,12 +491,22 @@ export default {
|
||||
id: this.model.mailContactsTemporaryId,
|
||||
name: this.model.mailContactsTemporaryName
|
||||
}
|
||||
// 是否需要显示联系人备注信息
|
||||
if (this.model.contactsTemporaryIdOne) {
|
||||
this.hasContactOne = true
|
||||
}
|
||||
if (this.model.contactsTemporaryIdTwo) {
|
||||
this.hasContactTwo = true
|
||||
}
|
||||
if (this.model.contactsTemporaryIdThree) {
|
||||
this.hasContactThree = true
|
||||
}
|
||||
}
|
||||
this.chargeWayType = record.chargeWay
|
||||
this.pickChargeNoticeType(record.charge, true)
|
||||
this.visible = true
|
||||
this.$nextTick(() => {
|
||||
this.form.setFieldsValue(pick(this.model, 'chargeCompany', 'contactsIdOne', 'contactsIdTwo', 'contactsIdThree', 'mailContactsId', 'chargeWay', 'charge', 'receivableAmount', 'contractNum', 'receivableAmount', 'chargeNoticeId', 'needInvoice', 'remarks'))
|
||||
this.form.setFieldsValue(pick(this.model, 'chargeCompany', 'contactsIdOne', 'contactsIdTwo', 'contactsIdThree', 'mailContactsId', 'chargeWay', 'charge', 'receivableAmount', 'contractNum', 'receivableAmount', 'chargeNoticeId', 'needInvoice', 'remarks', 'remarksOne', 'remarksTwo', 'remarksThree'))
|
||||
})
|
||||
},
|
||||
close() {
|
||||
@@ -473,6 +521,10 @@ export default {
|
||||
// 清除企业、来款方式、合同号的限制
|
||||
this.isAssociatedContract = false
|
||||
this.disabledCompany = false
|
||||
// 清除联系人备注信息
|
||||
this.hasContactOne = false
|
||||
this.hasContactTwo = false
|
||||
this.hasContactThree = false
|
||||
this.visible = false
|
||||
},
|
||||
handleOk() {
|
||||
@@ -677,6 +729,16 @@ export default {
|
||||
* @param value
|
||||
*/
|
||||
contactsChange(value) {
|
||||
if (!value) {
|
||||
this.hasContactOne = false
|
||||
this.form.setFieldsValue({remarksOne: null})
|
||||
return
|
||||
}
|
||||
this.hasContactOne = true
|
||||
// 判断联系人是否和原来的一致,不一致则清空备注内容
|
||||
if (value !== this.model.contactsTemporaryIdOne) {
|
||||
this.form.setFieldsValue({remarksOne: null})
|
||||
}
|
||||
let mailContact = Object.values(this.form.getFieldValue(['mailContactsId']))[0]
|
||||
// 邮寄联系人非undefined时赋值
|
||||
if (!mailContact) {
|
||||
@@ -685,6 +747,38 @@ export default {
|
||||
this.form.setFieldsValue(pick(this.model, 'mailContactsId'))
|
||||
})
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 企业联系人2变化
|
||||
* @param value
|
||||
*/
|
||||
contactsTwoChange (value) {
|
||||
if (!value) {
|
||||
this.hasContactTwo = false
|
||||
this.form.setFieldsValue({remarksTwo: null})
|
||||
return
|
||||
}
|
||||
this.hasContactTwo = true
|
||||
// 判断联系人是否和原来的一致,不一致则清空备注内容
|
||||
if (value !== this.model.contactsTemporaryIdTwo) {
|
||||
this.form.setFieldsValue({remarksTwo: null})
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 企业联系人3变化
|
||||
* @param value
|
||||
*/
|
||||
contactsThreeChange (value) {
|
||||
if (!value) {
|
||||
this.hasContactThree = false
|
||||
this.form.setFieldsValue({remarksThree: null})
|
||||
return
|
||||
}
|
||||
this.hasContactThree = true
|
||||
// 判断联系人是否和原来的一致,不一致则清空备注内容
|
||||
if (value !== this.model.contactsTemporaryIdThree) {
|
||||
this.form.setFieldsValue({remarksThree: null})
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user