Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
B-22186
INT PR
Summary
There have been errors occurring in production when documents are deleted and then new documents uploaded. This would occur when attempting to download the AOA Packets. The method used to fetch the uploaded documents by the AOA packet creation was passing a flag that in certain situations (that are difficult to reproduce) would cause the query for documents to return empty even though there are uploaded documents for that shipment. To resolve this we tell the query to give us everything then filter out the deleted uploads inside the AOA creation method.
The following was the error I received during analysis and that is seen in production:
"error creating AOA packet: error building PDF batch information for bookmark generation for order docs: error fetching document domain by id: e0817df2-f271-41ff-866a-e197328c0d6f: FETCH_NOT_FOUND"}
Verification Steps for the Author
These are to be checked by the author.
Verification Steps for Reviewers
These are to be checked by a reviewer.
Setup to Run the Code
How to test
This one was tricky to get it to fail but the basic idea was to add a bunch of order documents then delete them then add them again and request an advance for the PPM so you can attempt to download the AOA packet.
Frontend
officeApp
class or custommin-width
styling is used to hide any states the would not be visible to the user.Backend
Database
Any new migrations/schema changes:
Screenshots