[ 
https://issues.apache.org/jira/browse/WICKET-330?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Johan Compagner closed WICKET-330.
----------------------------------

    Resolution: Fixed

fixed the CheckBox wil always use the default boolean converter (or somebody 
has to override that again)

> CheckBox incorrectly converts its model value when a custom Boolean converter 
> is installed
> ------------------------------------------------------------------------------------------
>
>                 Key: WICKET-330
>                 URL: https://issues.apache.org/jira/browse/WICKET-330
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.3.0-beta3, 2.0 branch (discontinued)
>            Reporter: Martin Benda
>            Assignee: Johan Compagner
>             Fix For: 1.3.0-beta5
>
>         Attachments: checkbox-getModelValue.patch, CheckBox.patch
>
>
> When I use a custom localized Boolean converter (using my custom 
> IConverterLocator) that converts "Ano" to true and "Ne" to false (Czech words 
> for "yes" and "no") the CheckBox with 'true' getModelObject() will render 
> unchecked. The problem is that CheckBox uses Strings.isTrue() to convert a 
> value returned by getModelObjectAsString() which uses converters. The result 
> is that true is incorrectly converted to false...
> true -> convertToString() -> "Ano" -> Strings.isTrue() -> false

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to