-
Notifications
You must be signed in to change notification settings - Fork 0
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
Paid invoices and invoice lines data #1239
Conversation
183e315
to
f4994fd
Compare
[ | ||
{ | ||
"fadacf66-8813-4759-b4d3-7d506db38f48": { | ||
"fund_ids": [ | ||
"0e8804ca-0190-4a98-a88d-83ae77a0f8e3" | ||
], | ||
"poline_id": "b5ba6538-7e04-4be3-8a0e-c68306c355a2" | ||
} | ||
}, | ||
{ | ||
"a16030c1-66ca-44c1-b0a3-572cde626685": { | ||
"fund_ids": [ | ||
"47e1fc24-300d-4817-a866-5c0a2f490522" | ||
], | ||
"poline_id": "5513c3d7-7c6b-45ea-a875-09798b368873" | ||
} | ||
} | ||
] |
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.
As I was writing the test, I started to wonder why we even want the invoice line UUID here as key. Maybe for troubleshooting? We could have invoice lines that do not have fundDistributions (it is not required per json schema docs) and also no po line ID. So if the fund ID is missing or po line is missing, we don't want that data. Currently, in those cases, the filter_invoice_lines list can include an object like:
{"a16030c1-66ca-44c1-b0a3-572cde626685": {}}
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.
Or maybe in reporting in an email?
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.
Maybe we change this in a subsequent PR if unpacking this list is problematic with the empty objects for invoicelines that don't have funds or po lines.
retrieve_instances = instances_from_po_lines( | ||
retrieve_paid_po_lines, retrieve_bookplate_fund_ids | ||
) | ||
retrieve_instances = instances_from_po_lines(retrieve_bookplate_fund_po_lines) |
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.
The instances_from_po_lines
is missing a required funds
parameter
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.
Fixed in latest commit.
Closes #1218
Closes #1209