[update] 企业联系人验重
This commit is contained in:
@@ -529,14 +529,18 @@ export default {
|
||||
* @param callback
|
||||
*/
|
||||
validateContact(rule, value, callback) {
|
||||
const contactObj = this.form.getFieldsValue(['contactsIdOne', 'contactsIdTwo', 'contactsIdThree'])
|
||||
const contactArr = Object.values(contactObj)
|
||||
contactArr.filter(tt => tt !== undefined)
|
||||
console.log(contactArr)
|
||||
if (isRepeat(contactArr)) {
|
||||
callback('请选择不同的企业联系人')
|
||||
} else {
|
||||
if (value) {
|
||||
const contactObj = this.form.getFieldsValue(['contactsIdOne', 'contactsIdTwo', 'contactsIdThree'])
|
||||
const contactArr = Object.values(contactObj)
|
||||
contactArr.filter(tt => tt !== undefined)
|
||||
console.log(contactArr)
|
||||
if (isRepeat(contactArr)) {
|
||||
callback('请选择不同的企业联系人')
|
||||
} else {
|
||||
callback()
|
||||
}
|
||||
callback()
|
||||
return
|
||||
}
|
||||
callback()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user