[Bug #1273] Reimplement coerceToString as a workaround for the bug in Decimalbox.
FEA: ItEr75S04BugFixing
This commit is contained in:
parent
8a3c9d1594
commit
c27253af63
1 changed files with 6 additions and 3 deletions
|
|
@ -19,15 +19,14 @@
|
|||
package org.libreplan.web.common;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.text.DecimalFormatSymbols;
|
||||
|
||||
import org.zkoss.util.Locales;
|
||||
import org.zkoss.zk.ui.WrongValueException;
|
||||
import org.zkoss.zul.Decimalbox;
|
||||
|
||||
/**
|
||||
* Same behavior as a {@link Decimalbox}, but it always interprets <b>.</b> as
|
||||
* decimal separator, even when the locale uses a different separator.
|
||||
* We also reimplement coerceToString to workaround the bug
|
||||
* http://tracker.zkoss.org/browse/ZK-629.
|
||||
*
|
||||
* @author Óscar González Fernández <ogonzalez@igalia.com>
|
||||
* @author Jacobo Aragunde Pérez <jaragunde@igalia.com>
|
||||
|
|
@ -43,4 +42,8 @@ public class LenientDecimalBox extends Decimalbox {
|
|||
super(value);
|
||||
}
|
||||
|
||||
protected String coerceToString(Object value) {
|
||||
return formatNumber(value, null);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue