Details
-
Bug
-
Resolution: Timed out
-
Low
-
None
-
3.13.2
-
3.13
-
1
-
Severity 3 - Minor
-
-
Description
Hello,
whatever value is inserted in a Custom Field type "Number Field" the data will be correctly stored in the database as intended:
centos02-jira=# SELECT * FROM customfieldvalue ; id | issue | customfield | parentkey | stringvalue | numbervalue | textvalue | datevalue | valuetype -------+-------+-------------+-----------+-------------+-------------+-----------+-----------+----------- 10022 | 10000 | 10000 | | | 0.12345 | | | 10031 | 10020 | 10000 | | | 0.123456 | | |
but will be truncated to the 3rd decimal place on the issue screen.
If the file atlassian-jira/WEB-INF/classes/templates/plugins/fields/view/view-number.vm is amended with a format string like so:
#if ($value) $!numberTool.format("0000000000000000.000000", $value) #end
the value will be displayed properly (note however that it will give an error if the encoding string contains '#' wich would be preferable as it would omit unnecessary '0's).
The value will then be rendered truncated once again in the "edit issue" screen and if saved will overwrite the database with the wrong value. The responsible macro should be: /atlassian-jira/WEB-INF/classes/templates/plugins/fields/edit/edit-number.vm.
Please let me know if you require further information
Regards,
Edoardo
Attachments
Issue Links
- relates to
-
JRASERVER-14076 DoubleConverter / NumberCFType is not as I18N as it could / should be - decimal separator does not respect user's locale
- Closed