f:setPropertyActionListener无法设置属性

时间:2012-06-28 13:55:16

标签: jsf primefaces

我正在尝试通过

设置我的backingbeans属性的值
    <f:setPropertyActionListener value="#{customer}"
                            target="#{customersViewBean.selectedCustomer}" />       

但它没有设置value.it令人惊讶的是我已经在类中初始化了这个属性但是当我按下命令链接时,它被设置为null并且给出了空指针异常。你知道什么是错的?

    <p:dataList id="datalist5"
                value="#{customersViewBean.filteredPositionCustomer}"
                rendered="#{customersViewBean.positionaGoreListe}"
                var="customer">
                <p:column style="padding-bottom:1px!important;">
                    <p:commandLink id="commandLink"

                        action="#{customersViewBean.getCustomerDetail}">
                        <f:setPropertyActionListener value="#{customer}"
                            target="#{customersViewBean.selectedCustomer}" />
                        <f:setPropertyActionListener value="false"
                            target="#{customersViewBean.comingFromOpportunityDetailToAddressList}" />

                        <h3>#{customer.name}</h3>

                    </p:commandLink>

                </p:column>
            </p:dataList>

0 个答案:

没有答案