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: ensure Gov Pay reference is set for invite to pay applications in overview HTML and CSV #534

Merged
merged 1 commit into from
Oct 15, 2024

Conversation

jessicamcinchak
Copy link
Member

@jessicamcinchak jessicamcinchak commented Oct 14, 2024

Fixes #help-issues report from Friday afternoon: https://opendigitalplanning.slack.com/archives/C0241GWFG4B/p1728640257349149

Depending if the applicant self-paid or invited-to-pay, the payment info will be stored differently. We've been correctly accounting for this in the ODP Schema (eg here) but NOT the CSV/Overview HTML formats and the reference number in invite to pay cases was failing to populate.

This fix correctly accounts for invite to pay cases, but ideally in the near future we'll do a larger refactor to generate the CSV & Overview HTML from the ODP Schema directly so we can remove these duplicated bespoke messy mappings!

@jessicamcinchak jessicamcinchak marked this pull request as ready for review October 14, 2024 14:33
@jessicamcinchak jessicamcinchak requested a review from a team October 14, 2024 14:33
question: selfPayPassportKey,
responses:
(passportInstance.any([selfPayPassportKey]) as Response[]) ||
(govUkPayment as unknown as Response[]),
Copy link
Member Author

Choose a reason for hiding this comment

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

I know this is ugly type casting, but does what we need with minimal cascading changes to these bits of old tedious code !

Copy link
Contributor

@DafyddLlyr DafyddLlyr left a comment

Choose a reason for hiding this comment

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

Thanks for picking this one up - totally agreed that the aim here should be to generate this from the schema format 👌

@jessicamcinchak jessicamcinchak merged commit e73d702 into main Oct 15, 2024
3 checks passed
@jessicamcinchak jessicamcinchak deleted the jess/invite-to-pay-reference-export-docs branch October 15, 2024 11:31
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.

2 participants