[ http://issues.apache.org/jira/browse/MYFACES-154?page=all ]
sean schofield updated MYFACES-154:
-----------------------------------
Component: JSF 1.1
Description:
lookupSet is filled using either getSubmittedValuesAsSet or
getSelectedValuesAsSet. Both of these routines use
RenderUtils.internalSubmittedOrSelectedValuesAsSet(), which uses
RenderUtils.getConvertedStringValue().
getConvertedStringValue() always returns strings. Hence, lookupSet.contains()
should always compare against itemStrValue (rather than itemValue.)
This impacts 2 files:
HtmlCheckboxRendererBase.java:
168,170c168,173
< boolean checked = (useSubmittedValues && lookupSet^M
< .contains(itemStrValue))^M
< || (!useSubmittedValues &&
lookupSet.contains(itemValue));^M
---
> // boolean checked = (useSubmittedValues && lookupSet^M
> // .contains(itemStrValue))^M
> // || (!useSubmittedValues &&
> lookupSet.contains(itemValue));^M
> // HAN - the myfaces code does not work with a converter. The
> lookupSet=getS*ValuesAsSet() ultimately calls
> RenderUtils.internalSubmittedOrSelectedValuesAsSet^M
> // That routine calls getConvertedStringValue(); which always
> returns strings. Hence lookupSet should always be compared to itemStrValue.^M
> boolean checked = lookupSet.contains(itemStrValue);^M
HtmlRendererUtils.java:
457,458c460,464
< if ((useSubmittedValue && lookupSet.contains(itemStrValue))^M
< || (!useSubmittedValue &&
lookupSet.contains(itemValue))) {^M
---
> // if ((useSubmittedValue &&
> lookupSet.contains(itemStrValue))^M
> // || (!useSubmittedValue &&
> lookupSet.contains(itemValue))) {^M
> // HAN - the myfaces code does not work with a converter.
> The lookupSet=getS*ValuesAsSet() ultimately calls
> RenderUtils.internalSubmittedOrSelectedValuesAsSet^M
> // That routine calls getConvertedStringValue(); which
> always returns strings. Hence lookupSet should always be compared to
> itemStrValue.^M
> if (lookupSet.contains(itemStrValue)) {^M
was:
lookupSet is filled using either getSubmittedValuesAsSet or
getSelectedValuesAsSet. Both of these routines use
RenderUtils.internalSubmittedOrSelectedValuesAsSet(), which uses
RenderUtils.getConvertedStringValue().
getConvertedStringValue() always returns strings. Hence, lookupSet.contains()
should always compare against itemStrValue (rather than itemValue.)
This impacts 2 files:
HtmlCheckboxRendererBase.java:
168,170c168,173
< boolean checked = (useSubmittedValues && lookupSet^M
< .contains(itemStrValue))^M
< || (!useSubmittedValues &&
lookupSet.contains(itemValue));^M
---
> // boolean checked = (useSubmittedValues && lookupSet^M
> // .contains(itemStrValue))^M
> // || (!useSubmittedValues &&
> lookupSet.contains(itemValue));^M
> // HAN - the myfaces code does not work with a converter. The
> lookupSet=getS*ValuesAsSet() ultimately calls
> RenderUtils.internalSubmittedOrSelectedValuesAsSet^M
> // That routine calls getConvertedStringValue(); which always
> returns strings. Hence lookupSet should always be compared to itemStrValue.^M
> boolean checked = lookupSet.contains(itemStrValue);^M
HtmlRendererUtils.java:
457,458c460,464
< if ((useSubmittedValue && lookupSet.contains(itemStrValue))^M
< || (!useSubmittedValue &&
lookupSet.contains(itemValue))) {^M
---
> // if ((useSubmittedValue &&
> lookupSet.contains(itemStrValue))^M
> // || (!useSubmittedValue &&
> lookupSet.contains(itemValue))) {^M
> // HAN - the myfaces code does not work with a converter.
> The lookupSet=getS*ValuesAsSet() ultimately calls
> RenderUtils.internalSubmittedOrSelectedValuesAsSet^M
> // That routine calls getConvertedStringValue(); which
> always returns strings. Hence lookupSet should always be compared to
> itemStrValue.^M
> if (lookupSet.contains(itemStrValue)) {^M
Environment:
> checkbox and listbox do not handler converters well
> ---------------------------------------------------
>
> Key: MYFACES-154
> URL: http://issues.apache.org/jira/browse/MYFACES-154
> Project: MyFaces
> Type: Bug
> Components: JSF 1.1
> Versions: 1.0.9 beta
> Reporter: Han Lee
> Assignee: sean schofield
>
> lookupSet is filled using either getSubmittedValuesAsSet or
> getSelectedValuesAsSet. Both of these routines use
> RenderUtils.internalSubmittedOrSelectedValuesAsSet(), which uses
> RenderUtils.getConvertedStringValue().
> getConvertedStringValue() always returns strings. Hence, lookupSet.contains()
> should always compare against itemStrValue (rather than itemValue.)
> This impacts 2 files:
> HtmlCheckboxRendererBase.java:
> 168,170c168,173
> < boolean checked = (useSubmittedValues && lookupSet^M
> < .contains(itemStrValue))^M
> < || (!useSubmittedValues &&
> lookupSet.contains(itemValue));^M
> ---
> > // boolean checked = (useSubmittedValues && lookupSet^M
> > // .contains(itemStrValue))^M
> > // || (!useSubmittedValues &&
> > lookupSet.contains(itemValue));^M
> > // HAN - the myfaces code does not work with a converter. The
> > lookupSet=getS*ValuesAsSet() ultimately calls
> > RenderUtils.internalSubmittedOrSelectedValuesAsSet^M
> > // That routine calls getConvertedStringValue(); which always
> > returns strings. Hence lookupSet should always be compared to
> > itemStrValue.^M
> > boolean checked = lookupSet.contains(itemStrValue);^M
> HtmlRendererUtils.java:
> 457,458c460,464
> < if ((useSubmittedValue &&
> lookupSet.contains(itemStrValue))^M
> < || (!useSubmittedValue &&
> lookupSet.contains(itemValue))) {^M
> ---
> > // if ((useSubmittedValue &&
> > lookupSet.contains(itemStrValue))^M
> > // || (!useSubmittedValue &&
> > lookupSet.contains(itemValue))) {^M
> > // HAN - the myfaces code does not work with a converter.
> > The lookupSet=getS*ValuesAsSet() ultimately calls
> > RenderUtils.internalSubmittedOrSelectedValuesAsSet^M
> > // That routine calls getConvertedStringValue(); which
> > always returns strings. Hence lookupSet should always be compared to
> > itemStrValue.^M
> > if (lookupSet.contains(itemStrValue)) {^M
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira