Rene O created MYFACES-3901:
-------------------------------

             Summary: f:selectItems ignore itemDescription within 
h:selectOneListbox
                 Key: MYFACES-3901
                 URL: https://issues.apache.org/jira/browse/MYFACES-3901
             Project: MyFaces Core
          Issue Type: Bug
    Affects Versions: 2.2.3
         Environment: java 7, tomcat 7
            Reporter: Rene O
            Priority: Minor


I have a <h:selectOneListbox> with underlying List:
{code}
List<SelectItem> mylist = new ArrayList<SelectItem>();
mylist.add(new SelectItem("testvalue", "testlabel","testdescription"));
{code}
I want to show a tooltip over any option of a selectbox.
Therefore I tried two options:

1.
{code}
<h:selectOneListbox value="#{bean.myvalue}" ...>
        <f:selectItems value="#{bean.mylist}" var="item" 
itemValue="#{item.value}" itemLabel="#{item.label}" 
itemDescription="yyy#{item.label}"/>
</h:selectOneListbox>
{code}

2.
{code}
<h:selectOneListbox value="#{bean.myvalue}" ...>
        <f:selectItems value="#{bean.mylist}" var="item" 
itemValue="#{item.value}" itemLabel="#{item.label}" 
passtrough:title="yyy#{item.label}"/>
</h:selectOneListbox>
{code}

Option 1 ignores itemDescription. Only label and value are rendered.
Option 2 renders title attribute, but fills title only with "yyy" and ignores 
value of #{item.label}

I think, that this behaviour is a bug.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to