[
http://jira.jboss.com/jira/browse/JBSEAM-2148?page=all ]
Stephen Friedrich updated JBSEAM-2148:
--------------------------------------
Attachment: selectItems_group.patch
Here's a patch that adds these attributes to s:selectItems:
group - object to group by
groupVar - var name to store the object into
groupLabel
groupEscape
groupDisable
For now I only tested with a single example (checking the result with different values for
groupDisabled and groupEscaped):
<s:selectItems value="#{aircraftTypes}" var="aircraftType"
label="#{aircraftType.name}" group="#{aircraftType.manufacturer}"
groupVar="manufacturer" groupLabel="#{manufacturer.name}"/>
Unfortunately neither mojarra nor Trinidad honor "escape" and
"disabled" properties for SelectItemGroup:
https://javaserverfaces.dev.java.net/issues/show_bug.cgi?id=749
https://issues.apache.org/jira/browse/TRINIDAD-1140
I will have a look at Seam's unit tests and see how stuff that needs a FacesContext
can be tested.
Also if this code is generally fine (implementation fixes non.-withstnding) I am going to
update the docs.
Support for SelectItemGroup
---------------------------
Key: JBSEAM-2148
URL:
http://jira.jboss.com/jira/browse/JBSEAM-2148
Project: Seam
Issue Type: Feature Request
Components: JSF Controls
Affects Versions: 2.0.0.CR2
Reporter: Pete Muir
Fix For: 2.1.0.BETA2
Attachments: selectItems_group.patch
We can do something like
<s:selectItemGroup label="#{foo.bar}">
<s:selectItems .../>
<s:selectItems .../>
</s:selectItemGroup>
and, as a shorthand to put each list in a distinct group
<s:selectItems group="Foo"/>
I don't understand why this isn't in JSF core.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira