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

6349 fix double confirm #6753

Open
wants to merge 2 commits into
base: v2.6.0-RC
Choose a base branch
from
Open

Conversation

lache-melvin
Copy link
Contributor

@lache-melvin lache-melvin commented Feb 28, 2025

Fixes #6349

πŸ‘©πŸ»β€πŸ’» What does this PR do?

JSON forms has an isDirty check on navigation baked in. So we don't need the extra custom one :)

πŸ’Œ Any notes for the reviewer?

πŸ§ͺ Testing

  • Edit a patient (or create one)
  • Click cancel instead of save
  • You only get one confirmation modal before you are navigated away

πŸ“ƒ Documentation

  • Part of an epic: documentation will be completed for the feature as a whole
  • No documentation required: no user facing changes or a bug fix which isn't a change in behaviour
  • These areas should be updated or checked:
    1.
    2.

πŸ“ƒ Reviewer Checklist

The PR Reviewer(s) should fill out this section before approving the PR

Breaking Changes

  • No Breaking Changes in the Graphql API
  • Technically some Breaking Changes but not expected to impact any integrations

Issue Review

  • All requirements in original issue have been covered
  • A follow up issue(s) have been created to cover additional requirements

Tests Pass

  • Postgres
  • SQLite
  • Frontend

@github-actions github-actions bot added this to the v2.6.0-RC5 milestone Feb 28, 2025
@github-actions github-actions bot added Severity: Normal Bugs which have an acceptable workaround. Moderate/tolerable user impact. Next minor release. Team: Kororā 🐧 Chris, Laché, Aimee labels Feb 28, 2025
@@ -34,7 +34,7 @@
["TRANSGENDER_MALE", "Transgender Male"],
["TRANSGENDER_FEMALE", "Transgender Female"],
["NON_BINARY", "Non-binary"],
["UNKOWN", "Unknown"]
["UNKNOWN", "Unknown"]
Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed this in the edit schema last week but forgot the create schema 😁

Copy link

Bundle size difference

Comparing this PR to main

Old size New size Diff
5.97 MB 5.97 MB -186 B (-0.00%)

@aimee-mcneil-melville aimee-mcneil-melville self-assigned this Feb 28, 2025
Copy link
Contributor

@aimee-mcneil-melville aimee-mcneil-melville left a comment

Choose a reason for hiding this comment

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

Works like a beaut!
I did notice that when editing a patient, if a field is edited and not blurred before clicking one of the other tabs, the information won't save/confirm for saving.

This is not related to your issue or fix though, so I'll raise it separately!

@aimee-mcneil-melville
Copy link
Contributor

Actually - this looks like it's only if it's an immediate change of tab - after half a second it prompts the save!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Severity: Normal Bugs which have an acceptable workaround. Moderate/tolerable user impact. Next minor release. Team: Kororā 🐧 Chris, Laché, Aimee
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants