Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Converter does not work for CheckboxRenderer #460

Closed
ren-zhijun-oracle opened this issue Nov 28, 2006 · 10 comments
Closed

Converter does not work for CheckboxRenderer #460

ren-zhijun-oracle opened this issue Nov 28, 2006 · 10 comments
Assignees

Comments

@ren-zhijun-oracle
Copy link
Contributor

I tried to set an converter for selectBooleanCheckbox,
but it seems that this does not work or is not supported full.

The converter is called during RenderResponse, but not in ProcessValidation.
Searching the source code i detected: CheckboxRenderer.getConvertedValue

Think this method must check for existing Converter like the method of its
super class.

Environment

Operating System: All
Platform: All

Affected Versions

[1.2]

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
Reported by hammoud

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
Was assigned to javaserverfowner

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
@rlubke said:
I believe this may be a bug in the spec.

The decode for the boolean checkbox states that if the value
is detected as checked, then the submitted value must be true,
otherwise false - no need for custom conversion.

Can you provide a use case?

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
hammoud said:
Main objects of my model contain a HashMap with just String values.
So its possible to extend them individual for different applications.
All get stored automatically without any change of database or logic.

Only in the view every attribute must be rendered depending to its meaning.
Some converted from StringToInput, some StringToCheckbox, ...
This allows me to easily use an basic logic for several customers customized by
only changing the views.

Think its an special case and makes it not neccessary to include converter to
the CheckboxRender.
I could also build my own component for this which converts/renders
StringToCheckbox.
But then the converter attribute should be removed from TagHandler/TLD which
uses the CheckboxRenderer.

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
rogerk said:
I think the Renderer behavior is correct, and CheckboxRenderer des the right
thing according to the described behavior. So we have a situation where we have
a converter tld attribute that doesn't get used (or does not apply).
I believe we need to figure a way to remove the converter attribute for the
checkbox tag.

I've opened a spec issue for this:
https://javaserverfaces-spec-public.dev.java.net/issues/show_bug.cgi?id=238

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
@rlubke said:
The spec will address the deprecation of the converter attribute on the checkbox
component. Marking this as WONTFIX.

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
Marked as won't fix on Monday, January 29th 2007, 6:33:49 am

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
@manfredriem said:
Closing issue out

@ren-zhijun-oracle
Copy link
Contributor Author

@javaserverfaces Commented
This issue was imported from java.net JIRA JAVASERVERFACES-456

@ren-zhijun-oracle
Copy link
Contributor Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants