Commit 4f11e8da by 王昆

gsb

parent bd53b307
......@@ -36,7 +36,7 @@ class Validation {
}
let v = data[field];
if (rule.is_require && !v) {
this.error(data, "对象不存在");
this.error(data, `${rule.name}:为空`);
}
if (rule.maxLen && v.length > rule.maxLen) {
this.error(data, `${rule.name}:长度不允许超过${rule.maxLen}`);
......
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