[
https://issues.apache.org/jira/browse/TRINIDAD-2225?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13215181#comment-13215181
]
Yee-Wah Lee commented on TRINIDAD-2225:
---------------------------------------
In tr_TR locale, the percentage is displayed before the number, i.e. "% 40".
The numberConverter depends on the Locale JS file's getPercentSuffix(), which
is generated in the maven-i18n-plugins using
DecimalFormat df =
(DecimalFormat)NumberFormat.getPercentInstance(targetLocale);
Object[] percentData = new Object[2];
percentData[0] = df.getPositiveSuffix();
percentData[1] = df.getNegativeSuffix();
We would also need to add df.getPositivePrefix() to the Locale file, so the
numberConverter can detect if it is a prefix vs suffix and parse/format the
string accordingly.
However, the method getPositivePrefix() was fixed for tr_TR locale starting in
jdk 6u10 .
http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4494727
> Clieint numberConverter with type=percent fails in tr_TR locale
> ---------------------------------------------------------------
>
> Key: TRINIDAD-2225
> URL: https://issues.apache.org/jira/browse/TRINIDAD-2225
> Project: MyFaces Trinidad
> Issue Type: Bug
> Components: Components, Plugins
> Affects Versions: 2.0.0-core
> Reporter: Yee-Wah Lee
> Priority: Minor
>
> 1. Create an inputText with numberConverter, type = percent and turkish locale
> <tr:inputText label="Label 1" id="it1">
> <tr:convertNumber type="percent" locale="tr_TR"/>
> </tr:inputText>
> 2. Enter some numbers into the text and submit the page - it fails with
> TrParseException("percent suffix undefined or empty")
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira