Commit f9f379f0 authored by zhangyanni's avatar zhangyanni

第三阶段改为不必填

parent 28615c88
......@@ -32,12 +32,12 @@
<el-input v-model="ruleForm.requirementContactUser" style="width: 250px;" :placeholder="$t('saleManage.contactForm.placeholderName')" maxlength="36"></el-input>
</el-form-item>
<el-form-item :label="$t('recordManage.corporate')+' '+$t('saleRecordTitle.contactWay')+':'" prop="requirementContactWay">
<el-form-item :label="$t('recordManage.corporate')+(lang==2?' ':'')+$t('saleRecordTitle.contactWay')+':'" prop="requirementContactWay">
<el-input v-model="ruleForm.requirementContactWay" style="width: 250px;" :placeholder="$t('saleRecordTitle.contactWayTitle')" autocomplete maxlength="36"></el-input>
</el-form-item>
<el-form-item :label="$t('recordManage.corporate')+' '+$t('saleRecordTitle.position')+':'" prop="requirementPosition">
<el-form-item :label="$t('recordManage.corporate')+(lang==2?' ':'')+$t('saleRecordTitle.position')+':'" prop="requirementPosition">
<el-input v-model="ruleForm.requirementPosition" style="width: 250px;" :placeholder="$t('saleManage.contactForm.placeholderPosition')" maxlength="36"></el-input>
</el-form-item>
......@@ -47,12 +47,12 @@
</el-form-item>
<el-form-item :label="$t('recordManage.startup')+' '+$t('saleRecordTitle.contactWay')+':'" prop="projectContactWay">
<el-form-item :label="$t('recordManage.startup')+(lang==2?' ':'')+$t('saleRecordTitle.contactWay')+':'" prop="projectContactWay">
<el-input v-model="ruleForm.projectContactWay" style="width: 250px;" :placeholder="$t('saleRecordTitle.contactWayTitle')" autocomplete maxlength="36"></el-input>
</el-form-item>
<el-form-item :label="$t('recordManage.startup')+' '+$t('saleRecordTitle.position')+':'" prop="projectPosition">
<el-form-item :label="$t('recordManage.startup')+(lang==2?' ':'')+$t('saleRecordTitle.position')+':'" prop="projectPosition">
<el-input v-model="ruleForm.projectPosition" style="width: 250px;" :placeholder="$t('saleManage.contactForm.placeholderPosition')" maxlength="36"></el-input>
</el-form-item>
......@@ -153,16 +153,16 @@
recordResult:[{required: true, message:this.$t("saleRecordTitle.selectRecordTitle"), trigger: 'change'}],
contactTime:[{required: true, message:this.$t("saleRecordTitle.selectTime"), trigger: 'change'}],
requirementContactUser:[
{required: true, validator:validate.checkRequireName, trigger: 'blur'},
{required: false, validator:this.checkRequireName, trigger: 'blur'},
],
requirementContactWay:[{required: true, message:this.$t("saleRecordTitle.contactWayTitle"), trigger: 'blur'}],
requirementContactWay:[{required: false, message:this.$t("saleRecordTitle.contactWayTitle"), trigger: 'blur'}],
requirementPosition:[
{required: false, validator:validate.checkNotRequirePosition, trigger: 'blur'},
],
projectContactUser:[
{required: true, validator:validate.checkRequireName, trigger: 'blur'},
{required: false, validator:this.checkRequireName, trigger: 'blur'},
],
projectContactWay:[{required: true, message:this.$t("saleRecordTitle.contactWayTitle"), trigger: 'blur'}],
projectContactWay:[{required: false, message:this.$t("saleRecordTitle.contactWayTitle"), trigger: 'blur'}],
projectPosition:[
{required: false, validator:validate.checkNotRequirePosition, trigger: 'blur'},
],
......@@ -184,12 +184,25 @@
dictKey:1,
dictValue:this.$t("saleRecordTitle.no")
}],
disabledFlag:0
disabledFlag:0,
lang: this.publicFun.getCookie("language") == "zh-CN" ? 1 : 2,
}
},
methods:{
//验证需求联系人姓名
checkRequireName(rule,value,callback){
var reg = /^[a-zA-Z\u4e00-\u9fa5 ]{2,36}$/,reg1 = /^\s+$/g;
if(reg1.test(value)){
callback(new Error(this.$t("saleManage.placeholderName")));
}else if(value !=''&&!reg.test(value)){
callback(new Error(this.$t("saleManage.placeholderName")));
}else{
callback();
}
},
validateContent(rule,value,callback){
var reg1 = /^\s+$/g;
if(value===""||reg1.test(value)){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment