Commit 84db6afe authored by XieZhiXiong's avatar XieZhiXiong

fix: 修复外部定义了message给覆盖的问题

parent 59755016
......@@ -81,12 +81,12 @@ registerValidationRules({
return str.length > maxByte ? message : "";
},
required: (value, desc, rules) => {
const { required } = desc;
let message = ``
const { required, message } = desc;
let msg = '';
if (required) {
message += `${intl.formatMessage({id: 'common.bitian'})}`
msg = message || `${intl.formatMessage({id: 'common.bitian'})}`;
}
return (required && !isFieldLegal(value)) ? message : ''
return (required && !isFieldLegal(value)) ? msg : ''
}
});
......
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