[jbossseam-issues] [JBoss JIRA] Commented: (JBSEAM-2148) Support for SelectItemGroup

Stephen Friedrich (JIRA) jira-events at lists.jboss.org
Sun Jun 29 18:23:31 EDT 2008


    [ http://jira.jboss.com/jira/browse/JBSEAM-2148?page=comments#action_12419303 ] 
            
Stephen Friedrich commented on JBSEAM-2148:
-------------------------------------------

Hm, I think we need both variants.
The <s:selectItemGroup> is useful if there is a static/fixed number of groups.
The other flavor is nice if the grouping is already present in the domain model.

I created a patch for the latter case - it is basically working, but I still have to do a little cleanup and probably also support escape and disabled for the group.

Also I am a little unsure about the new attribute names.
selectItems has four attributes that apply to the tag itself (rather than the individual items): value, var, noSelectionLabel, hideNoSelectionLabel
These attributes apply to the items: itemValue, label, disabled, escape

The group does not need an itemValue (I think) because it can never be selected itself anyway, right?
Also the "groupByVar" from the previous example is not really needed, all values must be reachable through "var" anyway.

So there need to be four new attributes - one to specify the object which is used to group by, plus three for group's label, disabled and escape flags:

group
groupLabel
groupDisabled
groupEscape
???





> 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
>
>
> 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

        



More information about the seam-issues mailing list