-
Notifications
You must be signed in to change notification settings - Fork 248
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
(feat) Add ability to cancel orders #1640
Conversation
Size Change: -98.1 kB (-1%) Total Size: 10.7 MB
ℹ️ View Unchanged
|
aeeebc0
to
70e5951
Compare
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.scss
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have shared my comments in the PR.
My main question to this PR is, why aren't we using the order basket's Discontinue functionality which is already present in the order basket.
The same is being used for medications. I see there's a separate API you are hitting, but isn't it better to use the same /order
for these operations?
Thanks!
CC: @denniskigen @ibacher
packages/esm-patient-orders-app/src/components/orders-details-table.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.scss
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.scss
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.scss
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have shared my comments in the PR.
My main question to this PR is, why aren't we using the order basket's Discontinue functionality which is already present in the order basket.
The same is being used for medications. I see there's a separate API you are hitting, but isn't it better to use the same /order
for these operations?
Thanks!
CC: @denniskigen @ibacher
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
@vasharma05 @denniskigen all the comments have been resolved. Please take a second pass and merge if all good. |
59861b4
to
46c1cfc
Compare
packages/esm-patient-orders-app/src/components/orders-details-table.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
46c1cfc
to
28c1969
Compare
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Outdated
Show resolved
Hide resolved
packages/esm-patient-orders-app/src/order-cancellation-form/cancel-order-form.component.tsx
Show resolved
Hide resolved
72e2300
to
61bb3ee
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few more comments.
3bf7dea
to
d575cf3
Compare
Thanks @ibacher @denniskigen @denniskigen for the feedback. All the concerns and comments have been addressed. |
Could you please resolve the conflicts? |
packages/esm-patient-orders-app/src/components/orders-details-table.component.tsx
Outdated
Show resolved
Hide resolved
d575cf3
to
6f67e8d
Compare
@denniskigen @ibacher are we able to get this in? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this, @pirupius!
Thanks @denniskigen |
(feat) O3-2760: Add a `closeWorkspaceWithSavedChanges` function to the workspace API (openmrs#1689) * Added new function 'closeWorkspaceWithSavedChanges' to close workspace after form is saved * Passing 'closeWorkspaceWithSavedChanges' as workspace props (docs) Amend steps for updating core libraries in README (openmrs#1690) (chore) Bump @openmrs/ngx-formentry (openmrs#1684) (fix) O3 2804: Reuse the ResponsiveWrapper component from esm-framework (openmrs#1673) * (feat) Reuse ResponsiveWrapper component from esm-framework * feat: Added Layer in visit-notes-form * Fix styleguide imports by bumping both openmrs tooling and framework * Misc fixes --------- Co-authored-by: Dennis Kigen <[email protected]> (refactor) O3-2815: Replace usages of `/ws/rest/v1` with `restBaseUrl` (openmrs#1661) * (Refactor)O3-2815: Replace usages of '/ws/rest/v1' with restBaseUrl * Fixup --------- Co-authored-by: jwnasambu <wamalwa1844.com> Co-authored-by: Dennis Kigen <[email protected]> (feat) Add ability to cancel orders (openmrs#1640) * (feat) cancel order * clean up * pr changes, reload fixes and clean up * translations * wip cancel order via action * mutate orders on cancel * order mutations and pr comments * fixes to labs * button text change * Fixup * More tweaks --------- Co-authored-by: Dennis Kigen <[email protected]> (chore) Add generic slot to Visit Form (openmrs#1688) * (chore) Add billing slot to Start Visit Form * Add generic visit attribute slot * remove slot from config --------- Co-authored-by: CynthiaKamau <[email protected]> (chore) Bump Angular form engine (openmrs#1694) (feat) Makes orders widget expandable and adds detailed order view (openmrs#1696) * (feat) Expandable orders widget * adds order item cards when expanded * changes button to tooltip (fix) O3-2629: Submit button on Allergy Form remains disabled when filling allergen and severity before reactions (openmrs#1699) fix the allergy reaction dependency (feat) Hide bottom navigation on tablets and phones when workspace is active (openmrs#1695) (feat) Relocate Load More button in visits section (openmrs#1702) (chore) Relocate Load More button in visits section add closeWorkspaceWithSavedChanges argument to Allergy form parameterised allergy reaction should be checked correctly maintain non-coded allergen array remove test (chore) Prettier should only list files that don't formatting config (feat) Add config to handle bill submission in start visit form (openmrs#1700) Upgrade peter-evans/create-pull-request See peter-evans/create-pull-request#2790 (chore) Update translations from Transifex (openmrs#1683) add test fix added test
(feat) O3-2760: Add a `closeWorkspaceWithSavedChanges` function to the workspace API (openmrs#1689) * Added new function 'closeWorkspaceWithSavedChanges' to close workspace after form is saved * Passing 'closeWorkspaceWithSavedChanges' as workspace props (docs) Amend steps for updating core libraries in README (openmrs#1690) (chore) Bump @openmrs/ngx-formentry (openmrs#1684) (fix) O3 2804: Reuse the ResponsiveWrapper component from esm-framework (openmrs#1673) * (feat) Reuse ResponsiveWrapper component from esm-framework * feat: Added Layer in visit-notes-form * Fix styleguide imports by bumping both openmrs tooling and framework * Misc fixes --------- Co-authored-by: Dennis Kigen <[email protected]> (refactor) O3-2815: Replace usages of `/ws/rest/v1` with `restBaseUrl` (openmrs#1661) * (Refactor)O3-2815: Replace usages of '/ws/rest/v1' with restBaseUrl * Fixup --------- Co-authored-by: jwnasambu <wamalwa1844.com> Co-authored-by: Dennis Kigen <[email protected]> (feat) Add ability to cancel orders (openmrs#1640) * (feat) cancel order * clean up * pr changes, reload fixes and clean up * translations * wip cancel order via action * mutate orders on cancel * order mutations and pr comments * fixes to labs * button text change * Fixup * More tweaks --------- Co-authored-by: Dennis Kigen <[email protected]> (chore) Add generic slot to Visit Form (openmrs#1688) * (chore) Add billing slot to Start Visit Form * Add generic visit attribute slot * remove slot from config --------- Co-authored-by: CynthiaKamau <[email protected]> (chore) Bump Angular form engine (openmrs#1694) (feat) Makes orders widget expandable and adds detailed order view (openmrs#1696) * (feat) Expandable orders widget * adds order item cards when expanded * changes button to tooltip (fix) O3-2629: Submit button on Allergy Form remains disabled when filling allergen and severity before reactions (openmrs#1699) fix the allergy reaction dependency (feat) Hide bottom navigation on tablets and phones when workspace is active (openmrs#1695) (feat) Relocate Load More button in visits section (openmrs#1702) (chore) Relocate Load More button in visits section add closeWorkspaceWithSavedChanges argument to Allergy form parameterised allergy reaction should be checked correctly maintain non-coded allergen array remove test (chore) Prettier should only list files that don't formatting config (feat) Add config to handle bill submission in start visit form (openmrs#1700) Upgrade peter-evans/create-pull-request See peter-evans/create-pull-request#2790 (chore) Update translations from Transifex (openmrs#1683) add test fix added test
* (feat) cancel order * clean up * pr changes, reload fixes and clean up * translations * wip cancel order via action * mutate orders on cancel * order mutations and pr comments * fixes to labs * button text change * Fixup * More tweaks --------- Co-authored-by: Dennis Kigen <[email protected]>
) * Add functionality to allow deleting and editing an allergy (feat) O3-2760: Add a `closeWorkspaceWithSavedChanges` function to the workspace API (#1689) * Added new function 'closeWorkspaceWithSavedChanges' to close workspace after form is saved * Passing 'closeWorkspaceWithSavedChanges' as workspace props (docs) Amend steps for updating core libraries in README (#1690) (chore) Bump @openmrs/ngx-formentry (#1684) (fix) O3 2804: Reuse the ResponsiveWrapper component from esm-framework (#1673) * (feat) Reuse ResponsiveWrapper component from esm-framework * feat: Added Layer in visit-notes-form * Fix styleguide imports by bumping both openmrs tooling and framework * Misc fixes --------- Co-authored-by: Dennis Kigen <[email protected]> (refactor) O3-2815: Replace usages of `/ws/rest/v1` with `restBaseUrl` (#1661) * (Refactor)O3-2815: Replace usages of '/ws/rest/v1' with restBaseUrl * Fixup --------- Co-authored-by: jwnasambu <wamalwa1844.com> Co-authored-by: Dennis Kigen <[email protected]> (feat) Add ability to cancel orders (#1640) * (feat) cancel order * clean up * pr changes, reload fixes and clean up * translations * wip cancel order via action * mutate orders on cancel * order mutations and pr comments * fixes to labs * button text change * Fixup * More tweaks --------- Co-authored-by: Dennis Kigen <[email protected]> (chore) Add generic slot to Visit Form (#1688) * (chore) Add billing slot to Start Visit Form * Add generic visit attribute slot * remove slot from config --------- Co-authored-by: CynthiaKamau <[email protected]> (chore) Bump Angular form engine (#1694) (feat) Makes orders widget expandable and adds detailed order view (#1696) * (feat) Expandable orders widget * adds order item cards when expanded * changes button to tooltip (fix) O3-2629: Submit button on Allergy Form remains disabled when filling allergen and severity before reactions (#1699) fix the allergy reaction dependency (feat) Hide bottom navigation on tablets and phones when workspace is active (#1695) (feat) Relocate Load More button in visits section (#1702) (chore) Relocate Load More button in visits section add closeWorkspaceWithSavedChanges argument to Allergy form parameterised allergy reaction should be checked correctly maintain non-coded allergen array remove test (chore) Prettier should only list files that don't formatting config (feat) Add config to handle bill submission in start visit form (#1700) Upgrade peter-evans/create-pull-request See peter-evans/create-pull-request#2790 (chore) Update translations from Transifex (#1683) add test fix added test * clean deletePatientAllergy function * Update packages/esm-patient-allergies-app/src/allergies/allergies-form/allergy-form.component.tsx Co-authored-by: Dennis Kigen <[email protected]> * Update packages/esm-patient-allergies-app/src/allergies/allergies-form/allergy-form.test.tsx Co-authored-by: Dennis Kigen <[email protected]> * Update packages/esm-patient-allergies-app/src/allergies/allergies-form/allergy-form.resource.ts Co-authored-by: Dennis Kigen <[email protected]> * (chore) Bump @openmrs/ngx-formentry * make default allergy loading more clean * fix linting --------- Co-authored-by: Dennis Kigen <[email protected]>
* (feat) cancel order * clean up * pr changes, reload fixes and clean up * translations * wip cancel order via action * mutate orders on cancel * order mutations and pr comments * fixes to labs * button text change * Fixup * More tweaks --------- Co-authored-by: Dennis Kigen <[email protected]>
…enmrs#1703) * Add functionality to allow deleting and editing an allergy (feat) O3-2760: Add a `closeWorkspaceWithSavedChanges` function to the workspace API (openmrs#1689) * Added new function 'closeWorkspaceWithSavedChanges' to close workspace after form is saved * Passing 'closeWorkspaceWithSavedChanges' as workspace props (docs) Amend steps for updating core libraries in README (openmrs#1690) (chore) Bump @openmrs/ngx-formentry (openmrs#1684) (fix) O3 2804: Reuse the ResponsiveWrapper component from esm-framework (openmrs#1673) * (feat) Reuse ResponsiveWrapper component from esm-framework * feat: Added Layer in visit-notes-form * Fix styleguide imports by bumping both openmrs tooling and framework * Misc fixes --------- Co-authored-by: Dennis Kigen <[email protected]> (refactor) O3-2815: Replace usages of `/ws/rest/v1` with `restBaseUrl` (openmrs#1661) * (Refactor)O3-2815: Replace usages of '/ws/rest/v1' with restBaseUrl * Fixup --------- Co-authored-by: jwnasambu <wamalwa1844.com> Co-authored-by: Dennis Kigen <[email protected]> (feat) Add ability to cancel orders (openmrs#1640) * (feat) cancel order * clean up * pr changes, reload fixes and clean up * translations * wip cancel order via action * mutate orders on cancel * order mutations and pr comments * fixes to labs * button text change * Fixup * More tweaks --------- Co-authored-by: Dennis Kigen <[email protected]> (chore) Add generic slot to Visit Form (openmrs#1688) * (chore) Add billing slot to Start Visit Form * Add generic visit attribute slot * remove slot from config --------- Co-authored-by: CynthiaKamau <[email protected]> (chore) Bump Angular form engine (openmrs#1694) (feat) Makes orders widget expandable and adds detailed order view (openmrs#1696) * (feat) Expandable orders widget * adds order item cards when expanded * changes button to tooltip (fix) O3-2629: Submit button on Allergy Form remains disabled when filling allergen and severity before reactions (openmrs#1699) fix the allergy reaction dependency (feat) Hide bottom navigation on tablets and phones when workspace is active (openmrs#1695) (feat) Relocate Load More button in visits section (openmrs#1702) (chore) Relocate Load More button in visits section add closeWorkspaceWithSavedChanges argument to Allergy form parameterised allergy reaction should be checked correctly maintain non-coded allergen array remove test (chore) Prettier should only list files that don't formatting config (feat) Add config to handle bill submission in start visit form (openmrs#1700) Upgrade peter-evans/create-pull-request See peter-evans/create-pull-request#2790 (chore) Update translations from Transifex (openmrs#1683) add test fix added test * clean deletePatientAllergy function * Update packages/esm-patient-allergies-app/src/allergies/allergies-form/allergy-form.component.tsx Co-authored-by: Dennis Kigen <[email protected]> * Update packages/esm-patient-allergies-app/src/allergies/allergies-form/allergy-form.test.tsx Co-authored-by: Dennis Kigen <[email protected]> * Update packages/esm-patient-allergies-app/src/allergies/allergies-form/allergy-form.resource.ts Co-authored-by: Dennis Kigen <[email protected]> * (chore) Bump @openmrs/ngx-formentry * make default allergy loading more clean * fix linting --------- Co-authored-by: Dennis Kigen <[email protected]>
Requirements
Summary
Screenshots
Screen.Recording.2024-02-22.at.15.19.11.mov
Related Issue
Other