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

MAIN-B-21618 Prime Sim Create NTS/NTSR Shipments #14624

Merged
merged 11 commits into from
Jan 23, 2025
Merged

Conversation

brianmanley-caci
Copy link
Contributor

@brianmanley-caci brianmanley-caci commented Jan 20, 2025

Agility ticket

INT PR

Summary

The purpose of this story is to fix the NTS/NTSR Creation for the prime user. Previously it was erroring if the user sent a delivery address(NTS) or a pickup address(NTSR). The reason was that the shipment creator service was skipping the address creation in the database for NTS and NTSR which happens before the shipment is saved. Subsequently when it attempted to save the shipment, it was encountering a FK constraint on the address due to the address not being saved to the database.

This story removes the NTS/NTSR shipment type check for delivery/pickup address creation which will allow the shipment to be created successfully. The current process of the TOO adding the storage facility address info and that info being copied to the destination(NTS) or pickup(NTSR) address remains ensuring that the storage facility address will match the pickup/destination address as expected.

There will be a follow on feature that will allow the prime to include the storage information when creating an NTS/NTSR shipment, but that was not included as part of this feature.

Is there anything you would like reviewers to give additional scrutiny?

this article explains more about the approach used.

Verification Steps for the Author

These are to be checked by the author.

  • Tested in the Experimental environment (for changes to containers, app startup, or connection to data stores)
  • Have the Agility acceptance criteria been met for this change?

Verification Steps for Reviewers

These are to be checked by a reviewer.

  • Has the branch been pulled in and checked out?
  • Have the BL acceptance criteria been met for this change?
  • Was the CircleCI build successful?
  • Has the code been reviewed from a standards and best practices point of view?

Setup to Run the Code

How to test

  1. Login as a prime simulator user.
  2. Choose an existing move.
  3. Click on the Create Shipment button.
  4. Choose either HHG_INTO_NTS or HHT_OUTOF_NTS_DOMESTIC
  5. Add a pickup address, destination address, and any other required fields.
  6. Click the Save button. You should received a "Successfully created shipment..."

Frontend

  • There are no aXe warnings for UI.
  • This works in Supported Browsers and their phone views (Chrome, Firefox, Edge).
  • There are no new console errors in the browser devtools.
  • There are no new console errors in the test output.
  • If this PR adds a new component to Storybook, it ensures the component is fully responsive, OR if it is intentionally not, a wrapping div using the officeApp class or custom min-width styling is used to hide any states the would not be visible to the user.
  • This change meets the standards for Section 508 compliance.

Backend

Database

Any new migrations/schema changes:

  • Follows our guidelines for Zero-Downtime Deploys.
  • Have been communicated to #g-database.
  • Secure migrations have been tested following the instructions in our docs.

Screenshots

Screenshot 2024-12-27 at 12 32 11 PM
Screenshot 2024-12-27 at 12 32 33 PM
Screenshot 2024-12-27 at 12 33 08 PM

Copy link
Contributor

@danieljordan-caci danieljordan-caci left a comment

Choose a reason for hiding this comment

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

Code changes match up

@ryan-mchugh
Copy link
Contributor

INTO NTS
image

OUTOF NTS
image

NOTE - I was getting some "unique identifier" foreign key errors when submitting at times. I cleaned my local build and refreshed the DB and was able to get these two successful.

Copy link
Contributor

@cameroncaci cameroncaci left a comment

Choose a reason for hiding this comment

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

POA'd and commits are good

@brianmanley-caci brianmanley-caci merged commit 9c4fa7d into main Jan 23, 2025
43 checks passed
@brianmanley-caci brianmanley-caci deleted the MAIN-B-21618 branch January 23, 2025 15:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

Successfully merging this pull request may close these issues.

5 participants