Closed jenshp closed 6 years ago
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. If I want to add an entry with 1,2 hours, I have to use 1.2 to get through the Javascript checking but then it would be recognized as 12 hours instead of 1.2 (due to the locale configuration).
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:
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.