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

Rework form entry and form hierarchy to be one Activity #5420

Open
seadowg opened this issue Jan 24, 2023 · 1 comment
Open

Rework form entry and form hierarchy to be one Activity #5420

seadowg opened this issue Jan 24, 2023 · 1 comment

Comments

@seadowg
Copy link
Member

seadowg commented Jan 24, 2023

Blocked until v2023.3.x is merged in to master

Currently, there are two Activity objects that handle form entry (answering questions) and viewing/navigating the form hierarchy. This has two major disadvantages:

  • Sharing state between multiple Activity objects is far harder than sharing it within a single Activity
  • We're unable to embed the hierarchy within a "page" of form entry (like we've seen in some speculative mockups)

We should restructure our code so that FormEntryActivity handles the full form entry workflow. This most likely means creating a two Fragment or View objects that represent different "view" on the form entry session and can easily be switched in between (and potentially embed within each other).

As part of this, we should also remove the FormSessionRepository.

@seadowg seadowg added this to the v2023.2 milestone Jan 24, 2023
@seadowg seadowg changed the title Rework form entry and form hierarchy to be one Activity Rework form entry and form hierarchy to be one Activity Jan 24, 2023
@seadowg seadowg changed the title Rework form entry and form hierarchy to be one Activity Rework form entry and form hierarchy to be one Activity Jan 24, 2023
@github-project-automation github-project-automation bot moved this to icebox in ODK Collect Mar 20, 2023
@seadowg seadowg moved this from icebox to backlog in ODK Collect Mar 20, 2023
@seadowg seadowg modified the milestones: v2023.2, v2023.3 May 30, 2023
@seadowg seadowg removed the status in ODK Collect May 30, 2023
@seadowg seadowg moved this to not ready in ODK Collect May 30, 2023
@seadowg seadowg moved this from not ready to backlog in ODK Collect Jun 5, 2023
@seadowg seadowg moved this from backlog to not ready in ODK Collect Aug 15, 2023
@seadowg seadowg modified the milestones: v2023.3, v2023.4 Aug 28, 2023
@seadowg seadowg added the blocked label Oct 6, 2023
@seadowg seadowg removed the blocked label Nov 2, 2023
@seadowg seadowg moved this from not ready to backlog in ODK Collect Nov 2, 2023
@seadowg seadowg modified the milestones: v2024.1, v2024.2 Dec 5, 2023
@seadowg seadowg modified the milestones: v2024.2, v2024.3 Apr 8, 2024
@seadowg seadowg removed this from the v2024.3 milestone Jul 3, 2024
@seadowg
Copy link
Member Author

seadowg commented Nov 13, 2024

@grzesiek2010 I'm aiming to convert FormFillingActivity to single Activity/multi Fragment set up with a nav graph (similar to EntitiesBrowserActivity). There will be two fragments: one for form entry and one for the hierarchy. This will allow the form entry view models (mainly FormEntryViewModel itself) to be hosted at the activity level and shared between fragments. Later, we could use the same nav graph to open dialogs (like errors or even things like the select minimal UI), but for this issue I think we just lay the foundations with a simple two destination graph. I'm not sure exactly how the view only mode would work (different nav graph potentially).

After we're done with that, we can review if we can make improvements to how we store the form session. Just moving everything to one Activity here should make managing that state much simpler though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: in progress
Development

No branches or pull requests

2 participants