Jul 13th, 2005, 12:53 PM
I am new to spring web flow. The framework looks great! I would like to ask if the framework is able to support multiple users with different rights. In my case we have let say 5 different user types that would require different web flow for each one.
For example the entire flow has 10 steps:
user 1 - exposed to all steps
user 2 - exposed to steps 1, 3, 7
user 3 - exposed to steps 3, 4, 10
- How would one handle the above case with spring web flow?
- Is it possible to associate different verification bean for user 2 and user 3 on step 3?
Thank you in advance.
Jul 14th, 2005, 04:18 AM
You can have "decision-states" within a flow which could say "if userCanAccessActionA then go ActionA else go ActionB" etc.
You would almost certainly want to model the individual actions as subflows anyway, and then have all your "main" webflow would be is a series of subflows and decision-states.
Jul 14th, 2005, 11:41 AM
Is it possible to have multiple webflow files for the different user types, versus having everything in one file? Having everything in one makes things hard to maintain.
Jul 15th, 2005, 07:16 AM
You have (not sure it is mandatory actually) one "flow" per file. A flow can reference another flow as a subflow.
I certainly wasn't suggesting a single large flow I was suggesting splitting each smaller step into it's own flow and then having a single flow to do the navigational decisions.
Jul 20th, 2005, 08:30 AM
I probably would also go for a subflow per user type, and have a parent flow spawn the correct subflow using a decision state. Splitting things up makes the flows simpler and probably easier to maintain, even though you will end up with a bit of duplication (e.g. the common states).