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

Refactor application flow #1538

Merged
merged 35 commits into from
Feb 18, 2025
Merged

Refactor application flow #1538

merged 35 commits into from
Feb 18, 2025

Conversation

joonatank
Copy link
Contributor

@joonatank joonatank commented Feb 7, 2025

🛠️ Changelog

  • Recreating: Refactor application flow tilavarauspalvelu-ui#1644
  • Refactor: application flow
  • Fix: form validations
  • Refactor: form validation to use schemas instead of mixing field rules inside components.
  • Refactor: split [...params] page.
  • Refactor: split all queries to be page specific.

🧪 Test plan

  • Manual testing: creating / updating an application. customer

🚧 Dependencies

  • None

🎫 Tickets

@joonatank joonatank force-pushed the refactor-application-flow branch from 85df3ce to ec90085 Compare February 7, 2025 15:29
Base automatically changed from the-convergence to main February 10, 2025 08:20
@joonatank joonatank force-pushed the refactor-application-flow branch 6 times, most recently from ab6dce5 to 8e4e95f Compare February 11, 2025 11:15
@joonatank joonatank changed the base branch from main to add-adult-checks February 11, 2025 11:16
@joonatank joonatank force-pushed the refactor-application-flow branch from 8e4e95f to 4be1195 Compare February 11, 2025 11:22
Base automatically changed from add-adult-checks to main February 14, 2025 08:15
@joonatank joonatank force-pushed the refactor-application-flow branch from 7ad745f to ccae0b5 Compare February 14, 2025 09:40
@joonatank joonatank marked this pull request as ready for review February 14, 2025 10:14
@joonatank joonatank force-pushed the refactor-application-flow branch from 6e8befb to 0711389 Compare February 14, 2025 12:50
apps/ui/components/application/form.ts Outdated Show resolved Hide resolved
apps/ui/components/application/form.ts Outdated Show resolved Hide resolved
apps/ui/components/application/form.ts Outdated Show resolved Hide resolved
apps/ui/components/application/form.ts Show resolved Hide resolved
apps/ui/pages/applications/[id]/page3.tsx Outdated Show resolved Hide resolved
apps/ui/pages/applications/[id]/sent.tsx Show resolved Hide resolved
apps/ui/pages/recurring/[id]/criteria/index.tsx Outdated Show resolved Hide resolved
apps/ui/pages/recurring/[id]/criteria/index.tsx Outdated Show resolved Hide resolved
apps/ui/pages/recurring/[id]/index.tsx Outdated Show resolved Hide resolved
Copy link
Contributor

@vincit-matu vincit-matu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fix commented stuff, otherwise LGTM

@joonatank joonatank force-pushed the refactor-application-flow branch from 0711389 to a65652d Compare February 18, 2025 05:56
joonatank and others added 24 commits February 18, 2025 10:06
The schema is cleaner if we register / unregister the necessary fields.
This allows us to use a single top level undefined for a field that
should not be validate instead of writing custom validation logic.
add: cleaner Error component for custom form errors
- Make some inputs read-only
- Don't allow updating user or application round
- Move working memo update to own endpoint
- Validate number of application sections
- use schemas to validate all pages before sending and display an error
  with a link to the page.
- use schemas to validate the exact step (funnel page) user has access
- fix: individual address broken to form conversion
@joonatank joonatank force-pushed the refactor-application-flow branch from a65652d to 97fcce7 Compare February 18, 2025 08:06
@joonatank joonatank enabled auto-merge (rebase) February 18, 2025 08:11
@joonatank joonatank merged commit 2773596 into main Feb 18, 2025
21 checks passed
@joonatank joonatank deleted the refactor-application-flow branch February 18, 2025 08:11
@joonatank
Copy link
Contributor Author

#1550 merged into this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants