[
https://issues.jboss.org/browse/RF-13060?page=com.atlassian.jira.plugin.s...
]
Brian Leathem updated RF-13060:
-------------------------------
Fix Version/s: 4.3.3
5-Tracking
Assignee: Brian Leathem
Workaround Description: Make sure your domain objects implement both the _euqals_ and
the _hashCode_ methods.
The fix is to override hashCode for your Item Object. This however is less than ideal.
While the HashSet used may lead to an efficient implementation, in practice pickList value
collections are small enough that iterating over the elements is sufficient.
We should change our implementation to not require the implementation of the hashCode
method in the Data objects. To implement this, we can simply iterate over the collection,
invoking the equals method on the individual objects. This will make it easier for folks
to use the pickList.
Issue in initializing the list of selected items in a Picklist
--------------------------------------------------------------
Key: RF-13060
URL:
https://issues.jboss.org/browse/RF-13060
Project: RichFaces
Issue Type: Bug
Security Level: Public(Everyone can see)
Components: component-selects
Affects Versions: 4.3.2
Reporter: Jean-Noel Colin
Assignee: Brian Leathem
Fix For: 4.3.3, 5-Tracking
A picklist uses two list of items: a list of available items and a list of selected
items. If this second list has to be initialized, it has to contain the same object
instances as those in the available items. So both lists can't be built from two
separate DB queries, since they would refer to distinct objects, and in this case, the
list of selected items would always be empty. Upon request of Brian Leathem, I have
created this JIRA issue after providing a sample application that illustrates the problem.
/Items.xhtml is the frontend
Item is the element to be displayed in the list
ItemBean is the managed bean that builds the available and selected lists
ItemConverter is the converter
As you see in ItemBean's constructor, depending on the way I build the selectedList,
it gets displayed properly or not
the project is using ivy for dependencies, and is build using ant tasks
ant resolve-dependencies
ant package
should build the war file in /dist
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see:
http://www.atlassian.com/software/jira