0120bug
This commit is contained in:
@@ -490,13 +490,15 @@ export default {
|
||||
applicantEvidence: [], //申请人证据
|
||||
respondentEvidence: [], //被申请人证据
|
||||
buttonFlag: true,
|
||||
getUserInfoList: {}
|
||||
getUserInfoList: {},
|
||||
applicationFlag: null
|
||||
};
|
||||
},
|
||||
watch: {
|
||||
addModifyData(val) {
|
||||
if (val == 1) {
|
||||
this.title = "新增案件";
|
||||
this.getUserInfoFn();
|
||||
this.modelFlag = false;
|
||||
this.buttonFlag = true;
|
||||
this.formData = {
|
||||
@@ -524,48 +526,12 @@ export default {
|
||||
if (this.addModifyData != 1) {
|
||||
this.caseApplicationSelectByIdFn(this.caseData.id);
|
||||
}
|
||||
if (this.formData.affiliate.organizeFlag == 0) {
|
||||
this.formData.affiliate.applicationName = this.getUserInfoList.nickName;
|
||||
this.formData.affiliate.code = this.getUserInfoList.idCard;
|
||||
this.formData.affiliate.applicationEmail = this.getUserInfoList.email;
|
||||
this.formData.affiliate.applicationPhone = this.getUserInfoList.phonenumber;
|
||||
} else if (this.formData.affiliate.organizeFlag == 1) {
|
||||
this.formData.affiliate.nameAgent = this.getUserInfoList.nickName;
|
||||
this.formData.affiliate.agentEmail = this.getUserInfoList.email;
|
||||
this.formData.affiliate.contactTelphoneAgent = this.getUserInfoList.phonenumber;
|
||||
}
|
||||
}
|
||||
},
|
||||
formData: {
|
||||
handler(newVal) {
|
||||
if (newVal) {
|
||||
console.log('newVal========newVal==========newVal', newVal);
|
||||
if (newVal.affiliate.organizeFlag == 0) {
|
||||
this.formData.affiliate.applicationName = this.getUserInfoList.nickName;
|
||||
this.formData.affiliate.code = this.getUserInfoList.idCard;
|
||||
this.formData.affiliate.applicationEmail = this.getUserInfoList.email;
|
||||
this.formData.affiliate.applicationPhone = this.getUserInfoList.phonenumber;
|
||||
// this.formData.affiliate.nameAgent = '';
|
||||
// this.formData.affiliate.agentEmail = '';
|
||||
// this.formData.affiliate.contactTelphoneAgent = '';
|
||||
} else if (newVal.affiliate.organizeFlag == 1) {
|
||||
// this.formData.affiliate.applicationName = "";
|
||||
// this.formData.affiliate.code = "";
|
||||
// this.formData.affiliate.applicationEmail = "";
|
||||
// this.formData.affiliate.applicationPhone = "";
|
||||
this.formData.affiliate.nameAgent = this.getUserInfoList.nickName;
|
||||
this.formData.affiliate.agentEmail = this.getUserInfoList.email;
|
||||
this.formData.affiliate.contactTelphoneAgent = this.getUserInfoList.phonenumber;
|
||||
}
|
||||
}
|
||||
},
|
||||
deep: true, // 深度监听
|
||||
immediate: true, // 初始化监听
|
||||
}
|
||||
},
|
||||
created() {
|
||||
console.log(this.formData, "000000000000000000")
|
||||
this.getUserInfoFn();
|
||||
// this.getUserInfoFn();
|
||||
},
|
||||
methods: {
|
||||
/** 切换申请类型 */
|
||||
@@ -576,8 +542,11 @@ export default {
|
||||
/**获取申请人信息 */
|
||||
getUserInfoFn() {
|
||||
getUserInfo().then(res => {
|
||||
console.log(res, "信息信息信息信息信息信息信息信息信息信息信息信息信息信息");
|
||||
this.getUserInfoList = res.data;
|
||||
this.$set(this.formData.affiliate, "applicationName", this.getUserInfoList.nickName);
|
||||
this.$set(this.formData.affiliate, "code", this.getUserInfoList.idCard);
|
||||
this.$set(this.formData.affiliate, "applicationEmail", this.getUserInfoList.email);
|
||||
this.$set(this.formData.affiliate, "applicationPhone", this.getUserInfoList.phonenumber);
|
||||
})
|
||||
},
|
||||
/** 根据案件id获取对应信息 */
|
||||
@@ -671,6 +640,23 @@ export default {
|
||||
});
|
||||
},
|
||||
clearValidate(val) {
|
||||
if (val == 0) {
|
||||
this.$set(this.formData.affiliate, "applicationName", this.getUserInfoList.nickName);
|
||||
this.$set(this.formData.affiliate, "code", this.getUserInfoList.idCard);
|
||||
this.$set(this.formData.affiliate, "applicationEmail", this.getUserInfoList.email);
|
||||
this.$set(this.formData.affiliate, "applicationPhone", this.getUserInfoList.phonenumber);
|
||||
this.formData.affiliate.nameAgent = null;
|
||||
this.formData.affiliate.agentEmail = null;
|
||||
this.formData.affiliate.contactTelphoneAgent = null;
|
||||
} else if (val == 1) {
|
||||
this.$set(this.formData.affiliate, "nameAgent", this.getUserInfoList.nickName);
|
||||
this.$set(this.formData.affiliate, "agentEmail", this.getUserInfoList.email);
|
||||
this.$set(this.formData.affiliate, "contactTelphoneAgent", this.getUserInfoList.phonenumber);
|
||||
this.formData.affiliate.applicationName = null;
|
||||
this.formData.affiliate.code = null;
|
||||
this.formData.affiliate.applicationEmail = null;
|
||||
this.formData.affiliate.applicationPhone = null;
|
||||
}
|
||||
this.$refs["ruleForm"].clearValidate()
|
||||
},
|
||||
cancel() {
|
||||
|
||||
Reference in New Issue
Block a user