2 added 70 characters in body
source | link

The way this is traditionally done is actually very simple:

  • The menu system has a link for accessing Page1, but does not offer a direct link to Page2 or Page3
  • Page1 has a link to Page2
  • Page2 has a link to Page3

Ta da. No need to boil the ocean.

Now if you need to enforce the ordering rigidly, you can do the following:

  1. Add code to Page2 to ensure Page1 has been submitted. If it hasn't, redirect to Page1.
  2. Add code to Page3 to ensure Page2 has been submitted. If it hasn't, redirect to Page2.

Again, not exactly rocket science.

I can't think of any reason why you'd want to make this "generic" and use a List of pages with flags, unless your workflow is very long, maybe more than 10 pages, or if the page flow is supposed to be configurable at run-time, or if the flow is constantly changing with every release. Most of the time, a multi-page workflow doesn't have any of those properties, and the additional complexity isn't worth it and is likely to confuse future developers.

The way this is traditionally done is actually very simple:

  • The menu system has a link for accessing Page1, but does not offer a direct link to Page2 or Page3
  • Page1 has a link to Page2
  • Page2 has a link to Page3

Ta da. No need to boil the ocean.

Now if you need to enforce the ordering rigidly, you can do the following:

  1. Add code to Page2 to ensure Page1 has been submitted
  2. Add code to Page3 to ensure Page2 has been submitted

Again, not exactly rocket science.

I can't think of any reason why you'd want to make this "generic" and use a List of pages with flags, unless your workflow is very long, maybe more than 10 pages, or if the page flow is supposed to be configurable at run-time, or if the flow is constantly changing with every release. Most of the time, a multi-page workflow doesn't have any of those properties, and the additional complexity isn't worth it and is likely to confuse future developers.

The way this is traditionally done is actually very simple:

  • The menu system has a link for accessing Page1, but does not offer a direct link to Page2 or Page3
  • Page1 has a link to Page2
  • Page2 has a link to Page3

Ta da. No need to boil the ocean.

Now if you need to enforce the ordering rigidly, you can do the following:

  1. Add code to Page2 to ensure Page1 has been submitted. If it hasn't, redirect to Page1.
  2. Add code to Page3 to ensure Page2 has been submitted. If it hasn't, redirect to Page2.

Again, not exactly rocket science.

I can't think of any reason why you'd want to make this "generic" and use a List of pages with flags, unless your workflow is very long, maybe more than 10 pages, or if the page flow is supposed to be configurable at run-time, or if the flow is constantly changing with every release. Most of the time, a multi-page workflow doesn't have any of those properties, and the additional complexity isn't worth it and is likely to confuse future developers.

1
source | link

The way this is traditionally done is actually very simple:

  • The menu system has a link for accessing Page1, but does not offer a direct link to Page2 or Page3
  • Page1 has a link to Page2
  • Page2 has a link to Page3

Ta da. No need to boil the ocean.

Now if you need to enforce the ordering rigidly, you can do the following:

  1. Add code to Page2 to ensure Page1 has been submitted
  2. Add code to Page3 to ensure Page2 has been submitted

Again, not exactly rocket science.

I can't think of any reason why you'd want to make this "generic" and use a List of pages with flags, unless your workflow is very long, maybe more than 10 pages, or if the page flow is supposed to be configurable at run-time, or if the flow is constantly changing with every release. Most of the time, a multi-page workflow doesn't have any of those properties, and the additional complexity isn't worth it and is likely to confuse future developers.