Jsf h:selectManyCheckbox在导航时会丢失值

Jsf h:selectManyCheckbox在导航时会丢失值,jsf,primefaces,Jsf,Primefaces,我的问题是h:selectManyCheckbo在导航时会丢失值,下面是我的代码: <h:selectManyCheckbox id="selectGroupsBox" value="{userCreationWizardBean.selectedGroupsId}" layout="pageDirection"> <f:selec

我的问题是h:selectManyCheckbo在导航时会丢失值,下面是我的代码:

<h:selectManyCheckbox id="selectGroupsBox" 
                      value="{userCreationWizardBean.selectedGroupsId}"
                      layout="pageDirection">

                            <f:selectItems var="Group"
                                value="#{userCreationWizardBean.terminalsGroups}"
                                itemLabel="#{terminalsGroup.groupName}"
                                itemValue="#{terminalsGroup.id}"
                                itemDisabled="#{Group.defaultGroup}">
                            </f:selectItems>
                            <p:ajax event="change" update=":form-top-wizard:numBase" process="selectGroupsBox"
                                listener="#{userCreationWizardBean.selectedGroupListner}"></p:ajax>
</h:selectManyCheckbox>

如果我使用导航板来回移动,复选框将丢失值:

<div id="top-wizard" class="#{class}">
        <ul>
            <li class="premier#{wizard_step=='0'?'_active':''}"><p:commandLink
                    action="#{userCreationWizardBean.getViewAt(0)}" ajax="true"
                    update=":msg-form:popup_faces-messages" 
                    /></li>

            <li class="deuxieme#{wizard_step=='1'?'_active':''}"><p:commandLink
                    action="#{userCreationWizardBean.getViewAt(1)}" ajax="true"
                    update=":msg-form:popup_faces-messages"  
                     /></li>

            <li class="troisieme#{wizard_step=='2'?'_active':''}"><p:commandLink
                    action="#{userCreationWizardBean.getViewAt(2)}" ajax="true"
                     update=":msg-form:popup_faces-messages"  
                     /></li>
            <li class="quatrieme#{wizard_step=='3'?'_active':''}"><p:commandLink
                    action="#{userCreationWizardBean.getViewAt(3)}" ajax="true"
                    update=":msg-form:popup_faces-messages" 
                    /></li>

        </ul>
</div>

当我删除itemDisabled属性时,问题基本上消失了


似乎我可以使用jquery css选择器Syntax将复选框从处理中排除,但仅在primefaces 3.3中,但我使用的是3.2。

我认为您遇到的问题与禁用的组件或项的值未发送到服务器这一事实有关。。我也一直在努力寻找解决办法。查看此内容可能会有所帮助。

itemDisabled=“Group.defaultGroup”)}“这是SO post中的错误还是您的代码中的错误?很抱歉,我只是键入错误。您在引用的ManagedBean中使用了什么作用域类型?