Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 2.0.0
-
Fix Version/s: 2.0.1
-
Component/s: ICE-Components
-
Labels:None
-
Environment:Tomcat 6.0.25, Liferay EE 6.0SP1, PortletFaces Bridge 2.0-beta4, LiferayFaces 6.0, AlloyFaces 1.0.1-BETA1
-
Workaround Exists:Yes
-
Workaround Description:Use <h:selectOneListbox> with icecore:singleSubmt tag.
Description
When using <ice:selectOneListbox> with Liferay, items are displayed as the toString value instead of the specified itemValue property of the nested <f:selectItem> components.
This happens even even in very simple cases like this:
<ui:composition xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:aui="http://portletfaces.org/alloyfaces/aui"
xmlns:aui-cc="http://portletfaces.org/alloyfaces/aui-cc"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:ice="http://www.icesoft.com/icefaces/component"
xmlns:icecore="http://www.icefaces.org/icefaces/core"
xmlns:t="http://myfaces.apache.org/tomahawk"
template="templates/main.xhtml">
<ui:define name="body">
<ice:form id="selectMediaForm" styleClass="aui-form dlp">
<ice:selectOneListbox size="1" label="#{i18n['scope']}" partialSubmit="true"
required="true"
value="#{mutablePortletPreferencesValues['scopeGroupId'].value}">
<f:selectItem itemLabel="#{i18n['select']}" itemValue="" />
<f:selectItems itemValue="#{group.groupId}"
itemLabel="#{group.name}" value="#{preferencesBackingBean.groups}"
var="group" />
</ice:selectOneListbox>
</ice:form>
</ui:composition>
This happens even even in very simple cases like this:
<ui:composition xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:aui="http://portletfaces.org/alloyfaces/aui"
xmlns:aui-cc="http://portletfaces.org/alloyfaces/aui-cc"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:ice="http://www.icesoft.com/icefaces/component"
xmlns:icecore="http://www.icefaces.org/icefaces/core"
xmlns:t="http://myfaces.apache.org/tomahawk"
template="templates/main.xhtml">
<ui:define name="body">
<ice:form id="selectMediaForm" styleClass="aui-form dlp">
<ice:selectOneListbox size="1" label="#{i18n['scope']}" partialSubmit="true"
required="true"
value="#{mutablePortletPreferencesValues['scopeGroupId'].value}">
<f:selectItem itemLabel="#{i18n['select']}" itemValue="" />
<f:selectItems itemValue="#{group.groupId}"
itemLabel="#{group.name}" value="#{preferencesBackingBean.groups}"
var="group" />
</ice:selectOneListbox>
</ice:form>
</ui:composition>
Activity
Kito Mann
created issue -
Kito Mann
made changes -
Field | Original Value | New Value |
---|---|---|
Attachment | selectOneListbox bug.png [ 12993 ] |
Ken Fyten
made changes -
Workaround Description | Use <h:selectOneListbox>. | Use <h:selectOneListbox> with icecore:singleSubmt tag. |
Salesforce Case | [] | |
Fix Version/s | 2.1 [ 10241 ] |
Ken Fyten
made changes -
Salesforce Case | [] | |
Fix Version/s | EE-3.0.0.GA [ 10262 ] | |
Fix Version/s | 3.0 [ 10241 ] | |
Assignee Priority | P2 | |
Assignee | Adnan Durrani [ adnan.durrani ] |
Ken Fyten
made changes -
Fix Version/s | 3.1 [ 10312 ] | |
Fix Version/s | EE-3.0.0.GA [ 10262 ] |
Ken Fyten
made changes -
Salesforce Case | [] | |
Assignee Priority | P2 | P3 |
Assignee | Adnan Durrani [ adnan.durrani ] | yip.ng [ yip.ng ] |
Ken Fyten
made changes -
Fix Version/s | 3.2 [ 10338 ] | |
Fix Version/s | 3.1 [ 10312 ] |
yip.ng
made changes -
Attachment | screenshot-01.png [ 14661 ] |
Ken Fyten
made changes -
Status | Open [ 1 ] | Resolved [ 5 ] |
Fix Version/s | 2.0.1 [ 10255 ] | |
Fix Version/s | 3.2 [ 10338 ] | |
Assignee Priority | P3 | |
Resolution | Fixed [ 1 ] |
Ken Fyten
made changes -
Status | Resolved [ 5 ] | Closed [ 6 ] |
For a workaround, if you can use <h:selectOneListBox> with <f:ajax>:
<h:selectOneListbox size="1" label="#
{i18n['scope']}" required="true"
{mutablePortletPreferencesValues['scopeGroupId'].value}value="#
">
{i18n['select']}<f:selectItem itemLabel="#
" itemValue="" />
{group.groupId}<f:selectItems itemValue="#
"
{group.name}itemLabel="#
" value="#
{preferencesBackingBean.groups}"
{preferencesBackingBean.savePreferences}var="group" />
<f:ajax execute="@this" render="docLibraryPanel" listener="#
"/>
</h:selectOneListbox>