2012-11-13 31 views
2

我正在使用流量範圍有一個primesfaces的StreamedContent字段和圖像不顯示的彈簧bean。任何想法如何使這與流量範圍的工作?當它是一個具有請求範圍的託管bean並且它是具有session/prototype/singleton範圍的spring bean時它工作正常。Webflow的流程範圍和使primefaces graphicImage工作

下面是一些示例代碼:

流量:

<input name="springBean" required="false"/> 

<view-state id="testFlow"> 
    <transition on="post" to="testFlow" /> 
</view-state> 

XHTML文件:

<ui:define name="body"> 
<h:form> 
    <p:graphicImage value="#{springBean.barcode}" cache="false"/> 
    <br /> 
    <h:outputText value="This is a test flow" /> 
    <br /> 
    Message From Spring = #{springBean.text}<br /> 
    <h:inputText value="#{springBean.text}" style="width:200px" /> 
    <h:commandButton action="post" value="Update" /> 
</h:form> 
</ui:define> 

應用上下文:

<import resource="flowConfig.xml" /> 

<bean name="springBean" class="swfproject.MessageHolder" scope="flow"> 
    <property name="text" value="This was defined in Spring" /> 
</bean> 

回答

相關問題