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

Amend bill count in bill run view for zero value #602

Merged
merged 11 commits into from
Dec 16, 2023

Conversation

Cruikshanks
Copy link
Member

@Cruikshanks Cruikshanks commented Dec 16, 2023

https://eaflood.atlassian.net/browse/WATER-4223

In testing of the new bill run view we've built a scenario was found where the count of bills we show didn't match with the number of bills on the page.

For example, the bill run had 6 credit notes and 4 invoices so we displayed "10 Supplementary bills" as the caption. But when you counted the bills listed there were 11.

We double-checked what the legacy UI was doing with this bill run and found it also displayed 6 credits and 4 invoices. But its caption was "11 supplementary bills".

Neither looks right!

After digging in we found the extra bill is a 'zero value' bill (where the credit and debit lines have value but they cancel each other out). These don't get sent to SSCL so are not included in the credit note and invoice count.

After consultation with users, they don't want these to be included in the credit note or invoice count as this will mess up their reconciliation process. But they would like the total count to be correct. The agreed solution is that when a bill run contains zero-value bills we should extend the caption, for example, "10 Supplementary bills and 1 zero value bill".

This change implements that solution.

https://eaflood.atlassian.net/browse/WATER-4223

In testing of the new bill run view we've built a scenario was found where the count of bills we show didn't match with the number of bills on the page.

For example, the bill run had 6 credit notes and 4 invoices so we displayed "10 Supplementary bills" as the caption. But when you counted the bills listed there were 11.

We double checked what the legacy UI was doing with this bill run and found it too displayed 6 credits and 4 invoices. But its caption was "11 supplementary bills".

Neither looks right!

After digging in we found the extra bill is a 'zero-value' bill (where the credit and debit lines have value but they cancel each other out). These don't get sent to SSCL so are not included in the credit note and invoice count.

After consultation with users they don't want these to be included in either the credit note or invoice count as this will mess up their reconciliation process. But they would like the total count to be correct. The agreed solution is that when a bill run contains zero-value bills we should extend the caption, for example "10 Supplementary bills and 1 zero value bill".

This change implements that solution.
@Cruikshanks Cruikshanks added the enhancement New feature or request label Dec 16, 2023
@Cruikshanks Cruikshanks self-assigned this Dec 16, 2023
We are going to need it to check if there are any zero-value bills included and if so get the count.
Also make both be for supplementary (no idea why one was Annual before!)
If there is only 1 bill on a bill run it must be a credit or an invoice because a bill run won't exist with just one bill that is zero value.

So, those tests are wrong and should not be included.
This will generate the correct caption for the view.
Means we get the thing we actually want in one call rather than doing it in 2 separate steps.
@Cruikshanks Cruikshanks marked this pull request as ready for review December 16, 2023 12:31
@Cruikshanks Cruikshanks merged commit fbae6f7 into main Dec 16, 2023
6 checks passed
@Cruikshanks Cruikshanks deleted the amend-bill-count-in-view branch December 16, 2023 12:32
@Cruikshanks Cruikshanks changed the title Amend bill count in bill run view for zero-value Amend bill count in bill run view for zero value Dec 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant