}
try{
- String pattern = "-?\\d*.?\\d{0,10}";
+ String pattern = "-?\\d{0,9}.?\\d{0,9})";
if (value.matches(pattern)){
BigDecimal number = new BigDecimal(value);
if((start != null && number.compareTo(start) < 0 || (end != null && number.compareTo(end) > 0))){
public BigDecimal getBigDecimal(){
String text = super.getText();
+ if (StringUtils.isBlank(text) || "-".equals(text)){
+ return null;
+ }
try {
- return StringUtils.isBlank(text) ? null : new BigDecimal(text);
+ return new BigDecimal(text);
} catch (NumberFormatException e) {
exception = e;
return null;