Commit 897a29d8 by s_guodong

update

parent e7d28375
...@@ -63,12 +63,12 @@ public class ValidatorUtil { ...@@ -63,12 +63,12 @@ public class ValidatorUtil {
return "参数校验错误[" + annotation.message() + "]"; return "参数校验错误[" + annotation.message() + "]";
} }
String integerString = bigDecimal.substring(0, i); String integerString = bigDecimal.substring(0, i);
if (integerString.length() > annotation.value1()) { if (integerString.length() > annotation.zsvalue() && annotation.zsvalue() > 0) {
return "参数校验错误[" + annotation.message1() + "]"; return "参数校验错误[" + annotation.zsmessage() + "]";
} }
} else { } else {
if (bigDecimal.length() > annotation.value1()) { if (bigDecimal.length() > annotation.zsvalue()) {
return "参数校验错误[" + annotation.message1() + "]"; return "参数校验错误[" + annotation.zsmessage() + "]";
} }
} }
} }
......
...@@ -8,9 +8,9 @@ import java.lang.annotation.*; ...@@ -8,9 +8,9 @@ import java.lang.annotation.*;
public @interface DecimalLength { public @interface DecimalLength {
int value() default 0; int value() default 0;
int value1() default 0; int zsvalue() default 0;
String message1() default ""; String zsmessage() default "";
String message() default ""; String message() default "";
} }
......
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