我是webflow的新手,我尝试使用下面的代码,这是错误的......
<view-state id="displayAllTasks" view="/WEB-INF/flows/jsp/displayAllTasks.jsp" model="workflowSet">
<on-render>
<set name="requestScope.state" value="requestParameters.state"/>
<evaluate expression="workflowController.getAllTasksByState(requestParameters.state)" result="viewScope.workflowSet"></evaluate>
</on-render>
答案 0 :(得分:1)
使用on-entry替换on-render标记,它将起作用。
<view-state id="displayAllTasks" view="/WEB-INF/flows/jsp/displayAllTasks.jsp" model="workflowSet">
<on-entry>
<set name="requestScope.state" value="requestParameters.state"/>
<evaluate expression="workflowController.getAllTasksByState(requestParameters.state)" result="viewScope.workflowSet"></evaluate>
</on-entry>