Results 1 to 6 of 6

Thread: Send a flow to a page outside of its scope

  1. #1
    Join Date
    Jul 2005
    Posts
    14

    Default Send a flow to a page outside of its scope

    Hi all

    I am creating a flow, reasonably complex. In one given situation, if the user cancels the action, I want to sent him to a page outside the flow, ie, a page that is not included in the xml structure. How can I send him there without including that page in the flow?

  2. #2
    Join Date
    Aug 2004
    Posts
    1,905

    Default

    Why can't you just have an end-state which defines that view?

  3. #3
    Join Date
    Feb 2005
    Posts
    25

    Default

    OK, but I think there's a good question here.

    How does one end a flow (so that it cleans up) and
    leave for another page?

    What I need to do is to terminate the flow and
    jump out to a more traditional Spring Controller.
    I would like to terminate the flow gracefully so
    that any resources it uses are cleaned up.

    Is this possible and how do I do it? Thanks,
    -tom
    Balanced precariously on the learning curve

  4. #4
    Join Date
    Sep 2004
    Location
    Leuven, Belgium
    Posts
    1,853

    Default

    To correctly terminate a flow and jump to another page (e.g. a classic Spring MVC controller), just use an end state:

    Code:
    <end-state id="endCancel" view="..."/>
    Note that the view attribute can take quite a few different forms, so you can make all of this pretty flexible. E.g.:
    view="viewName" -> classic case
    view="redirect:/url" -> redirect to some url
    Also remember that the view attribute supports expressions, so you can have stuff like:
    view="redirect:${flowScope.callerUrl}"
    view="redirect:/details.do?id=${flowScope.formObject.id}"

    Erwin

  5. #5
    Join Date
    Feb 2005
    Posts
    25

    Default

    Thanks Erwin!

    That's exactly what I was looking for.
    -tom
    Balanced precariously on the learning curve

  6. #6
    Join Date
    Jun 2011
    Posts
    4

    Default

    my question is how to ask a question in this community?

Similar Threads

  1. FlowExecutionStorage in a DB
    By cacho in forum Web Flow
    Replies: 7
    Last Post: Oct 19th, 2009, 03:36 PM
  2. Pageable data list with Hibernate
    By robmorgan in forum Data
    Replies: 23
    Last Post: Jul 24th, 2006, 06:12 PM
  3. Replies: 2
    Last Post: Oct 10th, 2005, 02:10 AM
  4. Is a 'singleton' flow a bad idea?
    By akw in forum Web Flow
    Replies: 4
    Last Post: Oct 6th, 2005, 01:16 AM
  5. Spring Web Flow - Preview 1 Released
    By Colin Sampaleanu in forum Announcements
    Replies: 13
    Last Post: Apr 6th, 2005, 07:22 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •