Hi all, I've just started using WebFlow and I can't access my ActionForm.
I made an ActionForm and want to use one of the properties of it in another method (from a POJO Class). I'm trying using this code in my flow.xml file
But ${client.id} is not a set property (I get a ognl Exception). I've also tried with flowScope.client and flowScope.id. I tried calling the exposeFormObject after the setupForm but it's the same.Code:<view-state id="addClient" view="/addClient.jsp"> <entry-actions> <action bean="userForm" method="setupForm"/> </entry-actions> <transition on="submit" to="makeDeposit"> </transition> </view-state> <action-state id="makeDeposit"> <entry-actions> <action bean="userForm" method="bind"/> </entry-actions> <action bean="service" method="deposit(${client.id}, ${client.amount})" /> <transition on="sucess" to="depositMade"></transition> <transition on="error" to="authorizationNeeded"></transition> </action-state>
The ActionForm has Client.class as FormObjectClass and "client" as FormObjectName.
This is the UserForm class
and the Client classCode:import org.springframework.webflow.action.FormAction; public class UserForm extends FormAction { public UserForm(){ super.setFormObjectName("client"); super.setFormObjectClass(Client.class); } }
Can anyone help me get access to my ActionForm from the flow?Code:public class Client { String id; String amount; public String getAmount(){ return amount; } public void setAmount(String amount){ this.amount = amount; } public String getId() { return id; } public void setId(String id){ this.id = id; } }


Reply With Quote