Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Rewrite page navigation using hooks #1508

Closed
Tracked by #1094
olemartinorg opened this issue Sep 25, 2023 · 1 comment · Fixed by #1682
Closed
Tracked by #1094

Rewrite page navigation using hooks #1508

olemartinorg opened this issue Sep 25, 2023 · 1 comment · Fixed by #1682
Assignees
Labels
fe-v4 Issues to be solved before v4 goes gold quality/debt

Comments

@olemartinorg
Copy link
Contributor

olemartinorg commented Sep 25, 2023

We have these sagas currently:

  1. updateCurrentViewSaga
  2. calculatePageOrderAndMoveToNextPageSaga
  3. findAndMoveToNextVisibleLayout
  4. watchInitialCalculatePageOrderAndMoveToNextPageSaga

Number 2 and 4 should disappear with #1491, which leaves us with updateCurrentViewSaga, and the code in findAndMoveToNextVisibleLayout which fixes a problem caused by the fact that updateCurrentViewSaga moves to a specific page instead of mostly moving forwards/backwards through the page order.

The new code should prefer using separate methods for next/prev instead of jumping straight to a specific page, to avoid problems like those solved in findAndMoveToNextVisibleLayout whenever possible.

Proposed solution:

  • We lift the process task id to the url, and allow the users to navigate to an arbitrary step in the process model.
  • Browser-back between process steps should show read-only/generic error message.
  • We lift the current page of a process step to the url, and allow the users to navigate to arbitrary pages in the current process step.
  • In the case where a user navigates to a task which is not the current task in the process engine, we show a generic page, which explains that this page is not editable. This page will also include a button to navigate to the first page of the current task.

Out of scope:

  • Creating a read-only view of the current page if the user navigates to a process step which is not the current step in the process.
  • Creating process-next buttons that can never be rendered in the read-only view. Moving the process along to the next step should be impossible from a step that is not the current step in the process.
  • We should implement a button that can navigate to previous process step (with the help of process.next if defined in the process model).

Related issue(s):

@olemartinorg olemartinorg added the fe-v4 Issues to be solved before v4 goes gold label Sep 25, 2023
@RonnyB71
Copy link
Member

RonnyB71 commented Nov 3, 2023

Based on the assumption that pageOrder will be removed and replaced with expressions.

@mikaelrss mikaelrss self-assigned this Nov 14, 2023
@mikaelrss mikaelrss moved this to 👷 In Progress in Team Apps Nov 14, 2023
@mikaelrss mikaelrss moved this to 🏗 In progress in Digital gravferdsmelding Nov 14, 2023
@RonnyB71 RonnyB71 mentioned this issue Nov 22, 2023
Closed
@tjololo tjololo moved this from 👷 In Progress to 🔎 Review in Team Apps Dec 6, 2023
@mikaelrss mikaelrss moved this from 🏗 In progress to 👀 In review in Digital gravferdsmelding Dec 6, 2023
@github-project-automation github-project-automation bot moved this from 👀 In review to ✅ Done in Digital gravferdsmelding Dec 7, 2023
@mikaelrss mikaelrss moved this from 🔎 Review to 🧪 Test in Team Apps Dec 7, 2023
@RonnyB71 RonnyB71 moved this from 🧪 Test to ✅ Done in Team Apps Dec 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
fe-v4 Issues to be solved before v4 goes gold quality/debt
Projects
Status: ✅ Done
Archived in project
Development

Successfully merging a pull request may close this issue.

3 participants