details: https://code.openbravo.com/erp/devel/pi/rev/ba68aea40ed2
changeset: 23886:ba68aea40ed2
user: Augusto Mauch <augusto.mauch <at> openbravo.com>
date: Thu Jun 26 11:30:10 2014 +0200
summary: Fixes issue 26946: Default values are properly set with ',' decimal
sepsasrator
In the parameter windows, in case the default numeric value can't be parsed
with the decimal and grouping separators defined in Format.xml, the default
handler tries to parse it with the standard '.' and ','.
diffstat:
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js
| 3 +++
1 files changed, 3 insertions(+), 0 deletions(-)
diffs (13 lines):
diff -r 28ec99604b05 -r ba68aea40ed2
modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js
---
a/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js
Thu Jun 26 10:29:37 2014 +0200
+++
b/modules/org.openbravo.client.application/web/org.openbravo.client.application/js/process/ob-parameter-window-view.js
Thu Jun 26 11:30:10 2014 +0200
@@ -544,6 +544,9 @@
isNumber = isc.SimpleType.inheritsFrom(type, 'integer') ||
isc.SimpleType.inheritsFrom(type, 'float');
if (isNumber && OB.Utilities.Number.IsValidValueString(type, stringValue))
{
return OB.Utilities.Number.OBMaskedToJS(stringValue, type.decSeparator,
type.groupSeparator);
+ } else if (isNumber &&
isc.isA.Number(OB.Utilities.Number.OBMaskedToJS(stringValue, '.', ','))) {
+ // it might happen that default value uses the default '.' and ',' as
decimal and group separator
+ return OB.Utilities.Number.OBMaskedToJS(stringValue, '.', ',');
} else {
return stringValue;
}
------------------------------------------------------------------------------
Open source business process management suite built on Java and Eclipse
Turn processes into business applications with Bonita BPM Community Edition
Quickly connect people, data, and systems into organized workflows
Winner of BOSSIE, CODIE, OW2 and Gartner awards
http://p.sf.net/sfu/Bonitasoft
_______________________________________________
Openbravo-commits mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openbravo-commits