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

(fix) O3-2657: Show inline errors when saving orders fails #1667

Conversation

usamaidrsk
Copy link
Member

@usamaidrsk usamaidrsk commented Feb 15, 2024

Requirements

  • This PR has a title that briefly describes the work done including the ticket number. If there is a ticket, make sure your PR title includes a conventional commit label. See existing PR titles for inspiration.
  • My work conforms to the OpenMRS 3.0 Styleguide and design documentation.
  • My work includes tests or is validated by existing tests.

Summary

This PR add showing inline errors when saving an order fails, reading fieldErrors failed submission. Also add that quantity to dispense and quantity units to be required.

Screenshots

image
image

Related Issue

Other

O3-2657

@vasharma05 vasharma05 changed the title (fix) O3-2657: Show respective error snackbars when svaing orders fail (fix) O3-2657: Show respective error snackbars when saving orders fail Feb 15, 2024
@usamaidrsk usamaidrsk marked this pull request as draft February 15, 2024 14:15
@usamaidrsk usamaidrsk force-pushed the fix-show-respective-snackbar-errors-on-save-order-failure branch from 144ecfd to d8499a9 Compare February 17, 2024 10:43
@usamaidrsk usamaidrsk marked this pull request as ready for review February 17, 2024 10:58
@denniskigen denniskigen requested a review from ibacher February 20, 2024 13:57
@ibacher ibacher changed the title (fix) O3-2657: Show respective error snackbars when saving orders fail (fix) O3-2657: Show inline errors when saving orders fail Feb 20, 2024
Copy link
Member

@ibacher ibacher left a comment

Choose a reason for hiding this comment

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

Thanks. This mostly LGTM, but a couple of things need adjusting. In particular, avoid types that are implicitly any wherever possible.

@usamaidrsk usamaidrsk requested a review from ibacher February 21, 2024 00:04
@usamaidrsk usamaidrsk requested a review from ibacher February 21, 2024 20:45
@jwnasambu
Copy link
Contributor

This LGTM!

Copy link
Member

@ibacher ibacher left a comment

Choose a reason for hiding this comment

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

Very small adjustments, then this should be good to go.

packages/esm-patient-common-lib/src/orders/postOrders.ts Outdated Show resolved Hide resolved
packages/esm-patient-common-lib/src/orders/types.ts Outdated Show resolved Hide resolved
@usamaidrsk usamaidrsk requested a review from ibacher March 25, 2024 03:01
@usamaidrsk usamaidrsk force-pushed the fix-show-respective-snackbar-errors-on-save-order-failure branch from e2d2465 to f5dca54 Compare March 25, 2024 03:37
@usamaidrsk usamaidrsk force-pushed the fix-show-respective-snackbar-errors-on-save-order-failure branch from f5dca54 to f95b688 Compare March 25, 2024 03:46
Copy link
Member

@denniskigen denniskigen left a comment

Choose a reason for hiding this comment

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

Mostly LGTM. I've left some suggestions.

@denniskigen denniskigen changed the title (fix) O3-2657: Show inline errors when saving orders fail (fix) O3-2657: Show inline errors when saving orders fails Mar 26, 2024
@usamaidrsk usamaidrsk requested a review from denniskigen March 26, 2024 10:11
Copy link
Member

@denniskigen denniskigen left a comment

Choose a reason for hiding this comment

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

Thanks, @usamaidrsk!

@denniskigen denniskigen dismissed ibacher’s stale review March 26, 2024 12:19

The requested changes have been implemented in subsequent commits.

@denniskigen denniskigen merged commit c5a7a6c into openmrs:main Mar 26, 2024
6 checks passed
@usamaidrsk usamaidrsk deleted the fix-show-respective-snackbar-errors-on-save-order-failure branch May 13, 2024 04:12
@denniskigen denniskigen mentioned this pull request May 16, 2024
3 tasks
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.

4 participants