-
Notifications
You must be signed in to change notification settings - Fork 202
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversion failure with auto-parameters in other locales #49
Comments
A related issue is that apparently the number validation used does not take the locale into account. So, in HiveMind when I try to incorporate an hour formatted according to the curent locale (spanish) in hm/Task/EditTimeEntries, it gets rejected by the jquery validate plugin. |
I apologize for now response on this yet, it is indeed an issue. The first priority would be a working round trip to/from the database. The JavaScript checking is another issue, there may be a locale option for jquery-validation library that needs to be set. With other priorities I don't have time to look into this for the next couple weeks, but if you have any further input or a patch that solves either problem I'll review them. |
Closing as part of general cleanup for the move to HiveMind and for no recent activity on this issue. If this comes up again or anyone wants to pursue it feel free to create a request on moqui.org. For more information see: |
Co-authored-by: Michal Rovnanik on WS <michal@rovnanik.sk>
I am seeing following problem while using the spanish locale (relevant issue is that decimal separator is ',' and thousands separator is '.':
When invoking the service TaskServices.update#Task in mantle-usl, the auto-parameters for the in-parameters gets the decimal numbers wrong. These decimal numbers come directly from the Databse, so are not in the user's locale format. When checking the parameters (
checkConvertType
method oforg.moqui.impl.service.ServiceDefinition
), the line:BigDecimal bdVal = eci.l10n.parseNumber((String) parameterValue, format)
assumes that the parameter is in the locale's format. But when the value comes directly from the DB because it is filled in because of the auto-parameters tag, a value like 1.5 is converted to 15 (eliminating what is considered a thousands separator according to the locale).
The solution would be to either:
I'm not sure which way would be more suitable.
The text was updated successfully, but these errors were encountered: